Skip to content

Add Harvard University and alpha sort MARC sources #10771

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

Merged
merged 3 commits into from
May 20, 2025

Conversation

hornc
Copy link
Collaborator

@hornc hornc commented May 14, 2025

Closes #

Changes the source text from "harvard_bibliographic_metadata record" to "Harvard University record"

Example record: https://openlibrary.org/books/OL59082038M/Krugi

and alpha sorts the keys for organisation.

Technical

Testing

Screenshot

Stakeholders

@mekarpeles mekarpeles added the Needs: Submitter Input Waiting on input from the creator of the issue/pr [managed] label May 19, 2025
@mekarpeles mekarpeles requested a review from Copilot May 19, 2025 19:36
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Adds a more user-friendly label for Harvard and reorders MARC source mappings in sources.html for consistency

  • Updates the label for harvard_bibliographic_metadata to “Harvard University”
  • Inserts new MARC source entries and alphabetizes the keys
  • Refactors string concatenation to f-strings for URLs and links
Comments suppressed due to low confidence (2)

openlibrary/templates/history/sources.html:5

  • Add or update a test to verify that harvard_bibliographic_metadata maps to “Harvard University” in the rendered source list, ensuring the new label appears correctly.
"harvard_bibliographic_metadata": "Harvard University",

openlibrary/templates/history/sources.html:5

  • [nitpick] Inconsistent indentation detected (a tab is used on this line). Convert all leading tabs to spaces to match the surrounding entries.
"harvard_bibliographic_metadata": "Harvard University",

@github-actions github-actions bot removed the Needs: Submitter Input Waiting on input from the creator of the issue/pr [managed] label May 19, 2025
Copy link
Collaborator

@jimchamp jimchamp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me, @hornc. I'm going to commit the change suggested here, then merge this in.

Co-authored-by: Copilot <[email protected]>
@jimchamp jimchamp merged commit 48b53e0 into internetarchive:master May 20, 2025
4 checks passed
@hornc
Copy link
Collaborator Author

hornc commented May 20, 2025

@jimchamp uh, the AI suggested change was crap though. It wasn't in alphabetical order. I wasted time checking it, c an we revert it?

@jimchamp
Copy link
Collaborator

Looks like f-string literals cannot be used in our templates, and book pages are not rendering after these updates. Will open a PR reverting those changes shortly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants