Watch
1
0
Fork
You've already forked pkg-proxy
1
mirror of https://github.com/git-pkgs/proxy.git synced 2026-08-22 12:04:54 -04:00
pkg-proxy/internal/server
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Andrew Nesbitt 272e6d9040
Lint and dead-code cleanup (#279)
* Bump go tool golangci-lint to v2.13.1

The .golangci.yml goconst.ignore-tests setting was added in v2.12.0
(golangci/golangci-lint#6480). On the previously pinned v2.10.1,
config verify fails with "additional properties 'ignore-tests' not
allowed" and the setting is silently ignored at run time, so goconst
counts test-file literals toward min-occurrences.

* Apply gofmt and CutSuffix simplification

- gofmt -w internal/server/health_test.go
- Replace HasSuffix+TrimSuffix with CutSuffix in ParseSize

* Remove dead code and migrate tests off legacy Filesystem storage

Migrate the three test call sites of storage.NewFilesystem to
storage.OpenBucket("file://...") and drop the deprecated
StorageConfig.Path field from test configs, then delete code that
deadcode reports as unreachable from cmd/proxy:

- internal/storage/filesystem.go and its tests
- storage.HashingReader
- enrichment.Service.BulkCheckVulnerabilities and NormalizeLicense
- server.ActiveRequestsMiddleware (no-op body; the real tracking
  is the inline r.Use at server.go:226)
- mirror.RegistrySource (unimplemented stub)

metrics.UpdateCircuitBreakerState and RecordCircuitBreakerTrip are
kept because #275 wires them.

Update the CONTRIBUTING.md storage section to reflect blob.go.
2026-08-21 09:26:27 +01:00
..
static Polish UI: lucide icons, sticky footer, hamburger nav, clickable logo (#162) 2026-06-07 16:44:30 +01:00
templates Show build information in web UI (#257) 2026-08-21 09:25:02 +01:00
api.go fix: decode PURL percent-encoding in versions and package paths (#244) 2026-08-14 10:38:08 +01:00
api_test.go Validate package paths before database lookups (#109) 2026-05-03 09:14:18 +01:00
browse.go fix: decode PURL percent-encoding in versions and package paths (#244) 2026-08-14 10:38:08 +01:00
browse_bench_test.go Avoid repeated content type path lookup 2026-08-01 11:22:13 +01:00
browse_test.go Show build information in web UI (#257) 2026-08-21 09:25:02 +01:00
dashboard.go Add PROXY_UI_URL for separate UI/package URL advertisement (#161) 2026-06-07 16:12:43 +01:00
errors.go Structured JSON error responses for API endpoints (#110) 2026-05-03 09:42:03 +01:00
errors_test.go Structured JSON error responses for API endpoints (#110) 2026-05-03 09:42:03 +01:00
eviction.go Enforce max_size config with LRU cache eviction 2026-04-30 18:09:01 +01:00
eviction_test.go Lint and dead-code cleanup (#279) 2026-08-21 09:26:27 +01:00
gradle_cache_eviction.go Add .golangci.yml and clear gocognit/goconst findings (#113) 2026-05-05 10:25:17 +01:00
gradle_cache_eviction_test.go add Gradle Build Cache support with handler and tests (#87) 2026-05-04 11:15:16 +01:00
health.go Add storage backend probe to /health (closes #73) (#119) 2026-05-22 12:14:01 +01:00
health_test.go Lint and dead-code cleanup (#279) 2026-08-21 09:26:27 +01:00
layout.go Show build information in web UI (#257) 2026-08-21 09:25:02 +01:00
middleware.go Lint and dead-code cleanup (#279) 2026-08-21 09:26:27 +01:00
middleware_test.go Lint and dead-code cleanup (#279) 2026-08-21 09:26:27 +01:00
mirror_api.go Structured JSON error responses for API endpoints (#110) 2026-05-03 09:42:03 +01:00
mirror_api_test.go Add MaxBytesReader to mirror API HandleCreate (#105) 2026-05-02 18:00:25 +01:00
packages_list_test.go Fix all golangci-lint issues across the codebase (#32) 2026-03-18 10:59:29 +00:00
resolve.go fix: decode PURL percent-encoding in versions and package paths (#244) 2026-08-14 10:38:08 +01:00
resolve_test.go fix: decode PURL percent-encoding in versions and package paths (#244) 2026-08-14 10:38:08 +01:00
server.go Show build information in web UI (#257) 2026-08-21 09:25:02 +01:00
server_test.go Lint and dead-code cleanup (#279) 2026-08-21 09:26:27 +01:00
static.go Add Container, Debian, RPM handlers and enrichment API 2026-01-29 19:35:15 +00:00
swagger_gen.go Add generated OpenAPI docs support 2026-03-12 11:49:31 +00:00
templates.go Lazy-load HTML templates behind sync.Once (#59) 2026-04-06 13:06:25 +01:00
templates_test.go Show build information in web UI (#257) 2026-08-21 09:25:02 +01:00