Repository navigation
Conversation
Codecov Report❌ Patch coverage is
☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Merging this PR will not alter performance1 warning
Comparing Footnotes |
98ad5ea to
4317734
Compare
|
Is this something where we should actually request an |
| self.crate.mainEntity.append_to( | ||
| "url", f"https://nf-co.re/{self.crate.name.replace('nf-core/', '')}/{url}/", compact=True | ||
| ) | ||
| self.crate.mainEntity.append_to("url", f"{org_website}/{pipeline_short_name}/{url}/", compact=True) |
There was a problem hiding this comment.
Are we happy to assume that non-nf-core pipeline webistes use this structure and have a pipelines.json file?
There was a problem hiding this comment.
Converting back to draft because I've got an idea to tackle this
By the way there's a fallback in the code.
Those are the main questions indeed. There are two URL fields in the manifest: |
There was a problem hiding this comment.
One regression and a few small things:
rocrate.py:194and:218: the template doesn't setdocsUrl, so nf-core pipelines use the default..rstrip("/")turns it intohttps://nf-co.re, so the Organization@id/urlandsdPublisherchange fromhttps://nf-co.re/. Every pipeline'sro-crate-metadata.jsonwould change at the next sync. Could the default stay as is, and the slash only be stripped when building paths?manifest.get(key, default)only falls back when the key is missing.docsUrl = ''ororganization = ''gives an empty@id. Usingmanifest.get("docsUrl") or "https://nf-co.re/"and computing it once would cover both.rocrate.py:239:topics = ["nf-core", "nextflow"]still tags every crate withnf-core.org_namewould fit the goal of the PR.- The new test checks only the Organization name and url. Assertions on
sdPublisher,mainEntity.url, the topics fetched from the mockedpipelines.json, and the default case would catch point 1.
This was generated assisted by Claude code and checked by me.
9bbca77 to
f5005aa
Compare
165fba8 to
d35a60b
Compare
|
Thanks @eduard-watchmaker !
|
There was a problem hiding this comment.
Thanks, all points are addressed. Fair point on the trailing slash, as the crates change on every sync anyway.
This was generated assisted by Claude code and checked by me.
Alternative to #4146
My goal here is to make the RO-Crates more accurate by using actual correct org details (URL and name) for 3rd-party orgs that use the nf-core tooling. RO-Crates are indeed automatically updated by nf-core at every template update and version bump. Fixing them every time is quite time consuming.
This time, rather than introducing template parameters, I hijack existing manifest values:
And simply use them instead of
https://nf-co.reandnf-core, while still defaulting to these values when the keys are not present in the manifest.This way, in usual nf-core pipelines, since these are not used, nothing changes. And external orgs now have the possibility to define them as they wish.
This makes the change much shorter, with far less maintenance burden than my previous attempt.
However, it expects:
docsUrlURL to have a/pipelines.jsonthat must be formatted the same way the nf-core one is<docsUrl>/$pipeline_name/$versionto be validPR checklist
CHANGELOG.mdis updateddocsis updated