Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .copier-answers.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Changes here will be overwritten by Copier
_commit: 3a223c6
_commit: 9b579a3
_src_path: https://github.com/python-project-templates/base.git
add_docs: true
add_extension: python
Expand Down
32 changes: 31 additions & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
python-version: ["3.12"]

steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6

- uses: actions-ext/python/setup@main
with:
Expand All @@ -53,6 +53,7 @@ jobs:
- name: Build
run: make build

<<<<<<< before updating
# - name: Test
# run: make coverage
#
Expand All @@ -72,3 +73,32 @@ jobs:
# uses: codecov/codecov-action@v5
# with:
# token: ${{ secrets.CODECOV_TOKEN }}
=======
- name: Test
run: make coverage

- name: Upload test results (Python)
uses: actions/upload-artifact@v7
with:
name: test-results-${{ matrix.os }}-${{ matrix.python-version }}
path: junit.xml
if: ${{ always() }}

- name: Publish Unit Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
with:
files: '**/junit.xml'

- name: Upload coverage
uses: codecov/codecov-action@v6
with:
token: ${{ secrets.CODECOV_TOKEN }}

- name: Make dist
run: make dist

- uses: actions/upload-artifact@v7
with:
name: dist-${{matrix.os}}
path: dist
>>>>>>> after updating
2 changes: 1 addition & 1 deletion .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v6
- uses: actions-ext/python/setup@main
- run: |
sudo apt-get update
Expand Down
51 changes: 24 additions & 27 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ __pycache__/
*.exp
*.lib

# Rust
target

# Distribution / packaging
.Python
build/
Expand Down Expand Up @@ -55,26 +58,12 @@ junit.xml
.hypothesis/
.pytest_cache/

# Translations
*.mo
*.pot

# Django stuff:
# Django
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# PyBuilder
target/

# IPython
profile_default/
ipython_config.py
Expand All @@ -85,15 +74,12 @@ ipython_config.py
# pipenv
Pipfile.lock

# PEP 582; used by e.g. github.com/David-OConnor/pyflow
__pypackages__/

# Celery stuff
# Celery
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py
# Airspeed Velocity
.asv

# Environments
.env
Expand Down Expand Up @@ -126,11 +112,12 @@ dmypy.json
/site
index.md
docs/_build/
docs/src/_build/
docs/api
docs/index.md
docs/html
docs/index.md
docs/jupyter_execute
docs/src/_build/
docs/superpowers
index.md

# JS
Expand All @@ -141,13 +128,12 @@ js/node_modules
js/test-results
js/playwright-report
js/*.tgz
physics_workload/extension

# Jupyter
.ipynb_checkpoints
.autoversion
!physics_workload/extension/physics_workload.json
!physics_workload/extension/install.json
Untitled*.ipynb
physics_workload/extension
physics_workload/nbextension
physics_workload/labextension

Expand All @@ -157,8 +143,19 @@ physics_workload/labextension
# Rust
target

<<<<<<< before updating
# Project
staticfiles/
*.csv
*.xlsx
*/migrations/*
*/migrations/*
=======
# Hydra
outputs/
multirun/

# AI
ROADMAP.md
AGENTS.md
.github/hooks/sdlc.json
>>>>>>> after updating
18 changes: 18 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,24 @@ lints: lint
fix: fix-py fix-docs ## run all autoformatters
format: fix

<<<<<<< before updating
=======
################
# Other Checks #
################
.PHONY: check-dist check-types checks check

check-dist: ## check python sdist and wheel with check-dist
check-dist -v

check-types: ## check python types with ty
ty check --python $$(which python)

checks: check-dist

# Alias
check: checks
>>>>>>> after updating

#########
# TESTS #
Expand Down
60 changes: 49 additions & 11 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,15 +1,23 @@
[build-system]
requires = ["hatchling"]
build-backend="hatchling.build"
requires = [
"hatchling",
]
build-backend = "hatchling.build"

[project]
name = "physics-workload"
authors = [{name = "Sam Mangham", email = "s.mangham@soton.ac.uk"}]
authors = [
{name = "Sam Mangham", email = "s.mangham@soton.ac.uk"},
]
description = "Tool for managing staff teaching time."
readme = "README.md"
license = { text = "Apache-2.0" }
version = "0.1.0"
<<<<<<< before updating
requires-python = ">=3.11"
=======
requires-python = ">=3.10"
>>>>>>> after updating
keywords = []

classifiers = [
Expand All @@ -18,11 +26,11 @@ classifiers = [
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
]

dependencies = [
Expand Down Expand Up @@ -51,15 +59,16 @@ dependencies = [
develop = [
"build",
"bump-my-version",
"check-manifest",
"codespell>=2.4,<2.5",
"check-dist",
"codespell",
"hatchling",
"mdformat>=0.7.22,<0.8",
"mdformat",
"mdformat-tables>=1",
"pytest",
"pytest-cov",
"ruff",
"twine",
"ty",
"uv",
"wheel",
"django-fastdev",
Expand Down Expand Up @@ -93,6 +102,7 @@ branch = true
omit = [
"physics_workload/tests/integration/",
]

[tool.coverage.report]
exclude_also = [
"raise NotImplementedError",
Expand All @@ -109,32 +119,60 @@ artifacts = []
src = "/"

[tool.hatch.build.targets.sdist]
packages = ["physics_workload"]
packages = [
"physics_workload",
]

[tool.hatch.build.targets.wheel]
packages = ["physics_workload"]
packages = [
"physics_workload",
]

[tool.hatch.build.targets.wheel.shared-data]

[tool.pytest.ini_options]
addopts = ["-vvv", "--junitxml=junit.xml"]
addopts = [
"-vvv",
"--junitxml=junit.xml",
]
testpaths = "physics_workload/tests"

[tool.ruff]
line-length = 150

[tool.ruff.lint]
extend-select = ["I"]
extend-select = [
"I",
]

[tool.ruff.lint.isort]
combine-as-imports = true
default-section = "third-party"
<<<<<<< before updating
known-first-party = ["physics_workload", "app", "core", "users"]
section-order = ["future", "standard-library", "third-party", "first-party", "local-folder"]

[tool.ruff.lint.per-file-ignores]
"__init__.py" = ["F401", "F403"]
"*.py" = ["E731"]
=======
known-first-party = [
"physics_workload",
]
section-order = [
"future",
"standard-library",
"third-party",
"first-party",
"local-folder",
]

[tool.ruff.lint.per-file-ignores]
"__init__.py" = [
"F401",
"F403",
]
>>>>>>> after updating

[tool.yardang]
title = "Teaching Time Tool"
Expand Down