Skip to content

Replace globby with glob#921

Open
roli-lpci wants to merge 1 commit intosc-forks:masterfrom
roli-lpci:chore/replace-globby-with-glob
Open

Replace globby with glob#921
roli-lpci wants to merge 1 commit intosc-forks:masterfrom
roli-lpci:chore/replace-globby-with-glob

Conversation

@roli-lpci
Copy link
Copy Markdown

@roli-lpci roli-lpci commented Feb 28, 2026

Summary

  • Replace globby with glob to resolve CJS/ESM compatibility issues
  • globby v10 is pinned because newer versions are ESM-only, incompatible with Hardhat v2's CJS internals; glob supports both CJS and ESM via conditional exports
  • Single usage site: globby.sync([files])globSync(files) with identical behavior

Changes

  • plugins/resources/nomiclabs.utils.js — replace globby.sync with globSync from glob
  • package.json — swap globby ^10.0.1 for glob ^10.4.5
  • README.md — update documentation link from globby to glob
  • yarn.lock — regenerated

Testing

  • Unit tests: 135 passing, 0 failing, 1 pending
  • Integration tests: 42 passing, 0 failing, 1 pending
  • The --file test/<glob*> and --testfiles test/<fileName> integration tests both pass, confirming glob pattern matching works identically

Addresses #912

@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Feb 28, 2026

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 96.55%. Comparing base (8e52fd7) to head (e36cf16).
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #921   +/-   ##
=======================================
  Coverage   96.55%   96.55%           
=======================================
  Files          19       19           
  Lines        1073     1073           
=======================================
  Hits         1036     1036           
  Misses         37       37           

☔ View full report in Codecov by Sentry.
📢 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.

Replace the globby dependency with glob, which supports both CJS and
ESM. This resolves compatibility issues with Hardhat v2 which runs
CJS internally, as globby has moved to ESM-only in newer versions.

- Replace `globby.sync([files])` with `globSync(files)` from glob
- Update README documentation links
- Use glob v10 for broad Node.js compatibility

Addresses sc-forks#912

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@roli-lpci roli-lpci force-pushed the chore/replace-globby-with-glob branch from 04cb7c3 to e36cf16 Compare February 28, 2026 01: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