Remove dead code flagged in the code-quality review (#528)#552
Open
maltehuebner wants to merge 1 commit into
Open
Remove dead code flagged in the code-quality review (#528)#552maltehuebner wants to merge 1 commit into
maltehuebner wants to merge 1 commit into
Conversation
…edByProvider - assets/js/limit-violation.js references an undefined global `exceedanceData`, is not a Webpack entry and is rendered by no template - dead on arrival. Removed. - StationRepository::findIndexedByProvider has no callers anywhere in src/ and is not HTTP-reachable. Removed. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Addresses item 4 (dead/unreachable code) of #528 — the fully verifiable part.
Changes
assets/js/limit-violation.js. It references a globalexceedanceDatathat is defined nowhere, is not a Webpack entry (webpack.config.js) and is rendered by no template. Confirmed by grep acrossassets/,templates/,config/,webpack.config.jsandpackage.json.StationRepository::findIndexedByProvider. Grep acrosssrc/shows only the definition — no callers, not HTTP-reachable.Deliberately not implemented / deferred
These three items are behavioural changes on DB/HTTP paths that cannot be exercised or verified in this environment (no PostGIS/Redis, and the local
vendor/lackssymfony/runtimeso the kernel cannot boot). Committing them unverified would risk changing API behaviour blindly:CityController::showAction— consolidating the per-stationPollutionDataFactorynative queries into onestation_id IN (...)query requires DB verification of the grouped result and query-count profiling.UniqueConstraintViolationExceptionsuppression inPostgisPersister::persistValues— changing this alters API success/failure semantics (currently returns 200) and needs DB-backed batch-insert testing to get the upsert/clear behaviour right.PUT /api/value(valuebounds, futuredate_time,tag> 32 chars) — a 400-vs-500 behavioural change on an endpoint that needs a bootable kernel + DB to test end-to-end.Verification
vendor/bin/phpstan analyse --no-progress— No errorsvendor/bin/phpunit --testsuite="Project Test Suite"— OK (121 tests)Refs #528 (partial)
🤖 Generated with Claude Code