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
28 changes: 28 additions & 0 deletions .github/DISCUSSION_TEMPLATE/ideas.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
title: "[Idea] "
labels: ["idea"]
body:
- type: markdown
attributes:
value: |
Ideas for new packing rules, outputs or integrations. An idea the maintainers take on
is moved to an issue and linked back here, so you can follow it.
- type: textarea
id: problem
attributes:
label: The problem behind the idea
description: What real shipment or load does today's library not handle?
validations:
required: true
- type: textarea
id: idea
attributes:
label: The idea
validations:
required: true
- type: input
id: package
attributes:
label: Package(s) you use
placeholder: "packvium-native-rust"
validations:
required: false
30 changes: 30 additions & 0 deletions .github/DISCUSSION_TEMPLATE/q-a.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
title: "[Q&A] "
labels: ["question"]
body:
- type: markdown
attributes:
value: |
Ask anything about using the library. If you have found a wrong result or an error,
a bug report is the better place.
- type: input
id: package-version
attributes:
label: Package and version
placeholder: "packvium-native-rust 1.8.0 (Rust)"
validations:
required: true
- type: textarea
id: question
attributes:
label: Your question
description: What you are trying to pack, and what you tried.
validations:
required: true
- type: textarea
id: request
attributes:
label: Request (optional)
description: The JSON request or code, if it helps.
render: json
validations:
required: false
33 changes: 33 additions & 0 deletions .github/DISCUSSION_TEMPLATE/show-and-tell.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
title: "[Show and tell] "
labels: ["show-and-tell"]
body:
- type: markdown
attributes:
value: |
Using the library in a shop, a warehouse tool or a load planner? Tell us how. Leave out
anything confidential about your business.
- type: textarea
id: what
attributes:
label: What you built
validations:
required: true
- type: input
id: package-version
attributes:
label: Package and version
placeholder: "packvium-native-rust 1.8.0 (Rust)"
validations:
required: false
- type: textarea
id: lessons
attributes:
label: What worked, and what got in the way
validations:
required: false
- type: input
id: link
attributes:
label: Link (optional)
validations:
required: false
105 changes: 105 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
name: Bug report
description: A result that is wrong, an error you did not expect, or a crash.
title: "[Bug]: "
labels: ["bug", "needs-triage"]
body:
- type: markdown
attributes:
value: |
Thanks for reporting. A report we can run is a report we can fix, so the most useful
thing below is the smallest request that shows the problem.

