judgelint 0.2.1-x86_64-linux → 0.2.2-x86_64-linux
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +47 -0
- data/README.md +30 -12
- data/libexec/judgelint +0 -0
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4dae6f5f5e9fd33ae7c3a831d1f097db46f329845ea6c5d90a979cd6eb309706
|
|
4
|
+
data.tar.gz: dbfad61daa8ffc5ac52ac97bc6b9b455f081224b0eaecf36a3ce73bd7cf1f524
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 719691e6c0e7117a198c8bfb6962bba4e32a7e6aea820d079b8755ab37db9c62e2d1bd817fb517a7745dbc490345d37956cee0bcf8eb933ee9f08508bc13e0c6
|
|
7
|
+
data.tar.gz: 7ddede0ac667d6af31ce4985545ed673877f426c46597b6459d28c3492c73db1111cdaf67dd093659cabc13a7e9fd0179747b0e9005e84fed0a5f966440dfe1b
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,52 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.2.2 (2026-10-30)
|
|
4
|
+
|
|
5
|
+
Fixes from a third review of 0.2.1, which found ways around its fixes.
|
|
6
|
+
|
|
7
|
+
- `--pr` judges what the pull request committed. Untracked files, like ones
|
|
8
|
+
an earlier CI step wrote, aren't part of it and are never sent, whatever
|
|
9
|
+
the pull request's `.gitignore` says, and a tracked file a step changed is
|
|
10
|
+
read as committed.
|
|
11
|
+
- `--pr` reads the base branch's cache into memory and leaves the
|
|
12
|
+
checkout's `.judgelint/cache.bin` alone.
|
|
13
|
+
- `--base` and `--pr` work with `check` only. `judgelint test --pr` used to
|
|
14
|
+
run, ignore `--pr`, and use the pull request's config.
|
|
15
|
+
- Under `--base` or `--pr`, these now fail the run instead of passing:
|
|
16
|
+
- a changed file with a NUL byte near its start, which counted as binary
|
|
17
|
+
and was left out (images, fonts, archives and other formats that are
|
|
18
|
+
never code are still left out);
|
|
19
|
+
- a rule the model refused to answer for one window when another passed;
|
|
20
|
+
- a changed file that leads outside the project, or to nothing.
|
|
21
|
+
- Deleting or moving a file asks about its directory's directory rules.
|
|
22
|
+
- An empty file is asked about by rules about whole files and directories.
|
|
23
|
+
- If git fails to list the project's files, that's an error. Before, the
|
|
24
|
+
gitignore check was skipped and ignored files could be sent.
|
|
25
|
+
- The project's `.judgelint.yml` must be a regular file inside the project,
|
|
26
|
+
1 MB at most. A config named with `--config` can be anywhere.
|
|
27
|
+
- Files are opened with no links allowed in the path, so a directory
|
|
28
|
+
swapped for a link while judgelint runs can't lead it outside.
|
|
29
|
+
- Runs that share a cache no longer drop each other's answers.
|
|
30
|
+
- A custom endpoint's answers are cached under the address and headers its
|
|
31
|
+
`${VAR}`s resolve to. Custom endpoints, and presets with headers,
|
|
32
|
+
ask again once.
|
|
33
|
+
- A failed request stops the run: no more requests go out, from that file
|
|
34
|
+
or any other.
|
|
35
|
+
Requests go out 32 at a time across files. Responses are capped at 4 MB.
|
|
36
|
+
- A file too large for every model is skipped before its questions are
|
|
37
|
+
made, and a directory's files are capped at 4 MB together.
|
|
38
|
+
- Control characters in file names and endpoint errors are escaped in
|
|
39
|
+
output, and so are GitHub workflow commands (a leading `::`, or `##[`), so
|
|
40
|
+
they can't forge a CI annotation.
|
|
41
|
+
- A header whose `${VAR}` isn't set is an error; it was sent as written.
|
|
42
|
+
The key's header is marked sensitive. `price_per_million` can't be
|
|
43
|
+
negative. Cached choices must add up to one. YAML is parsed with
|
|
44
|
+
explicit limits.
|
|
45
|
+
- CI runs cargo-deny and zizmor, builds with the oldest supported Rust,
|
|
46
|
+
and builds the binaries with cargo-auditable. Dependabot updates the
|
|
47
|
+
actions and crates. install.sh checks the build attestation, for the
|
|
48
|
+
release's tag and workflow, when the GitHub CLI is signed in.
|
|
49
|
+
|
|
3
50
|
## 0.2.1 (2026-10-29)
|
|
4
51
|
|
|
5
52
|
Security fixes, after two reviews of 0.2.0. A pull request could change the
|
data/README.md
CHANGED
|
@@ -18,8 +18,9 @@ The script installs to `~/.local/bin`, or to `$JUDGELINT_INSTALL_DIR`. The
|
|
|
18
18
|
binaries are on the [releases page](https://github.com/jpcamara/judgelint/releases)
|
|
19
19
|
for macOS and Linux, on arm64 and x86_64. Linux needs glibc 2.34 or newer
|
|
20
20
|
(Ubuntu 22.04, Debian 12, RHEL 9). `gem install judgelint` installs the same
|
|
21
|
-
binary.
|
|
22
|
-
`cargo install --git https://github.com/jpcamara/judgelint`.
|
|
21
|
+
binary. On another Unix, or an older glibc, build it with Rust:
|
|
22
|
+
`cargo install --git https://github.com/jpcamara/judgelint`. It doesn't build
|
|
23
|
+
on Windows.
|
|
23
24
|
|
|
24
25
|
Each release's archives and gems carry a build attestation from the GitHub
|
|
25
26
|
Actions run that built them, from the tagged source. To check one:
|
|
@@ -232,26 +233,41 @@ judgelint --pr # changes in the current pull request
|
|
|
232
233
|
judgelint --pr --format github # GitHub annotations on the changed lines (json and sarif work too)
|
|
233
234
|
```
|
|
234
235
|
|
|
235
|
-
These only
|
|
236
|
-
context, so existing code doesn't block a new pull request
|
|
237
|
-
|
|
236
|
+
These ask only about the lines that changed, with the rest of the file as
|
|
237
|
+
context, so existing code doesn't block a new pull request. When the model
|
|
238
|
+
says the clearest violation is on a line the change didn't touch, it
|
|
239
|
+
doesn't count, even if a changed line breaks the same rule less clearly.
|
|
240
|
+
A new file is
|
|
238
241
|
all changed lines. Rules about a whole file (`scope: file`) still read the
|
|
239
|
-
whole file when any of it changed
|
|
242
|
+
whole file when any of it changed, and a directory rule asks about a
|
|
243
|
+
directory when a file in it was changed, added or deleted. Only `check`
|
|
244
|
+
takes `--base` and `--pr`. `--pr` gets the base branch from GitHub
|
|
240
245
|
Actions, GitLab, Buildkite, Bitbucket, Azure Pipelines,
|
|
241
246
|
`JUDGELINT_BASE_BRANCH`, or `gh`. Fetch enough history for git to find the
|
|
242
247
|
merge base.
|
|
243
248
|
|
|
244
249
|
Under `--base` or `--pr`, a changed file judgelint can't judge fails the
|
|
245
|
-
run: one too large for the model,
|
|
250
|
+
run: one too large for the model, one the model refused to answer about,
|
|
251
|
+
even in part, one that leads outside the project, or a binary one. Images,
|
|
252
|
+
fonts, archives and other formats that are never code are left out instead.
|
|
246
253
|
|
|
247
254
|
### Pull requests from people you don't trust
|
|
248
255
|
|
|
249
256
|
`--pr` reads `.judgelint.yml`, the specs, and `.judgelint/cache.bin` from the
|
|
250
257
|
base branch, not from the pull request, so a pull request can't change the
|
|
251
258
|
rules it's checked against, where its code is sent, or the answers it's
|
|
252
|
-
judged by. New or changed conventions apply once they're merged.
|
|
253
|
-
|
|
254
|
-
|
|
259
|
+
judged by. New or changed conventions apply once they're merged. The base
|
|
260
|
+
branch's cache is read into memory, and the checkout's own is left alone.
|
|
261
|
+
|
|
262
|
+
`--pr` judges what the pull request committed. Anything else in the
|
|
263
|
+
checkout, like a file an earlier CI step wrote, is never sent, whatever the
|
|
264
|
+
pull request's `.gitignore` says.
|
|
265
|
+
|
|
266
|
+
Run judgelint with `--pr` on pull requests; a plain `judgelint` or `--base`
|
|
267
|
+
run uses the checked-out files as they are.
|
|
268
|
+
|
|
269
|
+
`--pr` trusts the branch a pull request targets, so only check pull requests
|
|
270
|
+
against branches that only trusted people push to.
|
|
255
271
|
|
|
256
272
|
Even so, give the job only the model's API key. The pull request's code is
|
|
257
273
|
still what's being read, and the model can be argued with: a comment in the
|
|
@@ -267,8 +283,9 @@ your machine is read or sent:
|
|
|
267
283
|
- Only files inside the directory judgelint runs in, and none reached
|
|
268
284
|
through a link that leads out of it.
|
|
269
285
|
- In a git repository, only files git tracks or would add, never ignored
|
|
270
|
-
ones.
|
|
271
|
-
- No binary files, and nothing over 4 MB
|
|
286
|
+
ones. Under `--pr`, only files git tracks.
|
|
287
|
+
- No binary files, and nothing over 4 MB, or 4 MB for a directory's files
|
|
288
|
+
together.
|
|
272
289
|
|
|
273
290
|
Requests go to the model's API over https, or plain http to a server on
|
|
274
291
|
your own machine. The API key goes only to its own provider's address: a
|
|
@@ -291,6 +308,7 @@ A model judgelint has no price for, like any model on OpenRouter, needs a
|
|
|
291
308
|
|
|
292
309
|
Every run prints what it cost. Answers are cached in `.judgelint/cache.bin`,
|
|
293
310
|
so a file that hasn't changed costs nothing. Commit the cache to share it.
|
|
311
|
+
Runs at the same time can share it too.
|
|
294
312
|
`judgelint --help` lists the flags.
|
|
295
313
|
|
|
296
314
|
List two models to average their answers, like `models: [typesafe,
|
data/libexec/judgelint
CHANGED
|
Binary file
|