Skip to content

Commit b65b730

Browse files
bluetclaude
andcommitted
fix: address PR #230 review feedback
Triaged comments from coderabbit, gemini-code-assist, codex, and the ongoing snyk investigation. Three valid actionable items + one false positive class to flag. 1. Snyk: [tool.poetry] block was incomplete — Poetry requires name/version/description/authors as required fields. Without them, snyk's poetry parser rejects the block as invalid and reports "pyproject.toml error Failed to detect issues" before even getting to dependencies. Add the required identity fields, mirroring values from [project] above. poetry-core 2.x prefers [project] when both are present, so this duplication doesn't affect builds. Verified: `python -m build` produces wheel + sdist correctly. 2. coderabbit: attrs missing upper bound for consistency with other deps. Added `<27.0.0`. attrs uses year-based major versioning, so this caps at the next year boundary — same pattern as other caret constraints. Mirrored in [tool.poetry.dependencies] shim. 3. gemini-code-assist (medium) + coderabbit (nitpick): Dockerfile builder stage had redundant `apt-get upgrade -y` (already done in base stage) and missing `--no-install-recommends`. Removed the redundant upgrade and added the flag. Verified: `docker build` + `docker run --version` both work. 4. gemini-code-assist (3x "hallucination" comments on attrs 26.1.0, ruff 0.15.12, uv 0.11.13): false positives. All three are real, current package versions (verified via PyPI / GitHub releases / ghcr.io image registry). Gemini's training data appears to predate these releases; will reply on the comments rather than change code. 5. codex requirements.txt comment was already addressed in commit 7aa59b5 by adding `--quiet` to the export command — now generates clean output without the resolver status line. 293/293 tests pass. Docker image builds in ~4s. Wheel + sdist build. Co-Authored-By: Claude <noreply@anthropic.com>
1 parent 283154b commit b65b730

3 files changed

Lines changed: 17 additions & 5 deletions

File tree

Dockerfile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,12 @@ FROM base AS builder
4848

4949
WORKDIR /app
5050

51+
# Install build deps for native Python extensions. No `apt-get upgrade`
52+
# here — the base stage already upgraded the system, so re-running just
53+
# adds time without changing state. `--no-install-recommends` keeps the
54+
# image tight by skipping suggested-but-not-required packages.
5155
RUN apt-get update && \
52-
apt-get upgrade -y &&\
53-
apt-get install -y gcc libc-dev libffi-dev && \
56+
apt-get install -y --no-install-recommends gcc libc-dev libffi-dev && \
5457
apt-get clean && \
5558
rm -rf /var/lib/apt/lists/*
5659

pyproject.toml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ requires-python = ">=3.10,<4.0"
1818
dependencies = [
1919
"aiohttp>=3.13.5,<4.0.0",
2020
"aiodns>=3.6.1,<4.0.0",
21-
"attrs>=26.1.0",
21+
"attrs>=26.1.0,<27.0.0",
2222
"maxminddb>=2.8.2,<3.0.0",
2323
"cachetools>=5.5.2,<6.0.0",
2424
"click>=8.3.3,<9.0.0",
@@ -87,14 +87,23 @@ dev = [
8787
# is read only by snyk. DELETE this whole [tool.poetry.dependencies]
8888
# section once snyk's PR app uses uv preview natively.
8989
[tool.poetry]
90+
# name/version/description/authors are required Poetry fields — without
91+
# them snyk's poetry parser rejects the [tool.poetry] block as invalid
92+
# and reports "pyproject.toml error Failed to detect issues". Mirror the
93+
# values from [project] above. poetry-core 2.x prefers [project] when
94+
# both are present, so this duplication doesn't affect builds.
95+
name = "proxybroker2"
96+
version = "2.0.0b3"
97+
description = "The New (auto rotate) Proxy [Finder | Checker | Server]. HTTP(S) & SOCKS."
98+
authors = ["BlueT - Matthew Lien - 練喆明 <bluet@bluet.org>", "Denis Constverum <constverum@gmail.com>"]
9099
packages = [{include = "proxybroker"}]
91100
include = ["proxybroker/data/*.mmdb"]
92101

93102
[tool.poetry.dependencies]
94103
python = "^3.10"
95104
aiohttp = "^3.13.5"
96105
aiodns = "^3.6.1"
97-
attrs = ">=26.1.0"
106+
attrs = ">=26.1.0,<27.0.0"
98107
maxminddb = "^2.8.2"
99108
cachetools = "^5.5.2"
100109
click = "^8.3.3"

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)