Skip to content

chore: lint fixes part 4#256

Open
pawbana wants to merge 2 commits intopb/coder-lint-fix3from
pb/coder-lint-fix4
Open

chore: lint fixes part 4#256
pawbana wants to merge 2 commits intopb/coder-lint-fix3from
pb/coder-lint-fix4

Conversation

@pawbana
Copy link
Copy Markdown
Contributor

@pawbana pawbana commented Apr 10, 2026

  • import-shadowing (11): renamed recorder parameter to rec in Setup() interface + all 9 implementations to avoid shadowing the recorder package import; renamed provider parameter to prov in
    newPassthroughRouter to avoid shadowing the provider package
  • unused-receiver (1): omitted receiver name on AsyncRecorder.RecordInterception panic method
  • context-as-argument (2): moved context.Context to first parameter in newBridgeTestServer and newMockUpstream, updated ~60 call sites
  • G306/gosec (2): tightened WriteFile permissions from 0o644 to 0o600 in API dump files
  • forcetypeassert (2): added nolint directives for sync.Map type assertions in circuit breaker (always stores the same type)

Copy link
Copy Markdown
Contributor Author

pawbana commented Apr 10, 2026

func newBridgeTestServer(
t *testing.T,
ctx context.Context,
t *testing.T,
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this picked up by a linter? Seems like an unneccesary change.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe it this regarding this point:

context-as-argument (2): moved context.Context to first parameter in newBridgeTestServer and newMockUpstream, updated ~60 call sites

linter rule is that context needs to be first argument IIRC.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK 👍

@pawbana pawbana force-pushed the pb/coder-lint-fix4 branch from edd1f90 to e1765bc Compare April 13, 2026 11:30
@pawbana pawbana force-pushed the pb/coder-lint-fix3 branch from ead0336 to e63a56f Compare April 13, 2026 11:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants