Repository navigation
Conversation
CON-cell.7 accepts a radicand above -1e-12 and rejects one below it. The cell stays sheared inside the window and is not a real cell outside.
The parallel frame scan treated a blank line and a component label as a section of the current frame, then dropped the error. The scan parses the same header as the iterator and skips only the sections that header declares. Thread arms agree on the class.
Reject the cells, tokens, and metadata the spec names, and accept a JSON major of 3.0 or 3e0. A frame that begins with U+FEFF is rejected on every frame (CON-file.2). Present unit strings must match their dimension (CON-units.2).
CON-cell.6 builds the cell from lines 3-4 only when lattice_vectors is absent, and CON-cell.1 has the reader prefer lattice_vectors. Angles of 170 170 170 with lattice_vectors still parse.
CON-file.2 rejects U+FEFF at the start of any frame. iter_con and ConFrameReader rebuild the position on the remainder, and that frame is still rejected, the same way read_con rejects it.
The reader reads -0 as major 0 (CON-line2.4, CON-line2.5), and the Rust oracle test already expects that class. The Python twin matches it.
Check the token boundary before a non-finite spelling, so trailing
junk such as -Inf{inity is InvalidNumberFormat. Trim leading spaces
and tabs on line 2 (CON-file.4). Reserved key types apply in every mode.
CON-token.3 and CON-file.4 restrict field separators and trailing characters to spaces and tabs. Numeric, scalar-section, and count tokenizers use that set. A form feed between line-2 tokens stays whitespace the minor scan skips.
CON-frame.3 names the first missing line when a frame ends early. The line position records that line once, including a UTF-8 rejection and a section that runs out of rows.
CARGO_MANIFEST_DIR in corpus31_manifest.rs stays in a cfg(test) module so the library source scan does not treat it as shipped code.
spec_corpus_recount.py previously wrote data/spec/corpus_recount.json
in place. Walk existing corpus_recount(-<n>).json files in
recount_paths() so each rerun writes the next corpus_recount-<n>.json
exclusively with open('x') and records supersedes on the previous
record, while --tables reads the newest record in the chain and
gen_version_map.py maps any corpus_recount(-<n>).json to the
specification corpus recount campaign.
Merging develop (25b1e08) added three test files and updated the library sources, making clause_coverage-0.24.0-sources.json and corpus_recount-2.json stale for the merged tree. Append clause_coverage-0.24.0-sources-2.json and corpus_recount-3.json without editing the existing records, refresh version_map.tex from the superseding recount, and register the new superseding patterns in scripts/check_version_sot.sh.
CON-units.21 requires units.velocity to equal units.length divided by the time the version assigns. Major 3 assigns the natural unit, and units.time must not decide the quotient. v31_units_compound names velocity nm/ps, so the reader rejects it. The base oracle still records the earlier acceptance.
fix: keep Python frame atoms and xyz in sync
Bring in #113, which keeps frame.atoms and frame.xyz on one coordinate buffer, onto the column model of this branch. src/types.rs: both sides added atomic_store_f64. Keep one copy, built on AtomicU64::from_ptr like the load beside it, with the documented contract from develop. src/python.rs: each cached Atom views its row of the xyz buffer, so a store into xyz after frame.atoms is built still reaches the next write. to_con_frame reads those views in place of the copies it held before. AtomDatum holds no coordinate pointer here, so the pointer drift fixup in overwrite_coords is dropped and the fingerprint fallback reads the positions column. canonical_owner also returns the buffer length. A short buffer leaves atoms unlinked, and an xyz assignment falls back to per-atom stores. Docs and pins: keep both doc edits. The cxx wrap hash keeps this branch's value here and is re-recorded later on this branch.
The lints job runs ruff-format through prek and failed on the clause coverage script and two Python test files. The output path in clause_coverage.py fits on one line, and latest() was missing the two blank lines before the next top-level name. Two test expressions are rewrapped. No behaviour changes.
cargo fmt --check failed on src/python.rs at develop. It rewraps hash_coords and two error paths in canonical_owner, and fixes the indent of source_coord_hash in pyconframe_from_ase. No behaviour changes.
clause_coverage.py --check failed against the r3 record. The Python frame sync tests from develop raise the Python test count, and the tree already counted more test files, Rust tests and Python tests than r3 records. The r4 record supersedes r3 with 221 files, 986 Rust tests and 632 Python tests. The clause totals are unchanged and r3 stays as it was.
The develop merge changes src/python.rs and src/types.rs, which are in the slim cxx archive, so check_cxx_wrap_pin.sh no longer matched. Record the digest of this tree in the wrap file, the sha256 sidecar and the FetchContent snippets. The saved source date epoch is kept.
fix: harden types, writer and Python buffers
clause_coverage.py --check reads clauses_macros.tex and fails when that file is missing. The file is gitignored, so a checkout has no copy and the check reports that it differs. The r4 record already matches the sources. Track the TeX the script writes from it.
Refresh archive pins, package contents, tutorial checks and manifests against the recorded release inputs. Clean clones now validate the same files that the submission archive ships.
Name the line of the parse error. The referee coverage record counts the regression test.
Use the zstandard module when Python has it, otherwise the zstd program, libzstd, or the harness socket.
The corrected counts are this record: 165 files, readcon 125 matches, 23 disagreements, 17 not followed. Referee records keep the library version that produced them.
The error-line test starts an interpreter. Link that library only when the tests are compiled, so the cdylib stays free of it.
Replace the manuscript and supplement wording with the CON 4.0.4 text, the added sections and the ecosystem figure.
| "cthreeoneAccepted": s["accepted"], | ||
| "cthreeoneRejected": s["rejected"], | ||
| "cthreeoneAccepted": legal, | ||
| "cthreeoneRejected": len(record["files"]) - legal, |
There was a problem hiding this comment.
Legal corpus counts omit stored files
High Severity
macros() now treats cthreeoneAccepted and cthreeoneRejected as manifest legal/illegal totals, but it counts record["files"] instead of the summary. The referee record sets explicit_files_stored false and keeps only the non-explicit entries, so --tables writes legal/illegal macros that do not add up to \cthreeoneFiles and undercount the corpus the paper prints.
Reviewed by Cursor Bugbot for commit 59ab8e6. Configure here.
| "127", | ||
| jget(RECORDED, "spec.clauses"), | ||
| RECORDED, | ||
| "spec.clauses: the clauses of the recorded CON 3.1 specification", |
There was a problem hiding this comment.
Spec rules mix two cross-check records
Medium Severity
The clause-count rule now reads data/referee/r1h/corpus_crosscheck.json, but the corpus31 basis rules still read data/corpus_crosscheck.json. Those records are different measurements (127 vs 125 clauses; disagreements vs none), so the number tracer can certify table figures against a stale file after the paper moved to the referee record.
Reviewed by Cursor Bugbot for commit 59ab8e6. Configure here.
| return [] | ||
| return [ | ||
| "the velocity row does not state both its convention and lack of an in-file declaration" | ||
| ] |
There was a problem hiding this comment.
Velocity-row check never runs
Low Severity
velocity_row_problems is new manuscript-check logic, but nothing in check_front, check_conformance, or the main() check list calls it. Only isolated tests invoke it, so a velocity row that names “no unit convention” still passes check_manuscript.py.
Reviewed by Cursor Bugbot for commit 59ab8e6. Configure here.
Point the exchange macros at a new summary-2.csv copied from bench/ecosystem/summary.csv. The raw log ratios match that file. The first paper summary.csv stays as stored.
CPC-FORM.md was still the CON 3.1 abstract, title and keywords. make_packet.front_problems fails when those fields drift from rg_main.tex. The word count is check_manuscript.words.
gen_highlights.py writes highlights.txt from rg_main.tex and fails when a line differs or exceeds 85 characters. The packet records the lengths of those lines.
CON-status.4 requires a patch bump when normative sentences change. CON-cell.3, CON-count.4 and CON-units.9 now say absent or omitted where 4.0.4 said missing.
gen_spec_supp.py --measure names the 4.0.5 text, and clause_coverage.py --record supersedes the spec-major-11 coverage record. The named commit is the parent.
The writer patch follows the specification text. A stored measurement stays byte-identical, and a later run appends the next record. Readers still accept a frame stamped 4.0.4.
The survey frame, the failure matrix, the version-safety rows and the test-run frame hash supersede the 0.24.0 records. The stored files are unchanged.
The generated fixture stamps specification patch 5. Record its sha256 in the next pin file.
Set the executable bit so the shebang matches sibling scripts. Read the successor names once per chain.
The csv path is the json record with a csv suffix.
Resolve docs/source/_generated/cachegrind_results.json by taking main's newer measurement, then regenerate docs/source/_generated/cachegrind_results.rst.
The successor walk re-read every later file on each hop. Parse each file once, then follow supersedes.
Windows CPython has no LDLIBRARY sysconfig value. On MSVC, name pythonXY.lib from LIBDIR or base_prefix\libs. If that import lib is not on the target, skip the link instead of panicking. Linux and macOS still use the LDLIBRARY stem.
py_version_nodot stays 313 or 314 when the GIL is disabled, but the import library is python313t.lib or python314t.lib. Read the plat version, ABIFLAGS, or Py_GIL_DISABLED, and link that library.
PYO3_PYTHON is first when it is set. python3 is next, and python is last, because python3 may be missing or the Microsoft Store alias. Linux and macOS still call python3.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 2 potential issues.
There are 5 total unresolved issues (including 3 from previous reviews).
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 17f5646. Configure here.
| if !dir.is_empty() { | ||
| let flag = python_link::msvc_libpath_arg(dir); | ||
| println!("cargo:rustc-link-arg-tests={flag}"); | ||
| } |
There was a problem hiding this comment.
MSVC LIBPATH misses unit tests
High Severity
cargo:rustc-link-arg-tests does not apply to the lib unit-test harness. The generated #[link] lives in src/python.rs unit tests, so on MSVC the search path never reaches the binary that needs pythonXY.lib. cargo test --features python then fails unless that import library already sits on the default LIB path.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 17f5646. Configure here.
|
|
||
| #[cfg(feature = "python")] | ||
| #[path = "support/python_link.rs"] | ||
| mod python_link; |
There was a problem hiding this comment.
Python link file omitted from package
High Severity
support/python_link.rs is pulled in by build.rs (python feature) and by lib tests, but Cargo.toml's include list still names only support/metatensor_install.rs. A crates.io package therefore omits the file, so --features python builds and cargo test of the published crate cannot compile.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit 17f5646. Configure here.


Commits:
The specification blob changed with the absent and omitted wording.
Lands after #127 (stacked on feat/referee-r6).
Note
Medium Risk
Normative spec patch and writer metadata affect conformance pins and cross-language tests; build-time Python probing can fail on unusual environments; large regenerated paper datasets increase review surface without obvious runtime logic changes to the core reader.
Overview
Bumps the CON format specification to 4.0.5 (2026-11-26): normative clauses and surrounding prose now say absent or omitted instead of missing (
CON-cell.3,CON-count.4,CON-units.9), with matching updates inclauses.tsv, Org/RST docs, and round-trip examples expectingcon_spec_patch5. A new bench pin and refreshed million-atom fixture SHA reflect the 4.0.5 writer stamp.Build and CI:
build.rswires apythonfeature path that probes sysconfig (UnixLDLIBRARY, Windows/MSVC including free-threadedpython313t.lib) viasupport/python_link.rsand emits link args for Rust test binaries. Weak-scaling ASV tests now expectTimeWeakThreads.setupto be callable. Cachegrind generated artifacts are refreshed.CPC paper / referee bundle: Manuscript highlights reframe CON 3.1 → 4 and broaden the ecosystem pitch (metatensor, readcon-db/ops, etc.). Adds or supersedes measurement records (failure matrix, survey frame, test run, corpus crosscheck, clause coverage 134/179, drift, format H2H, Fortran standard check) and small evidence-script tweaks; TeX macros for clause counts and e5 prefactor ratios are updated.
Reviewed by Cursor Bugbot for commit 17f5646. Bugbot is set up for automated code reviews on this repo. Configure here.