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

Setting prefix explicitly in excelparser #470

Merged

Conversation

francescalb
Copy link
Collaborator

@francescalb francescalb commented Sep 27, 2022

Description:

Prefix can now be set explicitly for imported ontologies in excelparser. Either only prefix of given ontology, or set common prefix for all ontologies with a given root in the base_iri. Importing subontologies is also corrected.

The following is an image of the ImportedOntologies excelsheet.
image

The following image shows two new tests added in the excelparser test, in which two new classes are added. Both of these are subclasses on the locally imported testontology, either from the first import or its subontology. Note that they are given the same prefix based on the base_iri_root. If base_iri_root is not given the given prefix is only set to the main ontology and not the indirect imports. If base_iri_root is given all ontologies with their base_iri starting with base_iri_root are given the same prefix.

image

Type of change:

  • Bug fix.
  • New feature.
  • Documentation update.

Checklist:

This checklist can be used as a help for the reviewer.

  • Is the code easy to read and understand?
  • Are comments for humans to read, not computers to disregard?
  • Does a new feature has an accompanying new test (in the CI or unit testing schemes)?
  • Has the documentation been updated as necessary?
  • Does this close the issue?
  • Is the change limited to the issue?
  • Are errors handled for all outcomes?
  • Does the new feature provide new restrictions on dependencies, and if so is this documented?

Comments:

Prefix can now be set explicitly for imported ontologies in excelparser.
Either only prefix of given ontology, or set common prefix for all
ontologies with a given root in the base_iri
@francescalb francescalb linked an issue Sep 27, 2022 that may be closed by this pull request
ontopy/excelparser.py Outdated Show resolved Hide resolved
@francescalb francescalb linked an issue Sep 30, 2022 that may be closed by this pull request
@francescalb francescalb marked this pull request as ready for review October 5, 2022 14:16
Copy link
Collaborator

@jesper-friis jesper-friis left a comment

Choose a reason for hiding this comment

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

Looks very nice

@CasperWA
Copy link
Contributor

@francescalb I think this can be merged, and then you can try to perform a release again using all the new bells and whistles :)

@francescalb francescalb merged commit a3e81f0 into master Oct 11, 2022
@francescalb francescalb deleted the 467-excel2onto-add-choice-of-prefix-for-imported-ontologies branch October 11, 2022 10:30
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.

excel2onto: Read catalog file for imported ontology excel2onto: add choice of prefix for imported ontologies
3 participants