Skip to content
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

Label lookups for LCSH mappings are no longer working #1619

Closed
osma opened this issue Apr 16, 2024 · 0 comments · Fixed by #1620
Closed

Label lookups for LCSH mappings are no longer working #1619

osma opened this issue Apr 16, 2024 · 0 comments · Fixed by #1620
Assignees
Labels
Milestone

Comments

@osma
Copy link
Member

osma commented Apr 16, 2024

URL address of the page where you encountered the problem

https://finto.fi/yso/en/page/p14174

Description of the problem

Go to any YSO concept which has a mapping to LCSH (e.g. above URL). The mappings look like this:

image

Instead of the LCSH URI, the label "Labyrinths" should be displayed. This used to work fine but has recently stopped working.

I did some digging and found out the cause.

Skosmos has some custom code (LOCResolver.php) to perform fast HTTP HEAD lookups from LCSH and other LOC linked data sources. Previously, the LOC server has responded with a X-PrefLabel HTTP header containing the preferred label. But now the header is x-preflabel. Skosmos is expecting a specific capitalization style and thus fails to parse the HTTP header.

The fix is simple, just make the parsing code case-insensitive. I will open two PRs to fix this, separately for Skosmos 2 and 3.

Additional information (e.g. screenshots) about the problem

See above

The browser you used when the problem appeared

Firefox

@osma osma added the bug label Apr 16, 2024
@osma osma added this to the 2.x milestone Apr 16, 2024
@osma osma self-assigned this Apr 16, 2024
@joelit joelit moved this to Done (verified in test.dev.finto.fi, set Milestone 3.0 for both issue & PR) in Skosmos 3.0 Backlog Aug 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Status: Done (verified in test.dev.finto.fi, set Milestone 3.0 for both issue & PR)
Development

Successfully merging a pull request may close this issue.

1 participant