diff --git a/CHANGELOG.md b/CHANGELOG.md index 89b0db7e0..95c864867 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -78,6 +78,9 @@ This is the resolution of #548, which reported `TransType.L2TP` (115) as registe - **Fixed** -- `main` went red the moment #604's `ljust()` landed, because `TCPUDPUnitTests.test_a_truncated_option_still_parses_its_declared_length` still pinned the head-padded short read that fix removed. The `Reserved_79` option declaring `length=12` over 6 real octets now reports `aabbccddeeff00000000` where the test expected `00000000aabbccddeeff`, so both subtests -- `declared_length=12` and `=32` -- failed on that one assertion while the 17 other cases in the file stayed green: the parse itself never changed, only which end the synthesised zeros sit at. The expectation is inverted, and the docstring above it -- which said the short read was *left*-padded and described the value as four zero octets followed by the six real ones -- is corrected to match, since a docstring that contradicts its own assertion is how the stale expectation survived in the first place. The inputs do discriminate: `trailing` is non-zero and the pad width is 4 and 24, so neither subtest would hold under the other order. #621 left this file alone deliberately, because #612 owned it at the time, and merged two minutes ahead of the cross-review verdict that named it (#604, #621). - **Fixed** -- `util/bump_version.py` left `CITATION.cff` naming the previous release. Nothing else in the repository maintains that file -- no workflow, hook or packaging file mentions it -- so every bump since it landed in #615 would have stranded the `version` and `date-released` it renders as GitHub's "Cite this repository" button and that citation managers, Zenodo and dependency inventories read directly. Both fields now move with `__version__`. They have the same standing, since the file's own header says both describe the newest *published* release, and moving only one would assert that 1.5.0b5 was released on the day 1.5.0b4 was; the date is taken in UTC, because seven of the thirty most recent bumps were made late evening in US-Eastern where a local date is a day behind the publish it describes. That the two are the same day at all is measured rather than assumed: the bump is what triggers `create-release.yml`, the median gap to the PyPI upload is three minutes, and the UTC calendar dates agree 30 times out of 30. The rewrite is line-oriented, so the comment header, key ordering and each field's existing quoting survive -- `cff-version` and a `references` entry's own `version` are anchored out at column zero -- and the result is checked with `cffconvert --validate`. An absent file is reported on stderr and skipped rather than failing the vendor cron before its `git commit`, which would discard the whole registry crawl for the sake of a documentation file; a file present with no `version` field raises instead, before anything is written, because rewriting nothing while reporting success is the staleness this fixes. Two things came with it. The script gains a `main()` guard, having previously run the entire bump at import, which is why it had no testable surface; and the `import pcapkit` fallback in its version reader, which returned `"1.5.0b4'\n"` -- closing quote and newline included, which `packaging` rejects -- is fixed, a path that had never worked and went unnoticed because the only caller installs the package first. A new gate asserts the committed file still names the packaged version, covering the version changes made by hand, which never run this script at all -- 40 of the 159 commits that have moved `__version__` on `main`, a quarter over the project's life and 11 of the most recent 25 (#625). +- **Fixed** -- `LICENSE`'s copyright notice began the term at 2018, a year after the work it covers. The repository's first commit is `c57f7d0b7` "Initial commit", dated 2017-11-07, so the notice understated the term and contradicted the only other copyright site in the tree: `docs/source/conf.py` computes its Sphinx footer as `f'2017-{datetime.date.today().year}, Jarry Shaw'` and has said 2017 for as long as it has existed. The two now agree on where the term starts. The wrong start year survived every maintenance pass the line has had, because each looked only at the other end of the range: `bc836cfa2` (2020-05-31) introduced `2018-2020` when the BSD-3-Clause text replaced MPL 2.0, and the range was then bumped by hand three times, to `2018-2022`, `2018-2023` and `2018-2026` (#615), each bump correcting the end year and copying `2018` forward untouched. 2017 is being **restored** rather than newly asserted. The project's first `LICENSE` -- MIT, at `c57f7d0b7`, the initial commit -- already read `Copyright (c) 2017 Jarry Shaw` on line 3, and the GPL v3 era that followed carried `Copyright (C) 2017 Jarry Shaw` in its filled-in "how to apply" appendix. 2017 was lost on 2018-12-08, when `4f3e00d5f` relicensed to Apache 2.0 under `Copyright 2018 Jarry Shaw` -- a single year, correct for the year it was written -- and `1c69341dc` replaced that with MPL 2.0 text the same day, which carried no author notice at all. `bc836cfa2` then picked `2018` back up as a range start in 2020, by which point it was two years stale and no longer described anything. The end year is **dropped** rather than automated, which is the other half of the change: the notice ships inside the sdist and the wheel, so its text is fixed at build time in every copy already downloaded and cannot be computed the way the docs footer is; copyright subsists from creation whether or not a notice names the current year; and BSD-3-Clause's canonical form is `Copyright (c) `, singular. So a range here is six years of hand maintenance on one line buying nothing, and no workflow, script hook or other automation is added in its place -- that was considered and rejected, since automating a value that need not be current is worse than not carrying it. `conf.py` is deliberately untouched, a self-maintaining docs footer showing a range being both conventional and correct. The licence body is unaltered: the whole-file diff is one hunk at line 3, and the remaining 28 lines carry the canonical BSD-3-Clause wording verbatim. Three things distinguish the file from SPDX's bare `licenseText`, and all three predate this change -- the `BSD 3-Clause License` title line, which the choosealicense.com template carries and SPDX omits; the `*` bullets in place of `1.`/`2.`/`3.`; and the extra `All rights reserved.` line -- and the `DAMAGE.` that #615 repaired from a stray `DAMAGE.s` is still clean (#630). + +- **Fixed** -- two inaccurate claims in the #630 entry above, caught by review after #630 had already merged. Both were about the history of `LICENSE` rather than about the change itself, and `LICENSE` is untouched here: 2017 was and remains the right answer, so this is a changelog-prose correction only. The entry asserted that the file "until then was stock MPL text carrying no author notice at all, so 2018 is the first start year the project ever asserted and it was already a year late when it was written". Every clause of it is wrong as a description of the era, though each was true of the single blob `bc836cfa2` happened to replace, which is where the mistake came from. The pre-BSD file was MIT, then GPL v3, then Apache 2.0, and only then MPL 2.0 -- four licences before BSD, not the one implied. The MIT and GPL texts both carried an author notice naming **2017**, the MIT one on line 3 of the initial commit. And `2018` first appeared in the Apache notice of 2018-12-08 as a single year, current for the year it was written rather than late. The claim also contradicted the entry's own opening sentence, which dates the first commit to 2017-11-07. What the history actually supports is a stronger argument for the change than the one that was written, which is why this is corrected rather than deleted: 2017 is the year the project asserted from its first commit, and #630 restores it rather than asserting it anew. The `BSD 3-Clause License` title line is reattributed too, from the opensource.org template -- whose licence text begins at the copyright line -- to choosealicense.com's, whose first line is literally that title, and which also carries the `Copyright (c) [year], [fullname]` comma this file uses. The error came from generalising the pre-BSD era off two blobs that turned out to be the same file, `bc836cfa2^:LICENSE` and `1c69341dc:LICENSE`; enumerating all 14 commits that ever touched `LICENSE` is what caught it (#638). - **Fixed** -- `LICENSE`'s copyright notice began the term at 2018, a year after the work it covers. The repository's first commit is `c57f7d0b7` "Initial commit", dated 2017-11-07, so the notice understated the term and contradicted the only other copyright site in the tree: `docs/source/conf.py` computes its Sphinx footer as `f'2017-{datetime.date.today().year}, Jarry Shaw'` and has said 2017 for as long as it has existed. The two now agree on where the term starts. The wrong start year survived every maintenance pass the line has had, because each looked only at the other end of the range: `bc836cfa2` (2020-05-31) introduced `2018-2020` when the BSD-3-Clause text replaced MPL 2.0 -- the file until then was stock MPL text carrying no author notice at all, so 2018 is the first start year the project ever asserted and it was already a year late when it was written -- and the range was then bumped by hand three times, to `2018-2022`, `2018-2023` and `2018-2026` (#615), each bump correcting the end year and copying `2018` forward untouched. The end year is **dropped** rather than automated, which is the other half of the change: the notice ships inside the sdist and the wheel, so its text is fixed at build time in every copy already downloaded and cannot be computed the way the docs footer is; copyright subsists from creation whether or not a notice names the current year; and BSD-3-Clause's canonical form is `Copyright (c) `, singular. So a range here is six years of hand maintenance on one line buying nothing, and no workflow, script hook or other automation is added in its place -- that was considered and rejected, since automating a value that need not be current is worse than not carrying it. `conf.py` is deliberately untouched, a self-maintaining docs footer showing a range being both conventional and correct. The licence body is unaltered: the whole-file diff is one hunk at line 3, and the remaining 28 lines carry the canonical BSD-3-Clause wording verbatim. Three things distinguish the file from SPDX's bare `licenseText`, and all three predate this change -- the `BSD 3-Clause License` title line, which the opensource.org template carries and SPDX omits; the `*` bullets in place of `1.`/`2.`/`3.`; and the extra `All rights reserved.` line -- and the `DAMAGE.` that #615 repaired from a stray `DAMAGE.s` is still clean (#630). - **Fixed** -- `CITATION.cff` shipped in no source distribution. `MANIFEST.in` carries an `include` line each for `README.md`, `LICENSE` and `CHANGELOG.md` but had none for the citation file, and its two `global-include` patterns are `*.rst` and `*.py`, neither of which can match a `.cff` -- so the file sat in the repository and in nothing published. Nor was there a default to fall back on. Removing all three of those `include` lines and rebuilding shows `README.md` and `LICENSE` shipping anyway, setuptools adding the latter from `license_files` and recording it as `License-File: LICENSE` in `PKG-INFO`, while `CHANGELOG.md` vanishes -- so of the three only `CHANGELOG.md` is load-bearing, and a citation file, which no packaging default covers at all, is in the same position. The gap is invisible from the web UI, because GitHub renders the "Cite this repository" button from the repository itself; citation managers, Zenodo and dependency inventories read the published artifact, which is exactly the surface that was missing it, so the machine-readable half of the attribution stopped travelling with the code at the one point nobody can see the repository. #615 flagged the omission when it added the file and #619 did not address it. It matters now because #625 has just taught `util/bump_version.py` to keep the file's `version` and `date-released` in step with the bump, and a release exercising that path would otherwise publish an sdist omitting the very artefact under test. It also lets `RepositoryCitationTests` in `tests/project/test_bump_version.py` -- the gate #625 added for the hand-authored bumps that never run the script -- execute against an unpacked sdist, where today it skips itself with "CITATION.cff is not shipped in the source distribution". Measured both ways with `python -m build --sdist`: `tar tzf` found no `CITATION.cff` before and `pypcapkit-1.5.0b4/CITATION.cff` after, the two archive listings differ by that one added entry and nothing else -- 860 against 861 -- the shipped copy is byte-identical to the repository's, and `twine check --strict` reports `PASSED` on both archives (#631). diff --git a/docs/source/changelog/1.5.0.rst b/docs/source/changelog/1.5.0.rst index 7fc88a08c..e608708b0 100644 --- a/docs/source/changelog/1.5.0.rst +++ b/docs/source/changelog/1.5.0.rst @@ -1072,12 +1072,19 @@ pull requests between #326 and #509. for as long as it has existed. The two now agree on where the term starts. The wrong start year survived every maintenance pass the line has had, because each looked only at the other end of the range: ``bc836cfa2`` (2020-05-31) introduced - ``2018-2020`` when the BSD-3-Clause text replaced MPL 2.0 -- the file until then was - stock MPL text carrying no author notice at all, so 2018 is the first start year the - project ever asserted and it was already a year late when it was written -- and the - range was then bumped by hand three times, to ``2018-2022``, ``2018-2023`` and - ``2018-2026`` (#615), each bump correcting the end year and copying ``2018`` - forward untouched. The end year is + ``2018-2020`` when the BSD-3-Clause text replaced MPL 2.0, and the range was then + bumped by hand three times, to ``2018-2022``, ``2018-2023`` and ``2018-2026`` + (#615), each bump correcting the end year and copying ``2018`` forward untouched. + 2017 is being **restored** rather than newly asserted. The project's first + ``LICENSE`` -- MIT, at ``c57f7d0b7``, the initial commit -- already read + ``Copyright (c) 2017 Jarry Shaw`` on line 3, and the GPL v3 era that followed + carried ``Copyright (C) 2017 Jarry Shaw`` in its filled-in "how to apply" + appendix. 2017 was lost on 2018-12-08, when ``4f3e00d5f`` relicensed to Apache 2.0 + under ``Copyright 2018 Jarry Shaw`` -- a single year, correct for the year it was + written -- and ``1c69341dc`` replaced that with MPL 2.0 text the same day, which + carried no author notice at all. ``bc836cfa2`` then picked ``2018`` back up as a + range start in 2020, by which point it was two years stale and no longer described + anything. The end year is **dropped** rather than automated, which is the other half of the change: the notice ships inside the sdist and the wheel, so its text is fixed at build time in every copy already downloaded and cannot be computed the way the docs footer is; @@ -1091,8 +1098,8 @@ pull requests between #326 and #509. is unaltered: the whole-file diff is one hunk at line 3, and the remaining 28 lines carry the canonical BSD-3-Clause wording verbatim. Three things distinguish the file from SPDX's bare ``licenseText``, and all three predate this change -- the - ``BSD 3-Clause License`` title line, which the opensource.org template carries and - SPDX omits; the ``*`` bullets in place of ``1.``/``2.``/``3.``; and the extra + ``BSD 3-Clause License`` title line, which the choosealicense.com template carries + and SPDX omits; the ``*`` bullets in place of ``1.``/``2.``/``3.``; and the extra ``All rights reserved.`` line -- and the ``DAMAGE.`` that #615 repaired from a stray ``DAMAGE.s`` is still clean (#630). * **Fixed** -- ``CITATION.cff`` shipped in no source distribution. ``MANIFEST.in`` @@ -1125,6 +1132,31 @@ pull requests between #326 and #509. 861 -- the shipped copy is byte-identical to the repository's, and ``twine check --strict`` reports ``PASSED`` on both archives (#631). +* **Fixed** -- two inaccurate claims in the #630 entry above, caught by review after + #630 had already merged. Both were about the history of ``LICENSE`` rather than + about the change itself, and ``LICENSE`` is untouched here: 2017 was and remains + the right answer, so this is a changelog-prose correction only. The entry asserted + that the file "until then was stock MPL text carrying no author notice at all, so + 2018 is the first start year the project ever asserted and it was already a year + late when it was written". Every clause of it is wrong as a description of the era, + though each was true of the single blob ``bc836cfa2`` happened to replace, which is + where the mistake came from. The pre-BSD file was MIT, then GPL v3, then Apache 2.0, + and only then MPL 2.0 -- four licences before BSD, not the one implied. The + MIT and GPL texts both carried an author notice naming **2017**, the MIT one on + line 3 of the initial commit. And ``2018`` first appeared in the Apache notice of + 2018-12-08 as a single year, current for the year it was written rather than late. + The claim also contradicted the entry's own opening sentence, which dates the first + commit to 2017-11-07. What the history actually supports is a stronger argument for + the change than the one that was written, which is why this is corrected rather than + deleted: 2017 is the year the project asserted from its first commit, and #630 + restores it rather than asserting it anew. The ``BSD 3-Clause License`` title line + is reattributed too, from the opensource.org template -- whose licence text begins + at the copyright line -- to choosealicense.com's, whose first line is literally that + title, and which also carries the ``Copyright (c) [year], [fullname]`` comma this + file uses. The error came from generalising the pre-BSD era off two blobs that + turned out to be the same file, ``bc836cfa2^:LICENSE`` and ``1c69341dc:LICENSE``; + enumerating all 14 commits that ever touched ``LICENSE`` is what caught it (#638). + Preceded by ``1.5.0a1`` (2026-09-15), ``1.5.0b1`` and ``1.5.0b2`` (both 2026-09-18) and ``1.5.0b3`` (2026-09-19), all published as prereleases and so resolved only by ``pip install --pre``. ``1.5.0b1`` half-shipped: the tag, the