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

Deprecate source_url in favour of item_url #129

Open
axfelix opened this issue Jul 31, 2020 · 0 comments
Open

Deprecate source_url in favour of item_url #129

axfelix opened this issue Jul 31, 2020 · 0 comments

Comments

@axfelix
Copy link
Owner

axfelix commented Jul 31, 2020

Currently, we use a "source_url" field as a de facto item URL for export, and refer to it internally as "source_url" throughout. This is a legacy of beginning with oai_dc, in which item URLs were mostly frequently found in dc:source fields (even though this is arguably a violation of the DC guidelines, which specify that source should refer back to eg source material for the content, like a related item field, repository OAI implementations seem to contravene this across the board).

Now that we have a more consistent way of constructing item_url, we should probably deprecate this more fully. It's only used in a couple places in the exporter, where it is pulled to act as the canonical record source URL -- I think item_url could be a drop-in replacement here:

records_sql = """SELECT recs.record_id, recs.title, recs.title_fr, recs.pub_date, recs.series, recs.source_url,

['record_id', 'title', 'title_fr', 'pub_date', 'series', 'source_url', 'deleted', 'local_identifier',

It's used quite a bit more in the db interface code, mostly to pull dc:source: https://github.com/axfelix/frdr_harvest/blob/43bad15150241dcdc92615e332aa06bee073d011/harvester/DBInterface.py. These would take a little more care to clean up, making sure we keep using them as a fallback in some cases -- I'm not sure if we need to deprecate this field entirely, in case some repository is found to use it to link related identifiers, and ultimately I think we could probably just keep them and switch to defaulting to item_url in the exporter.

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

No branches or pull requests

1 participant