Skip to content
Merged
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
82 changes: 82 additions & 0 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
name: Pull Request CI

on:
pull_request:

permissions:
contents: read

concurrency:
group: pr-ci-${{ github.event.pull_request.number }}
cancel-in-progress: true

jobs:
regression:
name: Regression
runs-on: ubuntu-24.04
timeout-minutes: 30

steps:
- name: Checkout
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8

- name: Set up Python 3.14
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405
with:
python-version: "3.14"

- name: Install testing dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -e '.[testing]'

- name: Run regression tests
run: |
python -m pytest tests \
-m regression \
-vv \
--durations=20 \
--basetemp=.testdata

- name: Upload regression artefacts on failure
if: failure()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: pr-regression-failure
path: .testdata/
if-no-files-found: ignore
include-hidden-files: true
retention-days: 7

docs:
name: Docs
runs-on: ubuntu-24.04
timeout-minutes: 20

steps:
- name: Checkout
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8

- name: Set up Python 3.14
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405
with:
python-version: "3.14"

- name: Install documentation dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -r docs/requirements.txt

- name: Build documentation
run: |
make -C docs clean
make -C docs html SPHINXOPTS="-W --keep-going"

- name: Upload documentation
if: success()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: docs-html
path: docs/build/html/
if-no-files-found: error
retention-days: 7
54 changes: 54 additions & 0 deletions .github/workflows/regression-tests.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: Regression Tests

on:
push:
branches:
- main
schedule:
- cron: "0 8 * * 1"
workflow_dispatch:

permissions:
contents: read

concurrency:
group: sist-regression-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
regression:
name: SIST Regression
runs-on: ubuntu-24.04
timeout-minutes: 30

steps:
- name: Checkout
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8

- name: Set up Python 3.14
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405
with:
python-version: "3.14"

- name: Install testing dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -e '.[testing]'

- name: Run regression tests
run: |
python -m pytest tests \
-m regression \
-vv \
--durations=20 \
--basetemp=.testdata

- name: Upload regression artefacts on failure
if: failure()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: sist-regression-failure
path: .testdata/
if-no-files-found: ignore
include-hidden-files: true
retention-days: 7
32 changes: 24 additions & 8 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,32 +1,34 @@
# Default ignored files
/shelf/
/workspace.xml

# Editor-based HTTP Client requests
/httpRequests/

# Datasource local storage ignored files
/dataSources/
/dataSources.local.xml

# Prerequisites
*.d

# Compiled Object files
# Compiled object files
*.slo
*.lo
*.o
*.obj

# Precompiled Headers
# Precompiled headers
*.gch
*.pch

# Linker files
*.ilk

# Debugger Files
# Debugger files
*.pdb

# Compiled Dynamic libraries
# Compiled dynamic libraries
*.so
*.dylib
*.dll
Expand All @@ -35,7 +37,7 @@
*.mod
*.smod

# Compiled Static libraries
# Compiled static libraries
*.lai
*.la
*.a
Expand All @@ -46,13 +48,27 @@
*.out
*.app

# debug information files
# Debug information files
*.dwo

# Build directories
build/
dist/
cmake-build-*/

# Sphinx build output
docs/build/
docs/source/_autosummary/

# Python cache
# Python environments, caches, and packaging
.venv/
venv/
__pycache__/
*.pyc
*.py[cod]
.pytest_cache/
.ruff_cache/
*.egg-info/

# Regression test artefacts
.testdata/
test-results/
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,4 +38,4 @@
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output

html_theme = 'furo'
html_static_path = ['_static']
# html_static_path = ['_static']
36 changes: 36 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
[build-system]
requires = ["setuptools>=77,<84"]
build-backend = "setuptools.build_meta"

[project]
name = "SIST"
version = "0.0.1"
description = "Stress-Induced Structural Transitions in superhelical DNA."
readme = "README.md"
requires-python = ">=3.12"
dependencies = []

maintainers = [
{ name = "Harry Swift", email = "harry.swift@stfc.ac.uk" },
]

[project.urls]
Repository = "https://github.com/CCPBioSim/SIST"

[project.optional-dependencies]
testing = [
"pytest>=9.0,<10.0",
]

[tool.setuptools]
# SIST is currently a Perl/C++ application. This metadata manages the Python
# test harness and its development dependencies; it does not package SIST.
packages = []

[tool.pytest.ini_options]
testpaths = ["tests"]
addopts = "-ra"
markers = [
"regression: end-to-end regression tests against reference outputs",
"slow: long-running tests excluded from the default test suite",
]
Loading