GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — fix: ignore the error that directoryPath is not a directory by liximomo · Pull Request #226 · webpack/watchpack

Conversation

@liximomo

@liximomo liximomo commented Dec 12, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

The error is caused by a specific alias config of webpack, considering the following example:

// webpack.config.js
module.exports = {
  resolve: {
    alias:  {
       "@/foo": ["src/foo/index", "src/foo"] 
     }
  }
}

With the above config, we will get a DirectoryWatcher watching src/foo/index. If you happen to have a src/foo file on your filesystem, you will see the error:

Watchpack Error (initial scan): Error: ENOTDIR: not a directory, scandir '/Users/xx/demo/src/foo'

We could safely ignore the error of ENOTDIR in whatever cases.

Related Issues:
nuxt/bridge#226

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

AlexeyKosov reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@liximomo
fix: ignore the error that directoryPath is not a directory
fe84a8b
@linux-foundation-easycla

linux-foundation-easycla Bot commented Dec 12, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

CLA Signed

The committers listed above are authorized under a signed CLA.

  • ✅ login: liximomo / name: X.L (fe84a8b)

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@liximomo
fix: format lint
9ccfcf3
@codecov

codecov Bot commented Dec 12, 2022 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 78.11%. Comparing base (dc690bb) to head (9ccfcf3).
⚠️ Report is 110 commits behind head on main.

Files with missing lines Patch % Lines
lib/DirectoryWatcher.js 0.00% 2 Missing ⚠️

❗ There is a different number of reports uploaded between BASE (dc690bb) and HEAD (9ccfcf3). Click for more details.

HEAD has 5 uploads less than BASE
Flag BASE (dc690bb) HEAD (9ccfcf3)
integration 25 20
Additional details and impacted files
@@             Coverage Diff             @@
##             main     #226       +/-   ##
===========================================
- Coverage   92.12%   78.11%   -14.01%     
===========================================
  Files           6        6               
  Lines        1041     1042        +1     
  Branches      249      250        +1     
===========================================
- Hits          959      814      -145     
- Misses         82      228      +146     
Flag Coverage Δ
integration 78.11% <0.00%> (-14.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ 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.
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@alexander-akait alexander-akait mentioned this pull request Apr 17, 2026
AliasPlugin crash when file is deleted or rename (have to restart to make it work) webpack/enhanced-resolve#395
Closed
@alexander-akait alexander-akait mentioned this pull request Oct 16, 2026
fix: treat a file where a watched directory should be like a missing directory #360
Merged
@alexander-akait Claude

alexander-akait commented Oct 16, 2026

Copy link
Copy Markdown
Member

Thanks for the report and the analysis! Closing in favor of #360.

Hiding the ENOTDIR log was only half of the problem: with src/foo a file, nothing watched for it to become a directory, so a later src/foo/index.js was not reported. #360 treats ENOTDIR like a missing directory instead, so the error goes away and the file is reported once src/foo is a directory. It has a test for both.


Generated by Claude Code

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@alexander-akait alexander-akait closed this Oct 16, 2026
@github-actions github-actions Bot mentioned this pull request Oct 17, 2026
chore(release): new release #357
Merged
@alexander-akait alexander-akait mentioned this pull request Oct 17, 2026
fix(deps): update watchpack to 2.6.2 webpack/webpack#22743
Merged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@liximomo @alexander-akait
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.