1
0
Fork 0

dev-python/dandischema: new package (DANDI stack)

Package-Manager: Portage-3.0.23, Repoman-3.0.3
Signed-off-by: Horea Christian <chr@chymera.eu>
This commit is contained in:
Horea Christian 2021-09-26 22:40:22 -04:00
parent 4710e37363
commit 2b976fa6e5
No known key found for this signature in database
GPG Key ID: 161C0BE6255333D3
6 changed files with 101 additions and 0 deletions

View File

@ -0,0 +1,6 @@
*dandischema-0.3.4 (27 Sep 2021)
27 Sep 2021; <chymera@gentoo.org> +dandischema-0.3.4.ebuild,
+files/dandischema-0.3.4-coverage.patch,
+files/dandischema-0.3.4-versioningit.patch, +metadata.xml:
dev-python/dandischema: new package (DANDI stack)

View File

@ -0,0 +1 @@
DIST dandischema-0.3.4.tar.gz 47642 SHA256 f154b8c9f4e06cbf770241a1cfd75fabaa9e6f1dd4cac1554627e85ac4e93681 SHA512 764db251e47147b16d6beaecabf7b4610caf60f8bdaf6a4b05c084a6274d249aa340cb503912895812fcfad7a0c305cae5b2db3d590aeb69a8afd4e7068edf82 WHIRLPOOL bfe8edb5da25b5d45a8fb7df9acdb4797478e2329bde0738cf4af3c318bb7d73942de79a4b70f78e2ac90d67bf74d11f1c733db111d1d676537dddc5d1be882c

View File

@ -0,0 +1,51 @@
# Copyright 1999-2021 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{8..10} )
inherit distutils-r1
DESCRIPTION="Schemata for DANDI archive project"
HOMEPAGE="https://github.com/dandi/dandischema"
EGIT_REPO_URI="https://github.com/dandi/dandischema.git"
SRC_URI="https://github.com/dandi/dandischema/archive/refs/tags/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="test"
RESTRICT="!test? ( test )"
RDEPEND="
dev-python/wheel[${PYTHON_USEDEP}]
dev-python/jsonschema[${PYTHON_USEDEP}]
dev-python/pydantic[${PYTHON_USEDEP}]
dev-python/python-email-validator[${PYTHON_USEDEP}]
dev-python/requests[${PYTHON_USEDEP}]
"
DEPEND="
dev-python/setuptools[${PYTHON_USEDEP}]
"
PATCHES=(
"${FILESDIR}/${P}-coverage.patch"
"${FILESDIR}/${P}-versioningit.patch"
)
src_configure() {
echo "__version__ = '${PV}'" >> dandischema/_version.py
}
distutils_enable_tests pytest
python_test() {
local EPYTEST_DESELECT=(
# Requires network access:
# https://github.com/dandi/dandischema/issues/87
dandischema/tests/test_metadata.py::test_migrate_041
)
pushd dandischema || die
epytest tests
popd
}

View File

@ -0,0 +1,11 @@
--- a/tox.ini 2021-09-22 19:31:20.534576095 -0400
+++ b/tox.ini 2021-09-26 16:11:30.080164191 -0400
@@ -17,7 +17,7 @@
flake8 --config=setup.cfg {posargs} dandischema setup.py
[pytest]
-addopts = --cov=dandischema --tb=short --durations=10
+addopts = --tb=short --durations=10
filterwarnings = error
[coverage:run]

View File

@ -0,0 +1,10 @@
--- a/setup.py 2021-09-22 19:31:20.533576086 -0400
+++ b/setup.py 2021-09-23 07:42:02.856983656 -0400
@@ -21,7 +21,7 @@
# Give setuptools a hint to complain if it's too old a version
# Should match pyproject.toml
-SETUP_REQUIRES = ["setuptools >= 42.0.0", "versioningit ~= 0.1.0"]
+SETUP_REQUIRES = ["setuptools >= 42.0.0"]
# This enables setuptools to install wheel on-the-fly
SETUP_REQUIRES += ["wheel"] if "bdist_wheel" in sys.argv else []

View File

@ -0,0 +1,22 @@
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>gentoo@chymera.eu</email>
<name>Horea Christian</name>
</maintainer>
<maintainer type="project">
<email>sci@gentoo.org</email>
<name>Gentoo Science Project</name>
</maintainer>
<longdescription lang="en">
A Python library for maintaining and managing DANDI metadata schemata.
The library helps create and validate DANDI schema-compliant metadata
for Dandisets and assets. Every Dandiset and associated asset has a
metadata object that can be retrieved using the DANDI API. This
library uses Pydantic to implement all the metadata classes. Schemas
are generated on schema modifications and placed into this repository.
Dandischema generates JSON schema definitions and also an associated
context.json file for JSON-LD compliance of the metadata models.
</longdescription>
</pkgmetadata>