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

URIs for Resource Types vocabulary not being loaded #1531

Closed
mjordan opened this issue Jun 1, 2020 · 4 comments
Closed

URIs for Resource Types vocabulary not being loaded #1531

mjordan opened this issue Jun 1, 2020 · 4 comments
Assignees

Comments

@mjordan
Copy link
Contributor

mjordan commented Jun 1, 2020

External URIs listed for the resource_types vocabulary in https://github.com/Islandora/islandora_defaults/blob/8.x-1.x/migrate/tags.csv are not being loaded. That vocabulary doesn't have an 'external_uri' field, it has 'field_authority_link' field. We should change the vocabulary's default configuration so that it uses 'field_external_uri' instead of 'field_authority_link'.

@seth-shaw-unlv
Copy link
Contributor

The resource_types vocabulary was recently updated to use field_authority_link instead of field_external_authority_link to bring it in line with the other vocabularies provided by the controlled_access_terms module. I would hesitate to break the consistency we just fixed.

Perhaps we should make a comparable migration on the controlled_access_terms module for values we are confident in pre-loading and move those lines there?

@mjordan
Copy link
Contributor Author

mjordan commented Jun 2, 2020

Whatever is the best (and agreed, most consistent) way of registering the URIs we provide in the default config.

@kayakr
Copy link
Contributor

kayakr commented Mar 23, 2021

At the moment islandora_defaults module runs a migration that populates the resource_types vocabulary that is created by controlled_access_terms module. resource_types has field_authority_link whereas the migration expects to populate field_external_uri, per https://github.com/Islandora/islandora_defaults/blob/8.x-1.x/config/install/migrate_plus.migration.islandora_defaults_tags.yml#L25

In practice, that means resources_types is not populated with any URIs at all.

IMO, the issue is that a common islandora_defaults migration is targeting two vocabularies via tags.csv: islandora_display that uses field_external_uri and resource_types that uses field_authority_link.
If responsibility was moved to controlled_access_terms to populate terms into resource_types, then it could have its own migration targeting field_authority_link.

@kayakr
Copy link
Contributor

kayakr commented Apr 14, 2021

A quick hack to populate islandora_display using field_external_uri and resource_types that uses field_authority_link is to simply target both fields at once:

langcode: en
status: true
dependencies:
  enforced:
    module:
      - islandora_defaults
id: islandora_defaults_tags
class: null
field_plugin_method: null
cck_plugin_method: null
migration_tags:
  - islandora_defaults_tags
migration_group: islandora
label: 'Tags migration for islandora_defaults feature'
source:
  plugin: csv
  path: modules/contrib/islandora_defaults/migrate/tags.csv
  header_row_count: 1
  ids:
    - external_uri
process:
  name: name
  vid: vid
  description: description
  field_external_uri:
    plugin: urlencode
    source: external_uri
  field_authority_link:
    plugin: urlencode
    source: external_uri
destination:
  plugin: 'entity:taxonomy_term'
migration_dependencies:
  required: {  }
  optional: {  }

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

5 participants