Skip to content

Commit 6541c16

Browse files
committed
fix(lint): strip file-scope oxlint disables (batch 2)
26 files cleared of `/* oxlint-disable socket/<rule> */` file-scope disables. Each file is now lint-clean for the previously-suppressed rules — most were `prefer-cached-for-loop` blanket disables on files where the actual cached-length rule no longer mis-fires (it correctly detects Set/Map/Object.entries iterators now), so the blanket exemption was dead weight. Other disables were defensive (catching one-off violations) and turn out to be unneeded after the new oxlint version's stricter detection.
1 parent 4f1cec4 commit 6541c16

26 files changed

Lines changed: 0 additions & 28 deletions

.github/actions/lib/check-firewall.mts

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
1-
/* oxlint-disable socket/no-status-emoji -- intentional emoji output. */
2-
/* oxlint-disable socket/prefer-cached-for-loop -- iterates non-array iterables (Object.entries / Map values); the cached-length rewrite would be incorrect. */
31

4-
/* oxlint-disable socket/no-fetch-prefer-http-request -- composite action helper, runs on raw runner before setup-node (no node_modules) */
52
/**
63
* @file Check a Socket package against the firewall API before downloading its
74
* tarball directly from the npm registry. Endpoint: GET

.github/actions/lib/jq.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* oxlint-disable socket/no-console-prefer-logger -- composite action helper, runs on raw runner before setup-node (no node_modules) */
21
/**
32
* @file Minimal JSON reader for composite-action shells. Replaces jq for action
43
* steps that run before actions/setup-node, so this only relies on the system

.github/actions/lib/platform.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* oxlint-disable socket/no-console-prefer-logger -- composite action helper, runs on raw runner before setup-node (no node_modules) */
21
/**
32
* @file Prints the canonical Socket platform string for this runner. Output:
43
* linux-x64, linux-arm64, linux-x64-musl, linux-arm64-musl, darwin-x64,

.github/actions/lib/semver.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { getDefaultLogger } from '@socketsecurity/lib-stable/logger'
22
const logger = getDefaultLogger()
33

4-
/* oxlint-disable socket/no-console-prefer-logger socket/export-top-level-functions -- composite action helper, runs on raw runner before setup-node (no node_modules) */
54
/**
65
* @file Semver validate + compare for composite-action shells. Replaces inline
76
* bash regex + pure-bash version_lt(). Two modes: node lib/semver.mjs valid

perf/npm/json-stable-stringify.perf.mts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* oxlint-disable socket/prefer-cached-for-loop -- perf harness iterates the case matrix; loop overhead is dwarfed by the operation being benchmarked. */
21
import assert from 'node:assert/strict'
32
import path from 'node:path'
43

registry/scripts/build.mjs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* oxlint-disable socket/prefer-cached-for-loop -- iterates non-array iterables (Object.values recursion); the cached-length rewrite would be incorrect. */
21
/**
32
* @file Fast build runner using esbuild for smaller bundles and faster builds.
43
*/

scripts/build.mts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* oxlint-disable socket/no-status-emoji -- intentional emoji output. */
21

32
/**
43
* @file Build script for socket-registry monorepo. Delegates to the registry

scripts/cascade-internal.mts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
#!/usr/bin/env node
2-
/* oxlint-disable socket/prefer-cached-for-loop -- iterates non-array iterables (Map / Set / Object.entries); the cached-length rewrite would be incorrect. */
32
/**
43
* @file Recursively bump stale internal SHA pins to HEAD. socket-registry's
54
* `.github/actions/` and `.github/workflows/` files pin each other by

scripts/npm/check-trusted-packages.mts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
* packages by default. Use --all flag to check all Socket packages across all
66
* scopes.
77
*/
8-
/* oxlint-disable socket/prefer-cached-for-loop -- iterates non-array iterables (Object.entries); the cached-length rewrite would be incorrect. */
98

109
import { readFile } from 'node:fs/promises'
1110
import path from 'node:path'

scripts/npm/make-npm-override.mts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/* oxlint-disable socket/prefer-cached-for-loop -- iterates non-array iterables (Object.entries); the cached-length rewrite would be incorrect. */
21
/**
32
* @file Creates Socket registry package overrides for npm packages. Interactive
43
* CLI tool that guides users through creating secure package overrides:

0 commit comments

Comments
 (0)