Skip to content

Commit

Permalink
Chore: Bump Copier template
Browse files Browse the repository at this point in the history
  • Loading branch information
adrien-berchet committed Nov 7, 2024
1 parent 8ada604 commit 4548295
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 46 deletions.
2 changes: 1 addition & 1 deletion .copier-answers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ copyright_year: '2022'
distribution_name: region-grower
download_url: https://github.com/BlueBrain/region-grower
init_git: false
maintainer: Adrien Berchet
maintainer: Adrien Berchet (@adrien-berchet)
package_name: region_grower
project_description: Synthesize cells in a given spatial context.
project_name: Region Grower
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/run-tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.9", "3.10", "3.11", "3.12"]
min_versions: ["min_versions", "latest_versions"]
exclude:
- min_versions: "min_versions"
Expand Down
2 changes: 1 addition & 1 deletion AUTHORS.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Maintainer

Adrien Berchet
Adrien Berchet (@adrien-berchet)

# Contributors
9 changes: 5 additions & 4 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,11 @@

# -- Project information -----------------------------------------------------

project = "Region Grower"
project_name = "Region Grower"
package_name = "region-grower"

# The short X.Y version
version = metadata.version("region-grower")
version = metadata.version(package_name)

# The full version, including alpha/beta/rc tags
release = version
Expand Down Expand Up @@ -63,10 +64,10 @@
# html_static_path = ['_static']

html_theme_options = {
"metadata_distribution": "region-grower",
"metadata_distribution": package_name,
}

html_title = project
html_title = project_name

# If true, links to the reST sources are added to the pages.
html_show_sourcelink = False
Expand Down
31 changes: 12 additions & 19 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,10 @@
"""Setup for the region-grower package."""

import importlib.util
from pathlib import Path

from setuptools import find_namespace_packages
from setuptools import setup

spec = importlib.util.spec_from_file_location(
"region_grower.version",
"region_grower/version.py",
)
module = importlib.util.module_from_spec(spec)
spec.loader.exec_module(module)
VERSION = module.VERSION

reqs = [
"attrs>=19.3.0",
"click>=8.0",
Expand All @@ -37,7 +28,7 @@
]

doc_reqs = [
"docutils<0.21", # Temporary fix for m2r2
"docutils<0.21",
"m2r2",
"sphinx",
"sphinx-bluebrain-theme",
Expand All @@ -59,20 +50,22 @@

setup(
name="region-grower",
author="bbp-ou-cells",
author_email="",
author="Blue Brain Project, EPFL",
description="Synthesize cells in a given spatial context.",
long_description=Path("README.md").read_text(encoding="utf-8"),
long_description_content_type="text/markdown",
url="https://bbpteam.epfl.ch/documentation/projects/region-grower",
url="https://region-grower.readthedocs.io",
project_urls={
"Tracker": "https://bbpteam.epfl.ch/project/issues/projects/CELLS/issues",
"Source": "https://bbpgitlab.epfl.ch/neuromath/region-grower",
"Tracker": "https://github.com/BlueBrain/region-grower/issues",
"Source": "https://github.com/BlueBrain/region-grower",
},
license="BBP-internal-confidential",
license="Apache License 2.0",
packages=find_namespace_packages(include=["region_grower*"]),
python_requires=">=3.8",
version=VERSION,
python_requires=">=3.9",
use_scm_version=True,
setup_requires=[
"setuptools_scm",
],
install_requires=reqs,
extras_require={
"docs": doc_reqs,
Expand All @@ -91,10 +84,10 @@
"Intended Audience :: Science/Research",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Scientific/Engineering :: Bio-Informatics",
],
)
32 changes: 12 additions & 20 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,20 @@ files = {[base]name} tests docs/source/conf.py setup.py

[tox]
envlist =
check-version
check-packaging
lint
docs
min_versions
py{39,310,311}
py{39,310,311,312}
coverage

minversion = 3.18

[testenv]
extras =
test
extras = test
setenv =
COVERAGE_FILE = {env:COVERAGE_FILE:.coverage-{envname}}
deps =
min_versions: Requirements-Builder
commands =
min_versions: requirements-builder --level=min --extras=test -o {envtmpdir}/requirements_min.txt setup.py
min_versions: pip install -r {envtmpdir}/requirements_min.txt
min_versions: pip freeze
pytest \
--basetemp={envtmpdir} \
--cov={[base]name} \
Expand Down Expand Up @@ -53,20 +46,12 @@ commands = mpiexec -n 4 {envbindir}/python tests/test_synthesize_morphologies.py
[testenv:coverage]
skip_install = true
deps = coverage
allowlist_externals =
/bin/bash
allowlist_externals = /bin/bash
commands =
/bin/bash -c 'coverage combine .coverage-py*'
coverage xml
coverage report

[testenv:check-version]
skip_install = true
deps = bbp-nse-ci>=0.2.5
commands =
do_release.py -p . check-version
do_release.py -p . check-changelog --release-only --path CHANGELOG.md

[testenv:check-packaging]
skip_install = true
deps =
Expand All @@ -78,6 +63,12 @@ commands =

[testenv:min_versions]
basepython = python3.9
deps =
Requirements-Builder
commands_pre =
requirements-builder --level=min --extras=test -o {envtmpdir}/requirements_min.txt setup.py
pip install -r {envtmpdir}/requirements_min.txt
pip freeze

[testenv:lint]
basepython = python3.9
Expand Down Expand Up @@ -108,6 +99,7 @@ commands = make html SPHINXOPTS=-W

[gh-actions]
python =
3.9: py39, lint, docs
3.9: py39, lint
3.10: py310, check-packaging
3.11: py311
3.11: py311, docs
3.12: py312

0 comments on commit 4548295

Please sign in to comment.