Fix File show_as_unviewed behavior#9960
Merged
jwalz merged 25 commits intoJun 21, 2022
Merged
Conversation
added 24 commits
June 16, 2022 09:48
relying on default values
brianjgeiger
requested changes
Jun 21, 2022
Collaborator
brianjgeiger
left a comment
There was a problem hiding this comment.
Only the tiniest of typos on one of the docstrings.
brianjgeiger
approved these changes
Jun 21, 2022
Collaborator
brianjgeiger
left a comment
There was a problem hiding this comment.
GHA takes forever to run. I'm not going to hold up the PR for a typo, but it wouldn't be bad to fix if there turns out to be anything else.
Co-authored-by: Brian J. Geiger <bgeiger@pobox.com>
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Jun 26, 2022
…OpenScience/osf.io into load-lincenses * 'feature/django_upgrade' of https://github.com/CenterForOpenScience/osf.io: remove post-migrate signals from migration stream (CenterForOpenScience#9964) Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) Fix OSFUser.has_resources ensure VOL users always get read perms (CenterForOpenScience#9952) make types correspond more to serializer code (CenterForOpenScience#9955) remove special casing from DV permissions (CenterForOpenScience#9947)
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Jun 26, 2022
…OpenScience/osf.io into signal-storage-region * 'feature/django_upgrade' of https://github.com/CenterForOpenScience/osf.io: remove post-migrate signals from migration stream (CenterForOpenScience#9964) Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) Fix OSFUser.has_resources ensure VOL users always get read perms (CenterForOpenScience#9952) make types correspond more to serializer code (CenterForOpenScience#9955) remove special casing from DV permissions (CenterForOpenScience#9947) Add a generic demo institution on the test server Don't send empty affiliations list to Datacite or Crossref Update pre-commit config to specify py version Fix DOI conditional Bump version and update CHANGELOG Update sc to use new SSO IdP [ENG-3832] Add redirect based for unauthed files page user (CenterForOpenScience#9948) [ENG-3781] Admin Registration Schemas (CenterForOpenScience#9937)
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Jun 27, 2022
…OpenScience/osf.io into investigate-waffle-flags * 'feature/django_upgrade' of https://github.com/CenterForOpenScience/osf.io: move createcachetable to post migrate signal (CenterForOpenScience#9944) remove post-migrate signals from migration stream (CenterForOpenScience#9964) Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) # Conflicts: # osf/apps.py # osf/migrations/0137_transfer_preprint_service_permissions.py # osf/migrations/__init__.py
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Jun 27, 2022
…OpenScience/osf.io into signal-deny-list * 'feature/django_upgrade' of https://github.com/CenterForOpenScience/osf.io: move createcachetable to post migrate signal (CenterForOpenScience#9944) remove post-migrate signals from migration stream (CenterForOpenScience#9964) Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) # Conflicts: # osf/apps.py # osf/migrations/0137_transfer_preprint_service_permissions.py # osf/migrations/__init__.py
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Jun 27, 2022
…OpenScience/osf.io into signal-deny-list * 'feature/django_upgrade' of https://github.com/CenterForOpenScience/osf.io: move createcachetable to post migrate signal (CenterForOpenScience#9944) remove post-migrate signals from migration stream (CenterForOpenScience#9964) Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) # Conflicts: # osf/apps.py # osf/migrations/0137_transfer_preprint_service_permissions.py # osf/migrations/__init__.py
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Jul 29, 2022
into fix-mailchimp * 'develop' of https://github.com/CenterForOpenScience/osf.io: (73 commits) [ENG-3898][ENG-3899]Model support for OutcomeArtifact update and delete (CenterForOpenScience#9989) Make OutcomeArtifact.identifier nullable (CenterForOpenScience#9986) [ENG-3894] Outcome models (CenterForOpenScience#9975) revert color picker to working version (CenterForOpenScience#9968) Instrument the ORCiD SSO affiliation flow * Existing user with verified ORCiD ID * Existing user confirmation of linking ORCiD ID * New user confirmation of account creation with ORCiD ID Add a django command script to handle instn sso email domain changes Bump version and CHANGELOG Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) Fix OSFUser.has_resources ensure VOL users always get read perms (CenterForOpenScience#9952) make types correspond more to serializer code (CenterForOpenScience#9955) remove special casing from DV permissions (CenterForOpenScience#9947) Add a generic demo institution on the test server Don't send empty affiliations list to Datacite or Crossref Update pre-commit config to specify py version Fix DOI conditional Bump version and update CHANGELOG Update sc to use new SSO IdP ... # Conflicts: # website/templates/profile/notifications.mako
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Jul 29, 2022
into add-doi-domain * 'develop' of https://github.com/CenterForOpenScience/osf.io: (126 commits) [ENG-3898][ENG-3899]Model support for OutcomeArtifact update and delete (CenterForOpenScience#9989) Make OutcomeArtifact.identifier nullable (CenterForOpenScience#9986) [ENG-3894] Outcome models (CenterForOpenScience#9975) revert color picker to working version (CenterForOpenScience#9968) Instrument the ORCiD SSO affiliation flow * Existing user with verified ORCiD ID * Existing user confirmation of linking ORCiD ID * New user confirmation of account creation with ORCiD ID Add a django command script to handle instn sso email domain changes Bump version and CHANGELOG Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) Fix OSFUser.has_resources ensure VOL users always get read perms (CenterForOpenScience#9952) make types correspond more to serializer code (CenterForOpenScience#9955) remove special casing from DV permissions (CenterForOpenScience#9947) Add a generic demo institution on the test server Don't send empty affiliations list to Datacite or Crossref Update pre-commit config to specify py version Fix DOI conditional Bump version and update CHANGELOG Update sc to use new SSO IdP ...
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Aug 16, 2022
into remove-quickfiles-code * 'develop' of https://github.com/CenterForOpenScience/osf.io: (44 commits) Re-add non-anonymized fields removed in CenterForOpenScience#10009 (CenterForOpenScience#10022) Update shield logo for colorado (UC Boulder) Update description for maglab [ENG-3249] Improve registration anonymization (CenterForOpenScience#10009) "backport" artifact changes and swap schema_response.justification (CenterForOpenScience#10003) Add new instn purdue Ensure BitBucket token is string, not bytes Only redirect to cas if not logged in OSFI: Update Shared SSO and Add MagLab/FSU [ENG-3654] [ENG-3898][ENG-3899]Model support for OutcomeArtifact update and delete (CenterForOpenScience#9989) Make OutcomeArtifact.identifier nullable (CenterForOpenScience#9986) [ENG-3894] Outcome models (CenterForOpenScience#9975) revert color picker to working version (CenterForOpenScience#9968) Instrument the ORCiD SSO affiliation flow * Existing user with verified ORCiD ID * Existing user confirmation of linking ORCiD ID * New user confirmation of account creation with ORCiD ID Add a django command script to handle instn sso email domain changes Bump version and CHANGELOG Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) Fix OSFUser.has_resources ... # Conflicts: # api_tests/files/views/test_file_detail.py # osf/models/nodelog.py # osf/models/user.py # tests/test_addons.py # website/static/js/anonymousLogActionsList.json # website/static/js/logActionsList.json
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Aug 16, 2022
into remove-quickfiles-code * 'develop' of https://github.com/CenterForOpenScience/osf.io: (44 commits) Re-add non-anonymized fields removed in CenterForOpenScience#10009 (CenterForOpenScience#10022) Update shield logo for colorado (UC Boulder) Update description for maglab [ENG-3249] Improve registration anonymization (CenterForOpenScience#10009) "backport" artifact changes and swap schema_response.justification (CenterForOpenScience#10003) Add new instn purdue Ensure BitBucket token is string, not bytes Only redirect to cas if not logged in OSFI: Update Shared SSO and Add MagLab/FSU [ENG-3654] [ENG-3898][ENG-3899]Model support for OutcomeArtifact update and delete (CenterForOpenScience#9989) Make OutcomeArtifact.identifier nullable (CenterForOpenScience#9986) [ENG-3894] Outcome models (CenterForOpenScience#9975) revert color picker to working version (CenterForOpenScience#9968) Instrument the ORCiD SSO affiliation flow * Existing user with verified ORCiD ID * Existing user confirmation of linking ORCiD ID * New user confirmation of account creation with ORCiD ID Add a django command script to handle instn sso email domain changes Bump version and CHANGELOG Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) Fix OSFUser.has_resources ... # Conflicts: # api_tests/files/views/test_file_detail.py # osf/models/nodelog.py # osf/models/user.py # tests/test_addons.py # website/static/js/anonymousLogActionsList.json # website/static/js/logActionsList.json
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Aug 16, 2022
into remove-quickfiles-code * 'develop' of https://github.com/CenterForOpenScience/osf.io: (44 commits) Re-add non-anonymized fields removed in CenterForOpenScience#10009 (CenterForOpenScience#10022) Update shield logo for colorado (UC Boulder) Update description for maglab [ENG-3249] Improve registration anonymization (CenterForOpenScience#10009) "backport" artifact changes and swap schema_response.justification (CenterForOpenScience#10003) Add new instn purdue Ensure BitBucket token is string, not bytes Only redirect to cas if not logged in OSFI: Update Shared SSO and Add MagLab/FSU [ENG-3654] [ENG-3898][ENG-3899]Model support for OutcomeArtifact update and delete (CenterForOpenScience#9989) Make OutcomeArtifact.identifier nullable (CenterForOpenScience#9986) [ENG-3894] Outcome models (CenterForOpenScience#9975) revert color picker to working version (CenterForOpenScience#9968) Instrument the ORCiD SSO affiliation flow * Existing user with verified ORCiD ID * Existing user confirmation of linking ORCiD ID * New user confirmation of account creation with ORCiD ID Add a django command script to handle instn sso email domain changes Bump version and CHANGELOG Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) Fix OSFUser.has_resources ... # Conflicts: # api_tests/files/views/test_file_detail.py # osf/models/nodelog.py # osf/models/user.py # tests/test_addons.py # website/static/js/anonymousLogActionsList.json # website/static/js/logActionsList.json
Johnetordoff
pushed a commit
to Johnetordoff/osf.io
that referenced
this pull request
Aug 16, 2022
into remove-quickfiles-code * 'develop' of https://github.com/CenterForOpenScience/osf.io: (44 commits) Re-add non-anonymized fields removed in CenterForOpenScience#10009 (CenterForOpenScience#10022) Update shield logo for colorado (UC Boulder) Update description for maglab [ENG-3249] Improve registration anonymization (CenterForOpenScience#10009) "backport" artifact changes and swap schema_response.justification (CenterForOpenScience#10003) Add new instn purdue Ensure BitBucket token is string, not bytes Only redirect to cas if not logged in OSFI: Update Shared SSO and Add MagLab/FSU [ENG-3654] [ENG-3898][ENG-3899]Model support for OutcomeArtifact update and delete (CenterForOpenScience#9989) Make OutcomeArtifact.identifier nullable (CenterForOpenScience#9986) [ENG-3894] Outcome models (CenterForOpenScience#9975) revert color picker to working version (CenterForOpenScience#9968) Instrument the ORCiD SSO affiliation flow * Existing user with verified ORCiD ID * Existing user confirmation of linking ORCiD ID * New user confirmation of account creation with ORCiD ID Add a django command script to handle instn sso email domain changes Bump version and CHANGELOG Add better logic for routing Dataverse files and their stupid duplicate (CenterForOpenScience#9963) [ENG-3872] Fix dataverse 502s and pass version info to FE (CenterForOpenScience#9959) Fix File `show_as_unviewed` behavior (CenterForOpenScience#9960) Fix OSFUser.has_resources ... # Conflicts: # api_tests/files/views/test_file_detail.py # osf/models/nodelog.py # osf/models/user.py # tests/test_addons.py # website/static/js/anonymousLogActionsList.json # website/static/js/logActionsList.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
The legacy behavior imitated by the
current_user_has_seenattribute wasn't quite as simple as the name suggested.The FE only wanted to mark a File as unseen in the case where the user hadn't seen the latest version and they had viewed a previous version.
Changes
current_user_has_seentoshow_as_unviewedto more accurately reflect the intent and be less misleadingSerializerMethodFieldbehaviorQA Notes
Please make verification statements inspired by your code and what your code touches.
What are the areas of risk?
Any concerns/considerations/questions that development raised?
Documentation
Side Effects
Ticket