def test_public_comments(self, conference, helpers, test_client, client): notes = test_client.get_notes( invitation='MICCAI.org/2021/Challenges/-/Submission') assert len(notes) == 5 conference.set_comment_stage( openreview.CommentStage(unsubmitted_reviewers=True, reader_selection=True, email_pcs=True, authors=True, allow_public_comments=True)) public_comment_invitation = openreview.tools.get_invitation( client, conference.get_invitation_id('Public_Comment', number=1)) assert public_comment_invitation is None
def get_comment_stage(client, request_forum): commentary_start_date = request_forum.content.get('commentary_start_date', '').strip() if commentary_start_date: try: commentary_start_date = datetime.datetime.strptime( commentary_start_date, '%Y/%m/%d %H:%M') except ValueError: commentary_start_date = datetime.datetime.strptime( commentary_start_date, '%Y/%m/%d') else: commentary_start_date = None commentary_end_date = request_forum.content.get('commentary_end_date', '').strip() if commentary_end_date: try: commentary_end_date = datetime.datetime.strptime( commentary_end_date, '%Y/%m/%d %H:%M') except ValueError: commentary_end_date = datetime.datetime.strptime( commentary_end_date, '%Y/%m/%d') else: commentary_end_date = None anonymous = 'Public (anonymously)' in request_forum.content.get( 'participants', '') allow_public_comments = anonymous or 'Public (non-anonymously)' in request_forum.content.get( 'participants', '') unsubmitted_reviewers = 'Paper Submitted Reviewers' not in request_forum.content.get( 'participants', '') and 'Paper Reviewers' in request_forum.content.get( 'participants', '') email_pcs = request_forum.content.get( 'email_program_chairs_about_official_reviews', '') == 'Yes, email PCs for each official comment made in the venue' authors_invited = 'Authors' in request_forum.content.get( 'participants', '') return openreview.CommentStage(start_date=commentary_start_date, end_date=commentary_end_date, allow_public_comments=allow_public_comments, anonymous=anonymous, unsubmitted_reviewers=unsubmitted_reviewers, reader_selection=True, email_pcs=email_pcs, authors=authors_invited)
def test_open_comments(self, client, test_client, selenium, request_page): builder = openreview.conference.ConferenceBuilder(client) assert builder, 'builder is None' builder.set_conference_id('NIPS.cc/2018/Workshop/MLITS') builder.has_area_chairs(True) conference = builder.get_result() conference.set_comment_stage(openreview.CommentStage(authors=True)) notes = test_client.get_notes( invitation='NIPS.cc/2018/Workshop/MLITS/-/Submission') submission = notes[0] request_page(selenium, "http://localhost:3030/forum?id=" + submission.id, test_client.token) reply_row = selenium.find_element_by_class_name('reply_row') assert len(reply_row.find_elements_by_class_name('btn')) == 1 assert 'Official Comment' == reply_row.find_elements_by_class_name( 'btn')[0].text
openreview.ExpertiseSelectionStage( due_date=datetime.datetime(2019, 9, 28, 14, 59))) ## Anonymize current submissions conference.create_blind_submissions() ## Create withdraw invitations conference.create_withdraw_invitations() ## Create desk reject invitations conference.create_desk_reject_invitations() ## Stage: discussion conference.set_comment_stage( openreview.CommentStage(allow_public_comments=True, unsubmitted_reviewers=True, reader_selection=True, email_pcs=False)) ## Stage: bids conference.setup_matching( affinity_score_file='reviewer-path-to-scores.csv') conference.setup_matching(is_area_chair=True, affinity_score_file='ac-path-to-scores.csv') conference.set_bid_stage( openreview.BidStage(due_date=datetime.datetime(2019, 10, 2, 14, 59), use_affinity_score=True)) ## Stage: paper matching conference.setup_matching( affinity_score_file='path-to-re-created-scores-reviewers.csv')
def test_single_blind_conference(self, client, test_client, selenium, request_page, helpers): builder = openreview.conference.ConferenceBuilder(client) assert builder, 'builder is None' builder.set_conference_id('NIPS.cc/2019/Workshop/MLITS') builder.set_conference_name('2019 NIPS MLITS Workshop') builder.set_homepage_header({ 'title': '2019 NIPS MLITS Workshop', 'subtitle': 'Machine Learning for Intelligent Transportation Systems', 'deadline': 'October 12, 2018, 11:59 pm UTC', 'date': 'December 3-8, 2018', 'website': 'https://sites.google.com/site/nips2018mlits/home', 'location': 'Montreal, Canada', 'instructions': '' }) builder.has_area_chairs(True) builder.use_legacy_invitation_id(True) now = datetime.datetime.utcnow() builder.set_submission_stage(public=True, due_date=now + datetime.timedelta(minutes=40)) builder.set_review_stage(due_date=now + datetime.timedelta(minutes=40)) builder.set_meta_review_stage(due_date=now + datetime.timedelta(minutes=40)) conference = builder.get_result() note = openreview.Note( invitation=conference.get_submission_id(), readers=['everyone'], writers=['~Test_User1', '*****@*****.**', '*****@*****.**'], signatures=['~Test_User1'], content={ 'title': 'Paper title', 'abstract': 'This is an abstract', 'authorids': ['*****@*****.**', '*****@*****.**', '*****@*****.**'], 'authors': ['Test User', 'Peter Test', 'Andrew Mc'] }) url = test_client.put_attachment( os.path.join(os.path.dirname(__file__), 'data/paper.pdf'), conference.get_submission_id(), 'pdf') note.content['pdf'] = url test_client.post_note(note) conference.create_paper_groups(authors=True, reviewers=True, area_chairs=True) conference.set_reviewers(['*****@*****.**']) conference.set_area_chairs(['*****@*****.**']) conference.set_program_chairs(['*****@*****.**']) conference.set_assignment('*****@*****.**', 1) conference.set_assignment('*****@*****.**', 1, True) conference.set_comment_stage(openreview.CommentStage(authors=True)) conference.open_reviews() conference.open_meta_reviews() conference.open_decisions() assert client.get_invitations( regex='NIPS.cc/2019/Workshop/MLITS/-/Paper.*/Official_Comment') assert client.get_invitations( regex='NIPS.cc/2019/Workshop/MLITS/-/Paper.*/Official_Review') assert client.get_invitations( regex='NIPS.cc/2019/Workshop/MLITS/-/Paper.*/Meta_Review') assert client.get_invitations( regex='NIPS.cc/2019/Workshop/MLITS/-/Paper.*/Decision') reviewer_client = helpers.create_user('*****@*****.**', 'Reviewer', 'Legacy') request_page( selenium, "http://*****:*****@mail.com', 'AC', 'Legacy') request_page( selenium, "http://*****:*****@mail.com', 'PC', 'Legacy') request_page( selenium, "http://localhost:3030/group?id=NIPS.cc/2019/Workshop/MLITS/Program_Chairs", pc_client.token) tabs = selenium.find_element_by_class_name('tabs-container') assert tabs assert tabs.find_element_by_id('venue-configuration') assert tabs.find_element_by_id('paper-status') assert tabs.find_element_by_id('areachair-status') assert tabs.find_element_by_id('reviewer-status')
def test_open_comments(self, client, conference, test_client, selenium, request_page, helpers): conference.set_comment_stage(openreview.CommentStage(unsubmitted_reviewers = True, email_pcs = True, reader_selection=True, allow_public_comments = True, authors=True)) notes = test_client.get_notes(invitation='icaps-conference.org/ICAPS/2019/Workshop/HSDIP/-/Blind_Submission') submission = notes[2] reviews = client.get_notes(invitation='icaps-conference.org/ICAPS/2019/Workshop/HSDIP/Paper1/-/Official_Review') assert reviews review = reviews[0] note = openreview.Note(invitation = 'icaps-conference.org/ICAPS/2019/Workshop/HSDIP/Paper1/-/Official_Comment', forum = submission.id, replyto = review.id, readers = [ 'icaps-conference.org/ICAPS/2019/Workshop/HSDIP/Paper1/Authors', 'icaps-conference.org/ICAPS/2019/Workshop/HSDIP/Paper1/Reviewers', 'icaps-conference.org/ICAPS/2019/Workshop/HSDIP/Program_Chairs'], writers = ['icaps-conference.org/ICAPS/2019/Workshop/HSDIP/Paper1/AnonReviewer1'], signatures = ['icaps-conference.org/ICAPS/2019/Workshop/HSDIP/Paper1/AnonReviewer1'], content = { 'title': 'Comment title', 'comment': 'Paper is very good!' } ) reviewer_client = openreview.Client(username='******', password='******') review_note = reviewer_client.post_note(note) assert review_note helpers.await_queue() process_logs = client.get_process_logs(id = review_note.id) assert len(process_logs) == 1 assert process_logs[0]['status'] == 'ok' messages = client.get_messages(subject = '.*ICAPS HSDIP 2019.*AnonReviewer1 commented on your submission. Paper Number: 1, Paper Title') assert len(messages) == 3 recipients = [m['content']['to'] for m in messages] assert '*****@*****.**' in recipients assert '*****@*****.**' in recipients assert '*****@*****.**' in recipients messages = client.get_messages(subject = '.*ICAPS HSDIP 2019.*AnonReviewer1 commented on a paper you are reviewing. Paper Number: 1, Paper Number') assert len(messages) == 0 messages = client.get_messages(subject = '.*ICAPS HSDIP 2019.*AnonReviewer1 commented on a paper in your area. Paper Number: 1, Paper Number') assert len(messages) == 0 messages = client.get_messages(subject = '.*ICAPS HSDIP 2019.*AnonReviewer1 commented on a paper. Paper Number') assert len(messages) == 1 recipients = [m['content']['to'] for m in messages] assert '*****@*****.**' in recipients random_user = helpers.create_user(email='*****@*****.**', first='Random', last='User') note = openreview.Note(invitation = 'icaps-conference.org/ICAPS/2019/Workshop/HSDIP/Paper1/-/Public_Comment', forum = submission.id, replyto = submission.id, readers = ['everyone'], writers = ['~Random_User1'], signatures = ['~Random_User1'], content = { 'title': 'Comment title', 'comment': 'Paper is very good!' } ) public_comment_note = random_user.post_note(note) assert public_comment_note helpers.await_queue() process_logs = client.get_process_logs(id = public_comment_note.id) assert len(process_logs) == 1 assert process_logs[0]['status'] == 'ok'