Formalize representation of software dependencies
See original GitHub issueHere is a proposal for describing software dependencies. Feedback is welcome.
The CodeMeta context file currently defines the single JSON property ‘dependency’ to express software dependencies for a package. This should be expanded so that dependencies can be expressed in a more standard way. One possibility is to use “packageId”, “packageVersion”, “packageSystem”, “operatingSystem” where
- packageId: the unique identifier for the package
- version: a character string indicating the build / state of the software
- packageSystem: the software or system used for packaging
- operatingSystem: the platforms the package has been build and bundled for (optional)
for example:
"dependency":[
"packageId":"npplus",
"version": "0.9.4",
"packageSystem":"https://pypi.python.org",
},
{
"packageId":"statistics",
"version":"1.4.3",
"packageSystem":"https://pypi.python.org",
}
],
Another example:
"dependency":[
{
"packageId":"abd",
"version":"0.2-8",
"packageSystem":"http://cran.r-project.org",
"operatingSystem":"Windows, Mac OS X"
}
{
"packageId":"popbio",
"version":"2.4.3",
"packageSystem":"http://cran.r-project.org",
"operatingSystem":"Windows, Mac OS X"
}
],
A value for operatingSystem
is specified when required, for example, the operating system
isn’t relevant for software distributed as Python packages or Matlab Central contributed
files, as those software packages are dependant on their execution environment (python, matlab)
and not the OS directly.
The packageSystem
would serve as a namespace of sorts, as the values for packageId
and operatingSystem
are specified as required by the packageSystem
.
‘version’ would be optional and if omitted, the most currently available version would be assumed.
Issue Analytics
- State:
- Created 7 years ago
- Comments:13 (10 by maintainers)
@alee Yes, the term
softwareRequirements
is part of codemeta and schema.org; codemeta also provides the additional termsoftwareSuggestions
to distinguish between hard dependencies and other things (build dependencies , optional extensions etc). The list of terms can be found in https://codemeta.github.io/terms/.side note: The developer guide is mostly focused on introducing the JSON-LD concepts, and doesn’t describe all the terms themselves. “developer guide” and “user guide” should perhaps be renamed to “consume” and “create”, since the dev guide is really aimed at developers who are writing tools that parse lots of codemeta files, not developers wishing to generate a codemeta file for their own software (which is what the user guide is supposed to cover). Of course, feedback/edits/PRs on all of this more than welcome – this is very much a community-driven project
Hi there, I looked at the developer guide at https://codemeta.github.io/developer-guide/ but there is no mention of dependencies there - is that still part of codemeta or did those docs move somewhere?