**Security problems do not belong here.** Use **Report a vulnerability** under the
Security tab instead; it opens a private advisory.
- type: dropdown
id: package
attributes:
label: Package
description: Which package did you call?
options:
- "packvium (PyPI) — Packvium for Python"
- "packvium-native (PyPI) — Packvium native backend selector for Python"
- "packvium/packvium (Packagist) — Packvium for PHP"
- "packvium/native-bridge (Packagist) — Packvium native bridge for PHP"
- "@packvium/engine (npm) — Packvium for Node.js"
- "@packvium/browser (npm) — Packvium for browsers"
- "packvium (crates.io) — Packvium for Rust"
- "packvium-native-rust (PyPI) — Packvium native engines: Python wheels, Node addons and the C library"
- Not sure
default: 7
validations:
required: true
- type: input
id: version
attributes:
label: Package version
description: The exact version installed, for example 1.8.0.
placeholder: "1.8.0"
validations:
required: true
- type: input
id: runtime
attributes:
label: Runtime and operating system
description: Language runtime version and OS, for example "Python 3.12, Ubuntu 24.04" or "PHP 8.3, macOS 15".
validations:
required: true
- type: dropdown
id: profile
attributes:
label: Search profile
options:
- fast
- balanced
- quality
- exact_small
- Not set / default
- Not sure
validations:
required: false
- type: textarea
id: request
attributes:
label: Request that reproduces it
description: |
The JSON request, or the code that builds it, cut down as far as it still shows the
problem. Remove anything confidential; renamed item ids are fine.
render: json
validations:
required: true
- type: textarea
id: actual
attributes:
label: What happened
description: The result (or its relevant part), or the full error message and stack trace.
render: text
validations:
required: true
- type: textarea
id: expected
attributes:
label: What you expected
description: What the result should have been, and why. If another of the packages gives a different answer for the same request, say which.
validations:
required: true
- type: dropdown
id: stopped-by
attributes:
label: How was the search limited?
description: A search stopped by a time limit can differ between runs by design; one stopped by an effort budget cannot.
options:
- effort_budget
- time_limit_ms
- Both
- Neither / not sure
validations:
required: false
- type: checkboxes
id: checks
attributes:
label: Before submitting
options:
- label: I searched the existing issues and did not find this one.
required: true
- label: I read [docs/GUARANTEES.md](https://github.com/toxakara/packvium-native/blob/HEAD/docs/GUARANTEES.md) and this is not something it says the library does not guarantee.
required: false
11 changes: 11 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
blank_issues_enabled: false
contact_links:
- name: Question or help with a request
url: https://github.com/toxakara/packvium-native/discussions/categories/q-a
about: Ask in Discussions → Q&A. Answers there help the next person too.
- name: Report a security vulnerability
url: https://github.com/toxakara/packvium-native/security/advisories/new
about: Report privately. Do not open a public issue for a security problem.
- name: Documentation
url: https://packvium.com/docs
about: Guides, the request contract and the constraint reference.
62 changes: 62 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Feature request
description: A packing rule, constraint, output or integration the library does not support yet.
title: "[Feature]: "
labels: ["enhancement", "needs-triage"]
body:
- type: markdown
attributes:
value: |
Open-ended ideas are welcome in **Discussions → Ideas** first. Use this form when you can
describe a concrete problem the library does not solve today.
- type: dropdown
id: package
attributes:
label: Package you use
options:
- "packvium (PyPI) — Packvium for Python"
- "packvium-native (PyPI) — Packvium native backend selector for Python"
- "packvium/packvium (Packagist) — Packvium for PHP"
- "packvium/native-bridge (Packagist) — Packvium native bridge for PHP"
- "@packvium/engine (npm) — Packvium for Node.js"
- "@packvium/browser (npm) — Packvium for browsers"
- "packvium (crates.io) — Packvium for Rust"
- "packvium-native-rust (PyPI) — Packvium native engines: Python wheels, Node addons and the C library"
- More than one
default: 7
validations:
required: true
- type: input
id: version
attributes:
label: Package version
placeholder: "1.8.0"
validations:
required: true
- type: textarea
id: problem
attributes:
label: The problem
description: What are you packing, into what, and what rule or output is missing? A real (anonymised) example helps more than a general description.
validations:
required: true
- type: textarea
id: proposal
attributes:
label: What you would like
description: The behaviour or field you have in mind, if you have one.
validations:
required: false
- type: textarea
id: workaround
attributes:
label: What you do today
description: Any workaround you use, and what it costs you.
validations:
required: false
- type: markdown
attributes:
value: |
Every package implements one shared contract, so a new rule or result field lands in all
of them together, and a change to the request or result format waits for a release that
is allowed to change it. A request that is accepted may therefore take more than one
release to ship.
47 changes: 47 additions & 0 deletions .github/workflows/rc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: rc

# A pre-release tag (`v1.9.0-rc.1`) is checked against every version this repository
# declares and its changelog, exactly as `release.yml` does, and nothing is built or
# published. The native packages (`packvium-native-rust` on PyPI, `@packvium/native*` on
# npm) are not yet published to production at all; an RC channel for them is added in the
# change that gives them their production Trusted Publishers. There is no GitHub Release.

on:
push:
tags: ["v*-*"]

permissions:
contents: read

jobs:
verify-tag:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
# The tag and every packaged version must agree. Without this, `git tag v0.2.0` on a
# tree that still says 0.1.0 publishes 0.1.0 under a name that claims otherwise, and the
# mistake is only visible after it is public and immutable.
- name: The tag must match every version this repository publishes
run: |
python3 - "${GITHUB_REF_NAME#v}" <<'PY'
import json, sys, tomllib
from pathlib import Path
tagged = sys.argv[1]
versions = {
"Cargo.toml": tomllib.loads(Path("Cargo.toml").read_text())["workspace"]["package"]["version"],
"bindings/python/pyproject.toml": tomllib.loads(Path("bindings/python/pyproject.toml").read_text())["project"]["version"],
}
for manifest in ["bindings/node/package.json", *map(str, sorted(Path("bindings/node/npm").glob("*/package.json")))]:
versions[manifest] = json.loads(Path(manifest).read_text())["version"]
wrong = {path: found for path, found in versions.items() if found != tagged}
for path, found in wrong.items():
print(f"{path} declares {found}, the tag says {tagged}", file=sys.stderr)
raise SystemExit(1 if wrong else 0)
PY
- name: The tag must have a changelog entry
run: |
tagged="${GITHUB_REF_NAME#v}"
if ! grep -q "^## \[${tagged}\]" CHANGELOG.md; then
echo "CHANGELOG.md has no '## [${tagged}]' section for tag $GITHUB_REF_NAME" >&2
exit 1
fi
4 changes: 3 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,11 @@ name: release
# `npm publish` allowed.
# GitHub: environments named `pypi` and `npm`, with whatever reviewers the project wants.

# A pre-release tag (`v1.9.0-rc.1`) never reaches the production registries: the negated
# pattern must follow the positive one, and `rc.yml` takes those tags instead.
on:
push:
tags: ["v*"]
tags: ["v*", "!v*-*"]

permissions:
contents: read
Expand Down
30 changes: 12 additions & 18 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,20 @@ project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [1.8.0]

The first published release of the compiled engines. Each binary is built from the Rust
source in this repository at the tagged commit, run on the platform it names, and attested.
The engine inside is the 1.8.0 core.
The first release of the compiled engines. Each binary is built from the Rust source in this
repository at the tagged commit, tested on the platform it names, and attested. The engine
inside is the 1.8.0 core.

### Added

- **`packvium-native-rust` wheels**, one `abi3-py39` wheel each for Linux (manylinux_2_28,
x86_64 and aarch64), macOS (arm64 and x86_64) and Windows (x86_64). Every wheel is
installed into a clean CPython 3.9 and 3.14 and solves a request before it is published.
It is the backend the `packvium-native` selector's `native` extra installs; that selector is
not on PyPI yet.
- **`@packvium/native`** with four platform packages: `darwin-arm64`, `darwin-x64`,
`linux-x64-gnu` and `win32-x64-msvc`. npm installs the one matching the host as an
optional dependency. The loader names every binary it can load by a literal specifier and
refuses a binary from another release.
- **The C library** — `libpackvium_ffi` for Linux (x86_64, aarch64) and macOS (arm64,
x86_64), `packvium_ffi.dll` for Windows (x86_64) — attached to the GitHub Release with
`packvium.h` and `SHA256SUMS.txt`.
x86_64), `packvium_ffi.dll` for Windows (x86_64) — on the GitHub Release with `packvium.h`
and `SHA256SUMS.txt`.
- **`packvium-native-rust` abi3-py39 wheels** for the same five targets, each installed into a
clean CPython 3.9 and 3.14 and run before upload.
- **`@packvium/native`** with four platform packages (`darwin-arm64`, `darwin-x64`,
`linux-x64-gnu`, `win32-x64-msvc`); its loader names every binary by a literal specifier and
refuses one from another release.

## Before 1.8.0

No compiled engine was published. The Python selector and `@packvium/engine` answered from
their pure implementations, which give the same results.
The wheels and npm packages reach PyPI and npm only once their Trusted Publishers exist; until
then the release carries the C library alone.
2 changes: 2 additions & 0 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,5 @@ keywords:
- packing-algorithm
- logistics
- deterministic
- box-packing
- load-planning
Loading
Loading