-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Wikidata v0 with author description and infobox #9130
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm! Deploying to testing and will give a whirl there!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested:
- Visiting https://testing.openlibrary.org/authors/OL25788A/John_Steinbeck logged in as a librarian fetches wikidata and displays the Wikdiata short description
- Afterwards visiting https://testing.openlibrary.org/authors/OL25788A/John_Steinbeck , the short description is still visible
- Author with no Wikidata ID loads correctly: https://testing.openlibrary.org/authors/OL147566A/Klaus_von_See
- Going to an author page with a wikidata id logged out does not fetch/display the wd short description: https://testing.openlibrary.org/authors/OL1121078A
- Log in as non-librarian, going to author page does not display the wikidata description
- Clicking "Edit" does fetch/display the wd description
⚠ Modifying the short description on wikidata and reloading the author page as a non-librarian showed the new description! This suggests it re-fetched.
One bug to look into otherwise the testing went ok! Although I realized I was kind of assuming it fetched/didn't fetch the wikidata data.
@cdrini I fixed it :') I also write a ton of tests along the way so you can feel confident that that part of the code is working. |
c03d1c4
to
4710814
Compare
478104f
to
aafdc27
Compare
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm! Did a lighter round of testing and things appear to roughly work. Great catch on that bug!!! Super subtle.
Note: We should chat about at least on the edit page displaying that this data is coming from wikidata. But that can be a future change.
Is there a reason that this isn't linked to the issue #710 that it is intended to address? The side effect is that anyone who's interested in Wikidata integration and following that issue won't have been pinged to review this. |
Wikidata Project Google Doc
In short, this PR enables us to start fetching info from wikidata and showing it on the author pages.
How it works:
About this first step
This PR is v0 of the wikidata project:
Technical
This PR supersedes: #8949 and #8236 - much discussion here
Testing
Drini has tested thoroughly (see comments in this PR) but we also have nice unit tests for caching now.
Screenshot
Stakeholders
@cdrini