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
6 changes: 6 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,12 @@ jobs:
run: python3 packaging/homebrew/generate.py "$VERSION" dist > dist/proofback.rb
- name: Keep the release notes out of the upload
run: mkdir -p notes && mv dist/release-notes.md notes/
# proofback-node.tgz and its load()/locate() API are a contract with other
# projects (overfull pins the file by URL); docs/releasing.md.
- name: Check the release-file contract
env:
VERSION: ${{ needs.prepare.outputs.version }}
run: python3 packaging/check-release-files.py dist "$VERSION"
- uses: softprops/action-gh-release@8a0cd651e5b2365bd640854a3fa5dfc70e4875f3 # v3.0.4
with:
files: |
Expand Down
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,18 @@ the JSON schema is versioned separately (`schema_version` in round files).

## Unreleased

### Interop with overfull

- `docs/interop.md` §6 records that overfull 3.3.0 fixed its differences O1 and O2,
and adds O5; the file stays byte-identical in both repositories.
- The agent guide and the agent kit tell agents to run `overfull check --profile arxiv`
(or the venue's profile) before a source upload and to leave out what its
`review-records-in-source` rule reports, such as `.proofback/` and `*-answered.pdf`;
and to import peer reviews with `--anonymize-authors`.
- Release files: `proofback-node.tgz` and its `load()` and `locate()` API are now a
documented contract (overfull pins the file by URL), and the release workflow checks
them before publishing (`packaging/check-release-files.py`).

## 0.3.0 (2026-12-01)

### Breaking changes
Expand Down
1 change: 1 addition & 0 deletions docs/agents.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ The handoffs:
| New references | Add each with `overfull cite`, not by hand. |
| End of a round | `overfull check --json`; report each error. |
| Changes PDF | `overfull diff --base <commit>` makes it. The base is the reviewed draft: `round.source.commit` in `.proofback/rounds/<round>.json`. Then `proofback letter --diff-pdf <file>` names it in the letter. |
| Before uploading a source package | Run `overfull check --profile arxiv` (or the venue's profile) and leave out every path its `review-records-in-source` rule reports: `.proofback/`, the `*-answered.pdf` that `proofback answer` writes, and review notes. For peer review, import with `--anonymize-authors`: without it, overfull reports `.proofback/` as an error under anonymous profiles. |

`--diff-pdf` must name an existing file inside the project root; otherwise
`letter` exits with code 3. Without `--diff-pdf`, in a project with `overfull.yml`,
Expand Down
15 changes: 8 additions & 7 deletions docs/interop.md
Original file line number Diff line number Diff line change
Expand Up @@ -143,14 +143,15 @@ Current output of each tool compared with this specification.

### overfull

Tracked in overfull's own issue; listed here so both files agree.
Tracked in overfull issue 136 (fixed in overfull 3.3.0); listed here so both files agree.

| # | Difference | Kind |
|---|---|---|
| O1 | `Problem.location` has no `column`, `end_line`, `end_column` | Additive |
| O2 | The report has no `schema_version` | Additive |
| O3 | Exit code `2` covers both usage and internal errors | Recorded; a separate internal-error code waits for the next major version |
| O4 | SARIF results have no `partialFingerprints` | Allowed by §4 (no stable id) |
| # | Difference | Kind | Resolution |
|---|---|---|---|
| O1 | `Problem.location` had no `column`, `end_line`, `end_column` | Additive | Fixed in 3.3.0: the location object has all six fields; `anonymity-link`, `figure-missing-alt` (TikZ) and PDF findings placed by proofback's locator fill the range; SARIF regions carry them |
| O2 | The report had no `schema_version` | Additive | Fixed in 3.3.0: every `--json` object starts with `tool`, `version` and `schema_version` (`1`) |
| O3 | Exit code `2` covers both usage and internal errors | Changes an exit code | Recorded; a separate internal-error code waits for v4 (overfull issue 142) |
| O4 | SARIF results have no `partialFingerprints` | Allowed by §4 (no stable id) | No change |
| O5 | `explain --list --json` prints an array, so it cannot carry the top-level fields | Allowed: §5 covers JSON objects only | No change |

## 7. Versioning

Expand Down
22 changes: 21 additions & 1 deletion docs/releasing.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ built or published.
| build | Archives for Linux, macOS and Windows (x86_64 and ARM64) with PDFium, SHA-256 files and signed build provenance. Linux links against glibc 2.17; each binary is run before upload |
| vsix | VS Code extension, tested and packed as `proofback-vscode.vsix` |
| node | Node package, checked against the native result and packed as `proofback-node.tgz` |
| publish | Tag `vX.Y.Z` and GitHub Release with the changelog section as notes and all of the above, plus `install.sh`, `install.ps1` and `proofback.rb` |
| publish | Checks the release-file contract (below), then tags `vX.Y.Z` and publishes the GitHub Release with the changelog section as notes and all of the above, plus `install.sh`, `install.ps1` and `proofback.rb` |
| homebrew | Optional: commits `Formula/proofback.rb` to a tap repository |

Everything ships through the GitHub Release; no npm or Marketplace account is used.
Expand All @@ -48,6 +48,26 @@ npm install https://github.com/Amet13/proofback/releases/latest/download/proofba
code --install-extension proofback-vscode.vsix # after downloading it from the release
```

## Release files other projects depend on

These are a contract. A release that breaks it fails before anything is published:
the publish job runs `packaging/check-release-files.py` on the files it is about to
upload.

| File | Who depends on it | Contract |
|---|---|---|
| `proofback-node.tgz` | [overfull](https://github.com/Amet13/overfull) pins `https://github.com/Amet13/proofback/releases/download/vX.Y.Z/proofback-node.tgz` as an optional dependency (overfull 3.3.0 pins `v0.3.0`) | Published with every release under exactly this name. Its Node API, `load()` and `locate(pdf, { synctex, sources, queries })` with the query and result shapes of `site/schema/locate-v1.json`, changes only with a major version. |
| `proofback-vscode.vsix` | Users, through the stable "latest" link | Published with every release under exactly this name. |

The check fails when either file is missing, when the Node package's name or version
is wrong, when its engine files are missing, or when `lib/index.js` stops exporting
`load` and `locate` or `lib/index.d.ts` loses their declarations. Run it on a folder
of release files with:

```bash
python3 packaging/check-release-files.py <folder> <version>
```

## Optional: Homebrew tap

A tap is an ordinary repository on the same GitHub account, so no new account is
Expand Down
5 changes: 5 additions & 0 deletions integrations/AGENTS.snippet.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,8 @@ in `.proofback/`. When asked to address review comments:
`overfull check --json` and report each error; offer a changes PDF with
`overfull diff --base <commit>`, then `proofback letter --diff-pdf <file>`. If
`overfull` is not available, skip these steps and say so once.
- Before uploading a source package (arXiv or a venue that takes sources), run
`overfull check --profile arxiv` (or the venue's profile) and leave out every path
its `review-records-in-source` rule reports, such as `.proofback/` and the
`*-answered.pdf` from `proofback answer`. For peer review, import with
`--anonymize-authors`.
6 changes: 6 additions & 0 deletions integrations/claude-code/skills/proofback-review/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ proofback never runs it; you do, when it is installed. Check once with
- **Changes PDF**: offer to make a PDF with the changes highlighted,
`overfull diff --base <commit>` (the round's `round.source.commit` is the reviewed
draft), then name it in the letter: `proofback letter --diff-pdf <file>`.
- **Before a source upload** (arXiv or a venue that takes source files): run
`overfull check --profile arxiv` (or the venue's profile) and leave out every path
that its `review-records-in-source` rule reports, such as `.proofback/` and the
`*-answered.pdf` that `proofback answer` writes. For peer review, import with
`--anonymize-authors`; otherwise overfull reports `.proofback/` as an error under
anonymous profiles.
- **No overfull**: if the command is not available, skip these steps and say so to
the author once.

Expand Down
4 changes: 4 additions & 0 deletions integrations/cursor/proofback.mdc
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,7 @@ alwaysApply: false
hand; after the last item of a round run `overfull check --json` and report each
error; offer `overfull diff --base <commit>` and then `proofback letter --diff-pdf <file>`.
If it is not available, skip these steps and say so once.
- Before a source upload (arXiv or a venue that takes sources), run `overfull check
--profile arxiv` (or the venue's profile) and leave out every path its
`review-records-in-source` rule reports, such as `.proofback/` and `*-answered.pdf`;
for peer review, import with `--anonymize-authors`.
6 changes: 6 additions & 0 deletions integrations/skills/proofback-review/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,12 @@ proofback never runs it; you do, when it is installed. Check once with
- **Changes PDF**: offer to make a PDF with the changes highlighted,
`overfull diff --base <commit>` (the round's `round.source.commit` is the reviewed
draft), then name it in the letter: `proofback letter --diff-pdf <file>`.
- **Before a source upload** (arXiv or a venue that takes source files): run
`overfull check --profile arxiv` (or the venue's profile) and leave out every path
that its `review-records-in-source` rule reports, such as `.proofback/` and the
`*-answered.pdf` that `proofback answer` writes. For peer review, import with
`--anonymize-authors`; otherwise overfull reports `.proofback/` as an error under
anonymous profiles.
- **No overfull**: if the command is not available, skip these steps and say so to
the author once.

Expand Down
75 changes: 75 additions & 0 deletions packaging/check-release-files.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
#!/usr/bin/env python3
"""Check the release files that other projects depend on, before they are published.

Usage: check-release-files.py <dir> <version>

The contract (docs/releasing.md):
- `proofback-node.tgz` is published with every release. overfull pins it by URL
(`releases/download/vX.Y.Z/proofback-node.tgz`) and calls `load()` and `locate()`.
- That Node API (`load()`, `locate(pdf, { synctex, sources, queries })` with the
locate-v1 shapes) changes only with a major version.
- `proofback-vscode.vsix` is published with every release (stable "latest" link).
"""
import json
import sys
import tarfile
from pathlib import Path

ENGINE = ("package/engine/proofback_wasm.js", "package/engine/proofback_wasm_bg.wasm")


def check_node(path: Path, version: str) -> list[str]:
errors = []
try:
with tarfile.open(path, "r:gz") as tar:
names = set(tar.getnames())

def text(name: str) -> str:
member = tar.extractfile(name)
return member.read().decode("utf-8") if member else ""

pkg = json.loads(text("package/package.json")) if "package/package.json" in names else {}
if pkg.get("name") != "proofback":
errors.append(f"{path.name}: package name is {pkg.get('name')!r}, not 'proofback'")
if pkg.get("version") != version:
errors.append(f"{path.name}: package version is {pkg.get('version')!r}, not {version!r}")
for need in ("package/lib/index.js", "package/lib/index.d.ts", *ENGINE):
if need not in names:
errors.append(f"{path.name}: missing {need}")
if "package/lib/index.js" in names:
js = text("package/lib/index.js")
exports = js[js.rfind("module.exports"):]
for fn in ("load", "locate"):
if fn not in exports.split("{", 1)[-1].split("}", 1)[0].replace(" ", "").split(","):
errors.append(f"{path.name}: lib/index.js does not export {fn}()")
if "package/lib/index.d.ts" in names:
dts = text("package/lib/index.d.ts")
for decl in ("export function load(", "export function locate(", "interface LocateQuery", "interface LocateResult"):
if decl not in dts:
errors.append(f"{path.name}: lib/index.d.ts has no `{decl}`")
except (OSError, tarfile.TarError, json.JSONDecodeError) as e:
errors.append(f"{path.name}: not a readable package ({e})")
return errors


def main() -> int:
if len(sys.argv) != 3:
print(__doc__.strip().splitlines()[2], file=sys.stderr)
return 2
folder, version = Path(sys.argv[1]), sys.argv[2].lstrip("v")
errors = []
for required in ("proofback-node.tgz", "proofback-vscode.vsix"):
if not (folder / required).is_file():
errors.append(f"missing release file {required} (a contract, see docs/releasing.md)")
if (folder / "proofback-node.tgz").is_file():
errors += check_node(folder / "proofback-node.tgz", version)
for e in errors:
print(f"::error::{e}")
if errors:
return 1
print(f"release files for {version}: proofback-node.tgz and proofback-vscode.vsix present; Node API has load() and locate()")
return 0


if __name__ == "__main__":
sys.exit(main())
Loading