Skip to content

Commit 5bfdd1e

Browse files
committed
backport changes from bioutils implementation
1 parent 85c1891 commit 5bfdd1e

File tree

5 files changed

+46
-35
lines changed

5 files changed

+46
-35
lines changed

.gitignore

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,15 @@
11
*$py.class
2+
*.bak
23
*.cover
34
*.egg
45
*.egg-info/
56
*.log
67
*.manifest
78
*.mo
9+
*.orig
810
*.pot
911
*.py.cover
12+
*.py[cod]
1013
*.py[codz]
1114
*.sage.py
1215
*.so
@@ -27,6 +30,7 @@
2730
.env
2831
.envrc
2932
.hypothesis/
33+
.idea
3034
.installed.cfg
3135
.ipynb_checkpoints
3236
.mypy_cache/
@@ -37,7 +41,9 @@
3741
.pybuilder/
3842
.pypirc
3943
.pyre/
44+
.pytest_cache
4045
.pytest_cache/
46+
.python-version
4147
.pytype/
4248
.ropeproject
4349
.ruff_cache/
@@ -55,6 +61,7 @@ __marimo__/
5561
__pycache__/
5662
__pypackages__/
5763
archive
64+
bioutils/_data/assemblies/pull
5865
build/
5966
celerybeat-schedule
6067
celerybeat.pid
@@ -64,6 +71,10 @@ cython_debug/
6471
develop-eggs/
6572
dist/
6673
dmypy.json
74+
doc/_build
75+
doc/changelog/*/.tags
76+
doc/changelog/*/.tags.mk
77+
doc/changelog/*/hg-git-remap.pl
6778
docs/_build/
6879
docs/source
6980
downloads/
@@ -78,6 +89,7 @@ lib64/
7889
local_settings.py
7990
marimo/_lsp/
8091
marimo/_static/
92+
misc
8193
nosetests.xml
8294
parts/
8395
pip-delete-this-directory.txt

.pre-commit-config.yaml

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ repos:
1313
- id: detect-private-key
1414
- id: end-of-file-fixer
1515
- id: mixed-line-ending
16-
args: [ --fix=lf ]
16+
args: [--fix=lf]
1717
- id: pretty-format-json
1818
exclude: ^.devcontainer/.*devcontainer.json
1919
args: [--autofix, --no-sort-keys]
@@ -23,7 +23,7 @@ repos:
2323
rev: "v0.12.7"
2424
hooks:
2525
- id: ruff-check
26-
args: [ --fix, --exit-non-zero-on-fix ]
26+
args: [--fix, --exit-non-zero-on-fix]
2727
- id: ruff-format
2828

2929
- repo: local
@@ -33,11 +33,3 @@ repos:
3333
entry: sh -c 'LC_ALL=C sort -u -o .gitignore .gitignore'
3434
language: system
3535
files: ^\.gitignore$
36-
37-
- repo: local
38-
hooks:
39-
- id: canonicalize-pyproject
40-
name: Ensure pyproject.toml in canonical order and format
41-
entry: uvx toml-sort --in-place --all pyproject.toml
42-
language: system
43-
files: ^pyproject.toml$

Makefile

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
# Makefile for Python project
2+
13
.DELETE_ON_ERROR:
24
.PHONY: FORCE
35
.PRECIOUS:
@@ -6,12 +8,6 @@
68
.DEFAULT_GOAL := help
79
default: help
810

9-
COLOR_RESET=\033[0m
10-
COLOR_CYAN_BOLD=\033[1;36m
11-
define INFO_MESSAGE
12-
@echo -e "⏩$(COLOR_CYAN_BOLD)$(1)$(COLOR_RESET)"
13-
endef
14-
1511
############################################################################
1612
#= BASIC USAGE
1713

@@ -41,7 +37,6 @@ publish: build ## publish package to PyPI
4137
$(call INFO_MESSAGE, "Publishing package")
4238
uv publish # Requires UV_PUBLISH_TOKEN or Trusted Publishing setup
4339

44-
4540
############################################################################
4641
#= FORMATTING, TESTING, AND CODE QUALITY
4742

@@ -50,7 +45,7 @@ cqa: ## Run code quality assessments
5045
$(call INFO_MESSAGE, "Checking lock file consistency")
5146
uv lock --locked
5247
$(call INFO_MESSAGE, "Linting and reformatting files")
53-
uv run pre-commit run -a
48+
uv run pre-commit run
5449
$(call INFO_MESSAGE, "Checking for obsolete dependencies")
5550
uv run deptry src
5651

mkdocs.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,14 @@ edit_uri: edit/main/docs/
77
repo_name: biocommons/python-package
88
copyright: Maintained by <a href="https://biocommons.com">biocommons</a>.
99

10-
nav:
11-
- Home: index.md
12-
- Modules: modules.md
1310
plugins:
1411
- search
12+
- awesome-nav
1513
- mkdocstrings:
1614
handlers:
1715
python:
18-
paths: ["src/biocommons/example"]
16+
options:
17+
show_source: false
1918
theme:
2019
name: material
2120
feature:

pyproject.toml

Lines changed: 26 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ requires = ["setuptools >= 70.1", "setuptools_scm[toml] ~= 8.1"]
55
[dependency-groups]
66
dev = [
77
"deptry>=0.23",
8+
"mkdocs-awesome-nav>=3.1.2",
89
"mkdocs-material>=9.6",
910
"mkdocs>=1.6",
1011
"mkdocstrings[python]>=0.30",
@@ -13,7 +14,8 @@ dev = [
1314
"pytest-cov>=4.1",
1415
"pytest>=7.4",
1516
"ruff>=0.12",
16-
"tox-uv>=1.28"
17+
"tox-uv>=1.28",
18+
"vcrpy"
1719
]
1820

1921
[project]
@@ -32,6 +34,13 @@ classifiers = [
3234
dependencies = ["coloredlogs ~= 15.0", "pyyaml ~= 6.0"]
3335
description = "biocommons.example package (namespaced)"
3436
dynamic = ["version"]
37+
keywords = [
38+
"HGVS",
39+
"biocommons",
40+
"bioinformatics",
41+
"genomics",
42+
"variation"
43+
]
3544
license = "Apache-2.0"
3645
name = "biocommons-example"
3746
readme = "README.md"
@@ -55,16 +64,19 @@ Repository = "https://github.com/biocommons/python-package"
5564

5665
[tool.coverage.report]
5766
exclude_lines = [
58-
# Don't complain about missing debug-only code:
59-
"def __repr__",
60-
# Don't complain if non-runnable code isn't run:
61-
"if __name__ == .__main__.:",
62-
"if self.debug",
63-
# Have to re-enable the standard pragma
64-
"pragma: no cover",
65-
# Don't complain if tests don't hit defensive assertion code:
66-
"raise AssertionError",
67-
"raise NotImplementedError"
67+
# Have to re-enable the standard pragma
68+
"pragma: no cover",
69+
70+
# Don't complain about missing debug-only code:
71+
"def __repr__",
72+
"if self.debug",
73+
74+
# Don't complain if tests don't hit defensive assertion code:
75+
"raise AssertionError",
76+
"raise NotImplementedError",
77+
78+
# Don't complain if non-runnable code isn't run:
79+
"if __name__ == .__main__.:",
6880
]
6981
show_missing = true
7082
skip_empty = true
@@ -182,11 +194,12 @@ select = [
182194
include-package-data = true
183195

184196
[tool.setuptools.package-data]
185-
"*" = ["*.gz", "*.json", "*.yaml"]
197+
# "*" = ["_data/*/*.json.gz"]
198+
# "*" = ["*.gz", "*.json", "*.yaml"]
186199

187200
[tool.setuptools.packages.find]
188201
exclude = ["*.pyc", "__pycache__"]
189-
namespaces = true
202+
# namespaces = true
190203
where = ["src"]
191204

192205
[tool.setuptools_scm]

0 commit comments

Comments
 (0)