Compare commits

...
Sign in to create a new pull request.

30 commits

Author SHA1 Message Date
Benjamin A. Beasley
a5c98aa1fa Update to 1.1.5 (close RHBZ#2429338) 2026-01-14 11:48:43 +00:00
Benjamin A. Beasley
2c727abc05 Update to 1.1.4 (close RHBZ#2423779) 2025-12-19 07:18:01 +00:00
Benjamin A. Beasley
927a74bf65 Update to 1.1.3 (close RHBZ#2415638) 2025-11-18 21:38:08 +00:00
Benjamin A. Beasley
9c41b5cc64 Update to 1.1.2 (close RHBZ#2407439) 2025-10-30 21:06:40 +00:00
Benjamin A. Beasley
7c9f6ed65e Update to 1.1.1 (close RHBZ#2406894) 2025-10-28 21:22:53 +00:00
Python Maint
cfebcbe529 Rebuilt for Python 3.14.0rc3 bytecode 2025-09-19 12:08:43 +02:00
Benjamin A. Beasley
4b1a872560 Update to 1.1.0 (close RHBZ#2392899) 2025-09-05 08:10:53 +01:00
Benjamin A. Beasley
07fbe3a5ea Update to 1.0.14 (close RHBZ#2388666) 2025-08-15 07:10:40 -04:00
Python Maint
1b83fa9a2d Rebuilt for Python 3.14.0rc2 bytecode 2025-08-15 12:39:45 +02:00
Benjamin A. Beasley
eeebf75b31 Update to 1.0.13 (close RHBZ#2387162) 2025-08-12 18:22:12 -04:00
Benjamin A. Beasley
ac68ccbb61 Update to 1.0.12 (close RHBZ#2386327) 2025-08-04 13:36:57 -04:00
Benjamin A. Beasley
adf34a1804 Update to 1.0.11 (close RHBZ#2385888) 2025-08-01 07:15:46 -04:00
Fedora Release Engineering
7ea5af4cba Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild 2025-07-23 17:40:59 +00:00
Python Maint
fe35e19593 Rebuilt for Python 3.14 2025-06-04 21:29:49 +02:00
Benjamin A. Beasley
625d8c9d19 Update to 1.0.10 (close RHBZ#2370055) 2025-06-03 14:08:35 -04:00
Benjamin A. Beasley
00515d84c7 Update to 1.0.9 (close RHBZ#2368112) 2025-05-22 17:33:26 -04:00
Benjamin A. Beasley
53595880b6 Update to 1.0.8 (close RHBZ#2366945) 2025-05-16 17:58:31 -04:00
Benjamin A. Beasley
5d5b52ceb2 Update to 1.0.7 (close RHBZ#2366830) 2025-05-16 11:45:36 -04:00
Benjamin A. Beasley
425003f943 Update .rpmlintrc file for a new rpmlint version 2025-04-24 16:43:44 -04:00
Benjamin A. Beasley
1dd1b6ecb5 Update to 1.0.5 (close RHBZ#2359774) 2025-04-15 11:08:41 -04:00
Benjamin A. Beasley
2fa87b4d6e Update to 1.0.4 (close RHBZ#2353951) 2025-03-22 07:28:59 -04:00
Benjamin A. Beasley
dc49b919a3 Update to 1.0.3 (close RHBZ#2346980) 2025-02-21 13:09:12 -05:00
Benjamin A. Beasley
fa99cfbdca De-conditionalize the "render" extra 2025-02-21 13:04:02 -05:00
Benjamin A. Beasley
94b1c97237 Update to 1.0.2 (close RHBZ#2344674) 2025-02-10 11:40:40 -05:00
Benjamin A. Beasley
da44210be8 Update to 1.0.1 (close RHBZ#2344086) 2025-02-05 18:51:55 -05:00
Fedora Release Engineering
f7f100eaa4 Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild 2025-01-16 12:28:18 +00:00
Benjamin A. Beasley
bf8e9a5ac8 Trivial improvements to the get_test_data script
[skip changelog]
2025-01-02 09:03:26 -05:00
Benjamin A. Beasley
ecb022c0ae Add a SourceLicense field 2024-12-11 16:08:02 -05:00
Benjamin A. Beasley
fffdb3825a Update to 1.0.0 (close RHBZ#2330678) 2024-12-05 23:33:41 -05:00
Benjamin A. Beasley
b8106afae6 Update spec-file comment: python-tabluate is now in EPEL10
[skip changelog]
2024-12-05 23:28:53 -05:00
5 changed files with 66 additions and 68 deletions

31
.gitignore vendored
View file

@ -6,3 +6,34 @@
/bids-specification-schema-0.11.3.post2.tar.gz
/bids-specification-schema-0.11.3.post3.tar.gz
/bids-examples-507df6626dbbc555ae258ae286885d0a1b18391c-filtered.tar.zst
/bids-specification-schema-1.0.0.tar.gz
/bids-specification-schema-1.0.1.tar.gz
/bids-examples-e52f77fcd1abe7f234ecaec3542082279b043f8a-filtered.tar.zst
/bids-specification-schema-1.0.2.tar.gz
/bids-specification-schema-1.0.3.tar.gz
/bids-examples-5e6fa0ccba46c9701c4aba154b412542d616186c-filtered.tar.zst
/bids-specification-schema-1.0.4.tar.gz
/bids-examples-f21306744fd57bfd5c8e8e91d907fa8448f9eca5-filtered.tar.zst
/bids-specification-schema-1.0.5.tar.gz
/bids-specification-schema-1.0.7.tar.gz
/bids-specification-schema-1.0.8.tar.gz
/bids-specification-schema-1.0.9.tar.gz
/bids-specification-schema-1.0.10.tar.gz
/bids-examples-54355d2bbfec3fc126dd3cb80c3db9813505e3df-filtered.tar.zst
/bids-specification-schema-1.0.11.tar.gz
/bids-examples-e742618e66cce8fa16bf1066caa47d543508857c-filtered.tar.zst
/bids-specification-schema-1.0.12.tar.gz
/bids-specification-schema-1.0.13.tar.gz
/bids-examples-ce064b0868cf5ccd0098850be12e5205bedfa671-filtered.tar.zst
/bids-specification-schema-1.0.14.tar.gz
/bids-specification-schema-1.1.0.tar.gz
/bids-examples-546cb454ca33327fb27474edb508ead17c4053ac-filtered.tar.zst
/bids-specification-schema-1.1.1.tar.gz
/bids-examples-8f916644b973b44c946b7617e96b04b7be312f89-filtered.tar.zst
/bids-specification-schema-1.1.2.tar.gz
/bids-specification-schema-1.1.3.tar.gz
/bids-examples-0410c4114bd819c403309b1d210983ddbed271ec-filtered.tar.zst
/bids-specification-schema-1.1.4.tar.gz
/bids-examples-9d114380a6cf4c24526eb71259b3f52d43a08ad7-filtered.tar.zst
/bids-specification-schema-1.1.5.tar.gz
/bids-examples-c68d3afa54b3271d4718de7abf6cb6d5e603fceb-filtered.tar.zst

View file

@ -1,8 +1,3 @@
# It is normal that extras metapackages should not have documentation, or any
# files at all.
addFilter(r"\+\w+.noarch: W: no-documentation")
# This is not a spelling error
addFilter(r" spelling-error \('([Mm]etapackage)s?',")
# There are no URLs for these sources because we must generate them with scripts:
addFilter(r" invalid-url Source[1-9]: .*\.tar\.zst$")
# These are fine; rpmlint does not understand .tar.zst

View file

@ -1,10 +1,9 @@
# Missing dependencies in EPEL10:
# - python3dist(markdown-it-py)
# - python3dist(tabulate)
%bcond render %{undefined el10}
# Removable test dependency, not yet packaged:
# https://pypi.org/project/check-jsonschema
%bcond check_jsonschema 0
Name: bids-schema
Version: 0.11.3^post3
Version: 1.1.5
Release: %autorelease
Summary: BIDS schema description
@ -17,13 +16,15 @@ Summary: BIDS schema description
# https://github.com/bids-standard/bids-schema/raw/refs/heads/main/…
# versions/%%{bidsversion}/schema/SCHEMA_VERSION
# should match or nearly match the schema version packaged here.
%global bidsversion 1.10.0
%global bidsversion 1.10.1
# The specification, and the schema data derived from it, are CC-BY-4.0.
#
# The Python library in tools/schemacode/, packaged as python3-bidsschematools,
# is MIT.
License: CC-BY-4.0
# CC0-1.0 comes from the filtered test datasets, Source2 and Source3
SourceLicense: CC0-1.0 AND CC-BY-4.0 AND MIT
URL: https://github.com/bids-standard/bids-specification
# The PyPI sdist corresponds to the tools/schemacode directory in git.
Source0: %{url}/archive/schema-%{srcversion}/bids-specification-schema-%{srcversion}.tar.gz
@ -50,7 +51,7 @@ Source0: %{url}/archive/schema-%{srcversion}/bids-specification-schema-%{
# tools/schemacode/src/bidsschematools/conftest.py, which contains code to download
# these if they are not present.
%global examples_url https://github.com/bids-standard/bids-examples
%global examples_commit 507df6626dbbc555ae258ae286885d0a1b18391c
%global examples_commit c68d3afa54b3271d4718de7abf6cb6d5e603fceb
%global error_examples_url https://github.com/bids-standard/bids-error-examples
%global error_examples_commit ac0a2f58f34ce284847dde5bd3b90d7ea048c141
#
@ -83,6 +84,9 @@ BuildRequires: python3-devel
# https://docs.fedoraproject.org/en-US/packaging-guidelines/Python/#_linters,
# it is easier to enumerate test dependencies by hand.
BuildRequires: %{py3_dist pytest}
%if %{with check_jsonschema}
BuildRequires: %{py3_dist check-jsonschema}
%endif
%description
Portions of the BIDS specification are defined using YAML files in order to
@ -116,7 +120,7 @@ Features:
simple CLI bindings (e.g. bst export)
%pyproject_extras_subpkg -n python3-bidsschematools %{?with_render:render} expressions
%pyproject_extras_subpkg -n python3-bidsschematools validation render expressions
%prep
@ -136,7 +140,7 @@ rm -rf src/js/ src/css/
%generate_buildrequires
pushd tools/schemacode >/dev/null
%pyproject_buildrequires -x %{?with_render:render,}expressions
%pyproject_buildrequires -x validation,render,expressions
popd >/dev/null
@ -161,17 +165,21 @@ install -t '%{buildroot}%{_datadir}/bids-schema/versions/%{bidsversion}' \
pushd tools/schemacode >/dev/null
%pyproject_install
%pyproject_save_files -l bidsschematools
%pyproject_save_files -L bidsschematools
popd
# Include a copy of the “exported” JSON version of the schema in the base
# package to imitate the structure of
# https://github.com/bids-standard/bids-schema. See readthedocs.yml.
install -p -m 0644 \
-t '%{buildroot}%{_datadir}/bids-schema/versions/%{bidsversion}' \
'%{buildroot}%{python3_sitelib}/bidsschematools/data/schema.json'
# Unbundle the schema data from the Python library.
# Since the schema directory is replaced by a symbolic link into the base
# package, we must remove its contents from the files list, and we must remove
# the directory itself so that we can list it manually without %%dir.
sed -r -i '/\/bidsschematools\/data\/schema(\/|$)/d' %{pyproject_files}
for thing in metaschema.json schema
for thing in metaschema.json schema.json
do
rm -rv "%{buildroot}%{python3_sitelib}/bidsschematools/data/${thing}"
rm "%{buildroot}%{python3_sitelib}/bidsschematools/data/${thing}"
# Create an absolute symlink into the buildroot and then convert it to a
# relative one; the relative symlink works both in %%check and after the
# package is actually installed.
@ -181,14 +189,6 @@ do
symlinks -c -o "%{buildroot}%{python3_sitelib}/bidsschematools/data/${thing}"
done
# Generate and include a copy of the “exported” JSON version of the schema to
# imitate the structure of https://github.com/bids-standard/bids-schema. See
# readthedocs.yml. We do this in %%install rather than %%build because we need
# to use the generated “bst” entry point.
PYTHONDONTWRITEBYTECODE=1 PYTHONPATH='%{buildroot}%{python3_sitelib}' \
%{buildroot}%{_bindir}/bst -v export --output \
'%{buildroot}%{_datadir}/bids-schema/versions/%{bidsversion}/schema.json'
# Do not ship the tests.
sed -r -i '/\/bidsschematools\/tests(\/|$)/d' %{pyproject_files}
sed -r -i '/bidsschematools\.tests(\.|$)/d' '%{_pyproject_modules}'
@ -220,11 +220,7 @@ install -t '%{buildroot}%{_docdir}/python3-bidsschematools' -D -p -m 0644 \
verfile='%{_datadir}/bids-schema/versions/%{bidsversion}/schema/SCHEMA_VERSION'
[ '%{srcversion}' = "$(cat "%{buildroot}${verfile}")" ]
%pyproject_check_import %{?!with_render:-e bidsschematools.render*}
%if %{without render}
ignore="${ignore-} --ignore-glob=tools/schemacode/src/bidsschematools/tests/test_render_*"
%endif
%pyproject_check_import
# These tests require example files that were filtered out for license reasons.
k="${k-}${k+ and }not test_bids_datasets[hcp_example_bids]"
@ -237,35 +233,16 @@ ln -s "${PWD}/bids-examples-%{examples_commit}" \
tools/schemacode/tests/data/bids-examples
ln -s "${PWD}/bids-error-examples-%{error_examples_commit}" \
tools/schemacode/tests/data/bids-error-examples
# We also link the actual schema data, as unbundled and installed in the
# buildroot.
rm -rvf 'tools/schemacode/src/bidsschematools/data'
ln -s '%{buildroot}%{python3_sitelib}/bidsschematools/data' \
'tools/schemacode/src/bidsschematools/data'
# All of this manipulation is OK here in %%check because we already built the
# wheel and installed the library to the buildroot.
%if %{without check_jsonschema}
k="${k-}${k+ and }not test_valid_schema_with_check_jsonschema"
%endif
%pytest ${ignore-} -k "${k-}" -v
# https://docs.fedoraproject.org/en-US/packaging-guidelines/Directory_Replacement/#_scriptlet_to_replace_a_directory
# Added for F42; can be removed in F45 (upgrade path for three releases)
%pretrans -p <lua> -n python3-bidsschematools
path = "%{python3_sitelib}/bidsschematools/data/schema"
st = posix.stat(path)
if st and st.type == "directory" then
status = os.rename(path, path .. ".rpmmoved")
if not status then
suffix = 0
while not status do
suffix = suffix + 1
status = os.rename(path .. ".rpmmoved", path .. ".rpmmoved." .. suffix)
end
os.rename(path, path .. ".rpmmoved")
end
end
%files
%license LICENSE
%doc %dir %{_pkgdocdir}
@ -292,15 +269,10 @@ end
%files -n python3-bidsschematools -f %{pyproject_files}
%license tools/schemacode/LICENSE
%doc %dir %{_docdir}/python3-bidsschematools
%doc %{_docdir}/python3-bidsschematools/README.md
# Symbolic link into the appropriate directory in the base package:
%{python3_sitelib}/bidsschematools/data/schema
# https://docs.fedoraproject.org/en-US/packaging-guidelines/Directory_Replacement/#_scriptlet_to_replace_a_directory
# Added for F42; can be removed in F45 (upgrade path for three releases)
%ghost %{python3_sitelib}/bidsschematools/data/schema.rpmmoved
%{_bindir}/bst
%{_mandir}/man1/bst.1*
%{_mandir}/man1/bst-*.1*

View file

@ -18,12 +18,12 @@ OUTDIR="${PWD}"
TMPDIR="$(mktemp -d)"
trap "rm -rf '${TMPDIR}'" INT TERM EXIT
SPEC="$(cd "$(dirname $0)"; echo "${PWD}")/bids-schema.spec"
SPEC="$(cd "$(dirname "${0}")"; echo "${PWD}")/bids-schema.spec"
MACROS="$(grep -E '^%global' "${SPEC}")"
get_macro()
{
echo "$(rpm -E "${MACROS}
%{${1}}")"
rpm -E "${MACROS}
%{${1}}"
}
EX_URL="$(get_macro examples_url)"

View file

@ -1,3 +1,3 @@
SHA512 (bids-specification-schema-0.11.3.post3.tar.gz) = 483eeec3b333d0d8a1ad41f941e51b0e6fdb1c17501d19ce30cd117e68d12408a86d5ceed0a46ea0daa4210ad34b82737e47c664a1a51557ae782742a45e135f
SHA512 (bids-examples-507df6626dbbc555ae258ae286885d0a1b18391c-filtered.tar.zst) = 632c42ebcaabde85b7b17d3c1e231955b3f54d0fc51b7dd50fc2b26de4062a36ec77ca937e4c70bb5c0214928ee15a9d2731d785fd6f8f867eca1a5a0185f569
SHA512 (bids-error-examples-ac0a2f58f34ce284847dde5bd3b90d7ea048c141-filtered.tar.zst) = 3f70d1a8b922be232778470d01b8364b22f2373d053f9b709916e0023dc588bb40797ee145ccc072acee9e9c6a9e1aa07d26698b08a9377a442ac3dedd97fbec
SHA512 (bids-specification-schema-1.1.5.tar.gz) = 4bc394cff2f7cd966ca570609ecc3fc99996ff056c74e8bde482402f8e221bf863d9e90ce2a0383de64dc1102b671f79d9cb1232f4df7647b0d5d0992a01c4e1
SHA512 (bids-examples-c68d3afa54b3271d4718de7abf6cb6d5e603fceb-filtered.tar.zst) = dc269c261c2d9dda8ab66e3670575c2337d9c6d4d2dbc8ed3c8b2d119dcfd726fb75b8411cfd63b5d956ede7d94de74b9c4bcc157370b1d2b2a1d94ecab2dc9b
SHA512 (bids-error-examples-ac0a2f58f34ce284847dde5bd3b90d7ea048c141-filtered.tar.zst) = d6ce411fbc24259a6587cea189b7eb043e1267cee085346a0bda125a31a9081a518772e3b5f07ed3cae182cd6a2422eaa66d6ff5f5018dfa4212fe90d7365a12