diff --git a/.circleci/config.yml b/.circleci/config.yml index ee82d5b003..676383d1f1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -174,8 +174,7 @@ jobs: docker: - image: cimg/base:stable steps: - - setup_remote_docker: - version: 17.11.0-ce + - setup_remote_docker # checkout code to default ~/project - checkout - attach_workspace: diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md index fa9d6566cf..b6be304f5b 100644 --- a/.github/pull_request_template.md +++ b/.github/pull_request_template.md @@ -2,27 +2,52 @@ See the [CONTRIBUTING](https://github.com/bids-standard/bids-specification/blob/master/CONTRIBUTING.md) guide. Specifically: -- Please keep the title of your Pull Request (PR) short but informative - it will - appear in the changelog. +- Please keep the title of your Pull Request (PR) short but informative - it will appear in the changelog. - If you do **not** want a PR to appear in the changelog, it must receive the `exclude-from-changelog` label. -- Please ensure your name is credited on our [Contributors appendix](https://github.com/bids-standard/bids-specification/blob/master/src/appendices/contributors.md). - To add your name, please edit our [Contributors wiki](https://github.com/bids-standard/bids-specification/wiki/Contributors) and add your name with the type of contribution. + +- Please ensure your name is credited + on our [Contributors appendix](https://github.com/bids-standard/bids-specification/blob/master/src/appendices/contributors.md). + To add your name, please edit our [Contributors wiki](https://github.com/bids-standard/bids-specification/wiki/Contributors) + and add your name with the type of contribution. For assistance, please tag @bids-standard/maintainers. + - Use one of the following prefixes in the title of your PR: - - `[ENH]` - enhancement of the specification that adds a new feature or - support for a new data type + - `[ENH]` - enhancement of the specification that adds a new feature or support for a new data type - `[FIX]` - fix of a typo or language clarification - - `[INFRA]` - changes to the infrastructure automating the specification - release (for example building HTML docs) + - `[INFRA]` - changes to the infrastructure automating the specification release (for example building HTML docs) - `[SCHEMA]` - changes to the BIDS schema and/or related code - - `[MISC]` - everything else including changes to the file listing - contributors -- If you are opening a PR to obtain early feedback, but the changes - are not ready to be merged (also known as a "Work in Progress" PR), please - use a [Draft PR](https://github.blog/2019-02-14-introducing-draft-pull-requests/). -- After opening the PR, our continuous integration services will automatically check your contribution for formatting errors and render a preview of the BIDS specification with your changes. + - `[MISC]` - everything else including changes to the file listing contributors + +- If you are opening a PR to obtain early feedback, + but the changes are not ready to be merged (also known as a "Work in Progress" PR), + please use a [Draft PR](https://github.blog/2019-02-14-introducing-draft-pull-requests/). + +- After opening the PR, our continuous integration services will automatically check your contribution + for formatting errors and render a preview of the BIDS specification with your changes. To see the checks and preview, scroll down and click on the `show all checks` link. - From the list, select the `Details` link of the `ci/circleci: build_docs artifact` check to see the preview of the BIDS specification. -- If you are updating the schema *and* you need to subsequently make changes to the bidsschematools code (validation, tests, rendering), this means your PR probably introduces a compatibility breaking change and you should increment the minor version (the second number) in `bids-specification/src/schema/SCHEMA_VERSION`. + From the list: + - select the `Details` link of the `docs/readthedocs.org:bids-specification` check to see the HTML preview of the BIDS specification. + - select the `Details` link of the `Check the rendered PDF version here! ` check to see the PDF preview of the BIDS specification. + +- If you are updating the schema *and* you need to subsequently make changes to the bidsschematools code (validation, tests, rendering), + this means your PR probably introduces a compatibility breaking change + and you should increment the minor version (the second number) in `bids-specification/src/schema/SCHEMA_VERSION`. + +- If you are opening a PR for a BIDS extension proposal (BEP), + make sure that your top message contains the following notes + +> [!Note] +> +> **We meet regularly to discuss this BEP** +> +> Next meeting: **insert date** on **URL to join** +> +> Communication channel on github repo / matrix / slack / discord : **insert URL to join** +> + +> [!Tip] +> +> [**HTML preview of this BEP**](insert URL to HTML preview once available) +> --- PLEASE READ AND DELETE THE TEXT ABOVE BEFORE OPENING THE PULL REQUEST --- diff --git a/.github/workflows/schemacode_ci.yml b/.github/workflows/schemacode_ci.yml index 6cf4dbcd4c..0b92cd9a4d 100644 --- a/.github/workflows/schemacode_ci.yml +++ b/.github/workflows/schemacode_ci.yml @@ -33,7 +33,7 @@ jobs: - name: "Install build dependencies" run: pip install --upgrade build twine - name: "Install test dependencies on tag" - run: pip install --upgrade pytest pyyaml pandas tabulate markdown-it-py pyparsing + run: pip install --upgrade tools/schemacode[test] if: ${{ startsWith(github.ref, 'refs/tags/schema-') }} - name: "Build archive on tag" run: pytest tools/schemacode/bidsschematools -k make_archive diff --git a/src/common-principles.md b/src/common-principles.md index 3d9bc233af..08ef8e6a4f 100644 --- a/src/common-principles.md +++ b/src/common-principles.md @@ -658,6 +658,21 @@ for more information. ## The Inheritance Principle +In some circumstances, there can be multiple data files for which +all or a subset of the relevant metadata is precisely equivalent. +Where this occurs, +it may be preferable to define those metadata *only once*, +and be placed on the filesystem in such a way that those files +are deemed to be *applicable* to each relevant data file individually, +but *not* be erroneously associated with other data files +to which the metadata contained within are not applicable. +The Inheritance Principle defines a systematized set of rules +to determine which metadata files to associate with which data files. +Further, because multiple metadata files may apply to an individual data file, +the Principle defines the *order of precedence* of such metadata files contents. + +### Rules + 1. Any metadata file (such as `.json`, `.bvec` or `.tsv`) MAY be defined at any directory level. 1. For a given data file, any metadata file is applicable to that data file if: @@ -687,7 +702,7 @@ for more information. same key present in another metadata file at a lower level (though it is RECOMMENDED to minimize the extent of such overrides). -Corollaries: +### Corollaries 1. As per rule 3, metadata files applicable only to a specific participant / session MUST be defined in or below the directory corresponding to that participant / session; @@ -704,6 +719,8 @@ Corollaries: a key-value in a later file does not imply the "unsetting" of that field (indeed removal of existing fields is not possible). +### Examples + Example 1: Demonstration of inheritance principle -{{ MACROS___make_suffix_table( - [ - "dwi", - "sbref", - ] - ) -}} +{{ MACROS___make_suffix_table(["dwi", "sbref"]) }} + +Additionally, the following suffixes are used for scanner-generated images: + + +{{ MACROS___make_suffix_table(["ADC", "TRACE"]) }}