Skip to content

chore(cache): stop relying on globalThis.gc being untyped - #7253

Merged
bartlomieju merged 1 commit into
denoland:mainfrom
tomas-zijdemans:untyped-globalThis
Jul 30, 2026
Merged

chore(cache): stop relying on globalThis.gc being untyped#7253
bartlomieju merged 1 commit into
denoland:mainfrom
tomas-zijdemans:untyped-globalThis

Conversation

@tomas-zijdemans

@tomas-zijdemans tomas-zijdemans commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Deno canary types globalThis.gc, so the @ts-expect-error above it is now unused and deno test fails with TS2578. Reading gc through Reflect.get works on both stable and canary, and keeps the test honest about gc being optional.

Partly solves #7219. The other 24 canary errors are a Deno-side URLPattern type collision, filed separately: denoland/deno#36346

Tested on 2.9.3 and canary 2.9.4+41e97d3, including deno test --v8-flags="--expose-gc" cache/

@github-actions github-actions Bot added the cache label Jul 29, 2026
@codecov

codecov Bot commented Jul 29, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.00%. Comparing base (ad7c87b) to head (510c2d3).

Additional details and impacted files
@@           Coverage Diff            @@
##             main    #7253    +/-   ##
========================================
  Coverage   95.00%   95.00%            
========================================
  Files         617      617            
  Lines       51674    51422   -252     
  Branches     9326     9277    -49     
========================================
- Hits        49093    48855   -238     
+ Misses       2038     2029     -9     
+ Partials      543      538     -5     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bartlomieju
bartlomieju merged commit f77a133 into denoland:main Jul 30, 2026
17 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants