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
9 changes: 8 additions & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,10 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-14]
os: [ubuntu-latest, macos-14, windows-latest]
# ubuntu-latest = Linux x86_64
# macos-14 = macOS arm64 (Apple Silicon)
# windows-latest = Windows x86_64 (MSVC)

steps:
- uses: actions/checkout@v5
Expand Down Expand Up @@ -83,6 +84,12 @@ jobs:
# macOS arm64 only on macos-14 runner
CIBW_ARCHS_MACOS: "native"
CIBW_ARCHS_LINUX: "x86_64"
CIBW_ARCHS_WINDOWS: "AMD64"

# Windows: OGDF has deep include paths and MSVC still honours the
# 260-character MAX_PATH limit in places, so build in a short
# directory instead of cibuildwheel's temp dir.
CIBW_ENVIRONMENT_WINDOWS: 'SKBUILD_BUILD_DIR="C:/tb/{wheel_tag}"'

- uses: actions/upload-artifact@v5
with:
Expand Down
39 changes: 39 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ on:
branches: [main, master, visualization]
pull_request:
branches: [main, master]
workflow_dispatch: # manual trigger, also runs the Windows job
schedule:
- cron: "0 3 * * 1" # weekly, Monday 03:00 UTC; runs the Windows job

# Cancel in-progress runs when a new push is made
concurrency:
Expand Down Expand Up @@ -78,6 +81,42 @@ jobs:
- name: Run all tests
run: python -m pytest -v

# Full tests with OGDF layout on Windows (MSVC). Building OGDF from source
# takes 20-30 minutes, so this runs only on manual trigger or on schedule,
# not on every push/PR. Not required for PRs to be mergeable.
pytest-windows:
if: github.event_name == 'workflow_dispatch' || github.event_name == 'schedule'
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
python-version: ["3.12"]
steps:
- name: Check out repository
uses: actions/checkout@v5
with:
submodules: recursive

- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: ${{ matrix.python-version }}

- name: Install tmap with bundled OGDF (MSVC)
env:
# Short build dir: OGDF include paths plus the default temp build
# dir can exceed MSVC's MAX_PATH limit.
SKBUILD_BUILD_DIR: C:/tb
run: |
python -m pip install --upgrade pip
python -m pip install ".[dev]"

- name: Verify OGDF extension
run: python -c "from tmap.layout import OGDF_AVAILABLE; print('OGDF:', OGDF_AVAILABLE); assert OGDF_AVAILABLE"

- name: Run all tests
run: python -m pytest -v

# This job is required to pass for PRs to be mergeable
# It depends on all other jobs succeeding
all-tests-pass:
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ The same path tracing and tree-distance colouring are available inside the inter
pip install tmap2
```

Wheels are published for Linux x86_64 and macOS arm64 (Apple Silicon) on Python 3.11 to 3.13. Other platforms build the OGDF layout extension from source and need CMake and a C++17 compiler. Windows is not tested or supported; use [WSL2](https://learn.microsoft.com/windows/wsl/install), where the Linux wheel installs directly.
Wheels are published for Linux x86_64, macOS arm64 (Apple Silicon), and Windows x86_64 on Python 3.11 to 3.13. Other platforms build the OGDF layout extension from source and need CMake and a C++17 compiler.

Optional extras:

Expand Down
3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ build-backend = "scikit_build_core.build"

[project]
name = "tmap2"
version = "0.3.0"
version = "0.3.1"
description = "Tree-based visualization for high-dimensional data"
readme = "README.md"
license = {text = "MIT"}
Expand All @@ -21,6 +21,7 @@ classifiers = [
"License :: OSI Approved :: MIT License",
"Operating System :: POSIX :: Linux",
"Operating System :: MacOS",
"Operating System :: Microsoft :: Windows",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
Expand Down
2 changes: 1 addition & 1 deletion src/tmap/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def _extend_package_path_for_extensions() -> None:
subset_anndata,
)

__version__ = "0.3.0"
__version__ = "0.3.1"

__all__ = [
"__version__",
Expand Down