beacon-v2 icon indicating copy to clipboard operation
beacon-v2 copied to clipboard

Missing "info" reference

Open M-casado opened this issue 1 year ago • 5 comments

I found a few references to info.json in the JSON Schemas, same as these ones of info.yaml in the YAML model.

I think in November these references were created, moving stuff from outside common definitions, but the file info.json and info.yaml seems to be missing in main, so the references from each of the other files resolve to nothing for now.

Just flagging it in case that file was missed in the latest commits.

M-casado avatar Jan 22 '25 16:01 M-casado

Hi @M-casado, Thanks for opening the issue. For the framework schemas the info.json file is here and it is resolved. The problem is for the model, which when we refactored the location of the info.json file, we removed the absolute path to the file and we added the relative path, which goes to the model common folder but doesn't have the info.json file, as it is expected to be in framework common folder. @mbaudis was your intention to add an additional info.json file in the model common folder when you refactored this? Or do we want to point to the framework folder relatively? Thanks!

costero-e avatar Feb 05 '25 11:02 costero-e

@costero-e Please check out https://github.com/ga4gh-beacon/beacon-v2/commit/102f047de120e2ed5b2b6d9aab27323b14e0d74d ... By accident I directly pushed to schema-urgent-fixes but should be fine. As noted in the commit I'm pretty sure that I'd added the missing file when refactoring the info refs but probably disappeared in branch reshuffling ╮(╯▽╰)╭

mbaudis avatar Feb 14 '25 08:02 mbaudis

Hi @mbaudis, yes, I see now is properly referenced and validated. But an error for schema validation shows up to me, for the reference of the ontologyTerm.json. For example, in defaultSchema.json for cohorts if I change the $ref from https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/common/ontologyTerm.json to "$ref": "../../../../framework/json/common/ontologyTerm.json", then, the problem is solved. I believe this should be changed as well in all the schemas. If you agree, I will raise an issue for that. Thanks.

costero-e avatar Feb 14 '25 16:02 costero-e

@costero-e Actually this comes (best guess) from someone editing the JSON files, not the yaml, when switching to local references (I don't think it was me since I never edit the JSON files but always the YAML ones & convert w/ bin/yamlrunnrer.py).

I saw this for the endpoints.json files (where the local $ref where now overwritten by the old ones) & removed them from the commit; didn't catch this one...

So:

  • fix this instance, please
  • have a look at the endpoints.yaml in the branch, please

Thanks!

mbaudis avatar Feb 14 '25 17:02 mbaudis

Hi @mbaudis, it looks like it was my fault, my JSON validator couldn't reach the absolute path URL and only could validate local files. Everything is OK either with relative or absolute paths. Sorry for the inconveniences! Oriol

costero-e avatar Feb 18 '25 09:02 costero-e

@costero-e Is this resolved -> close?

mbaudis avatar May 22 '25 07:05 mbaudis

Looks like this was solved in #227, so yes, resolved and I proceed to close.

costero-e avatar May 22 '25 08:05 costero-e