Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 13, 2025

The TypeScript workflow was incomplete and missing critical build infrastructure. No package lockfiles existed, ESLint configuration was absent, and the workflow only performed type checking without building or testing code.

Workflow Fixes

  • Replaced broken rules/Api job with proper compiler build/test job
  • Added website build verification job
  • Removed lint failure suppression (|| true)
  • Fixed npm cache paths to reference correct lockfiles

Build Infrastructure

  • Generated package-lock.json for rules compiler and Gatsby website
  • Created ESLint 9.x flat config with TypeScript support
  • Updated .gitignore to exclude build artifacts (dist/, public/, .cache/)

Code Quality

Fixed strict TypeScript violations:

// Before: Unsafe type casting
result.configVersion = (config as Record<string, unknown>).version as string ?? 'unknown';

// After: Proper type checking
const configRecord = config as unknown as Record<string, unknown>;
const versionValue = configRecord.version;
result.configVersion = typeof versionValue === 'string' ? versionValue : 'unknown';
  • Extracted formatTransformations() helper to eliminate nested ternaries
  • Excluded Deno-specific mod.ts from Node.js build (uses Deno APIs)
  • Simplified destructuring patterns with ESLint ignore comments

Security Notes

Rules Compiler: 6 vulnerabilities (2 moderate, 4 high) in @adguard/hostlist-compiler transitive dependencies (axios, follow-redirects). Requires upstream fixes.

Website: 33 vulnerabilities in Gatsby build tools. Build-time only, low risk for static site deployment.

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • unpkg.com
    • Triggering command: /usr/local/bin/node node scripts/postinstall.js (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Original prompt

Overhaul and fix the typescript workflow and deployment


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 3 commits December 13, 2025 23:52
Co-authored-by: jaypatrick <1800595+jaypatrick@users.noreply.github.com>
Co-authored-by: jaypatrick <1800595+jaypatrick@users.noreply.github.com>
Co-authored-by: jaypatrick <1800595+jaypatrick@users.noreply.github.com>
Copilot AI changed the title [WIP] Overhaul and fix TypeScript workflow and deployment Overhaul TypeScript workflow and build process Dec 14, 2025
Copilot AI requested a review from jaypatrick December 14, 2025 00:01
@jaypatrick jaypatrick marked this pull request as ready for review December 14, 2025 00:05
@jaypatrick jaypatrick merged commit 4d89dde into main Dec 14, 2025
14 checks passed
@jaypatrick jaypatrick deleted the copilot/overhaul-typescript-workflow branch December 14, 2025 00:05
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