Skip to content

Commit dd4870d

Browse files
committed
merge v1.4.4 into release/1.4 — JAR bundling + release-guard fixes precede 1.5.0
# Conflicts: # CHANGELOG.md # pyproject.toml
2 parents 48498c3 + 438738e commit dd4870d

4 files changed

Lines changed: 49 additions & 1 deletion

File tree

.github/workflows/release.yml

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,36 @@ jobs:
6565
- name: Build Package
6666
run: uv build
6767

68+
- name: Verify the codeanalyzer JAR is bundled
69+
# Guard against the hatchling/.gitignore regression (issue #284): a jarless wheel
70+
# installs fine but fails at runtime with "codeanalyzer jar not found". Fail the
71+
# release here rather than publish a broken artifact to PyPI.
72+
#
73+
# The listing is captured before grepping: piping `tar tzf` (which decompresses the
74+
# whole 32MB sdist) straight into `grep -q` lets grep close the pipe on first match,
75+
# SIGPIPE-killing tar and — under `pipefail` — reporting a false "missing JAR".
76+
run: |
77+
set -euo pipefail
78+
jar_re='codeanalyzer/jar/codeanalyzer-[0-9][^/]*\.jar$'
79+
fail=0
80+
for f in dist/*.whl dist/*.tar.gz; do
81+
case "$f" in
82+
*.whl) listing=$(unzip -l "$f") ;;
83+
*.tar.gz) listing=$(tar tzf "$f") ;;
84+
esac
85+
if grep -qE "$jar_re" <<<"$listing"; then
86+
echo " ✓ $f"
87+
else
88+
echo "::error::$f is missing the codeanalyzer JAR"
89+
grep -i '\.jar' <<<"$listing" || echo " (no .jar entries at all)"
90+
fail=1
91+
fi
92+
done
93+
if [ "$fail" -ne 0 ]; then
94+
echo "Refusing to publish a jarless release."; exit 1
95+
fi
96+
echo "codeanalyzer JAR present in wheel and sdist ✓"
97+
6898
- name: Read Changelog Entry
6999
id: changelog_reader
70100
uses: mindsers/changelog-reader-action@v2

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,17 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
3333
- Getter/setter pairs share one signature in the analyzer's output; the two backends currently
3434
collapse such pairs differently (#300 — documented on `get_callables_overview`).
3535

36+
## [v1.4.4] - 2026-07-22
37+
38+
### Fixed
39+
- **Published wheels bundle the `codeanalyzer-java` JAR again.** Every hatchling-built wheel/sdist
40+
since v1.2.0 shipped without the JAR, so `pip install cldk` + `CLDK.java(...)` raised
41+
`CodeanalyzerExecutionException: codeanalyzer jar not found`. The root `.gitignore` `*.jar` rule
42+
was applied at build time while the nested `!codeanalyzer-*.jar` negation (which keeps the JAR in
43+
git) was not honored, silently dropping the JAR from any build run inside a git repo — i.e. CI. A
44+
`[tool.hatch.build] artifacts` rule force-includes it, and the release workflow now fails if a
45+
built artifact is missing the JAR. (#284)
46+
3647
## [v1.4.3] - 2026-07-14
3748

3849
### Fixed

pyproject.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,13 @@ test = [
7474
requires = ["hatchling"]
7575
build-backend = "hatchling.build"
7676

77+
# The codeanalyzer-java JAR is force-included here: it lives under a `*.jar` .gitignore
78+
# (re-included for git via a nested `!codeanalyzer-*.jar`), but hatchling honors the root
79+
# ignore and not the nested negation, so without this it is silently dropped from every
80+
# wheel/sdist built inside a git repo (i.e. in CI). See issue #284.
81+
[tool.hatch.build]
82+
artifacts = ["cldk/analysis/java/codeanalyzer/jar/*.jar"]
83+
7784
[tool.hatch.build.targets.wheel]
7885
packages = ["cldk"]
7986

uv.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)