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

Remove reference to RO-Crate context from the JSON(LD) files #28

Merged
merged 1 commit into from
Jul 22, 2024

Conversation

simleo
Copy link
Contributor

@simleo simleo commented Jul 19, 2024

This form of the JSON(LD) files:

{
    "@context": [
        "https://w3id.org/ro/crate/1.1/context",
        {
            "ParameterConnection": "https://w3id.org/ro/terms/workflow-run#ParameterConnection",
            "ContainerImage": "https://w3id.org/ro/terms/workflow-run#ContainerImage",
...

Is a leftover of the first JSON files I generated when I initially wrote the Python script. The intention back then was to generate something that one could copy and paste in their ro-crate-metadata.json (possibly with a manual change of the RO-Crate version tag), but now we have actually valid context files that one can reference in their own context:

 {
    "@context": [
        "https://w3id.org/ro/crate/1.1/context",
        "https://w3id.org/ro/terms/workflow-run/context"
    ],
    "@graph": [
...

Unfortunately the above does not work, since the RO-Crate context is referenced twice: directly and then indirectly through the workflow-run context. This makes the workflow-run context unusable with RO-Crate versions other than the hardcoded one. Even if the RO-Crate version is the same, including the RO-Crate context leads to "recursive context inclusion" crashes with rdflib. See RDFLib/rdflib#2778.

This PR modifies the context files as well as the Python script that generates them to remove the reference to the RO-Crate context, so that they can be safely referenced in RO-Crates.

@simleo simleo merged commit 5c7a33b into master Jul 22, 2024
@simleo simleo deleted the rm_rocrate_ctx branch July 22, 2024 09:06
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.

1 participant