Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Investigate why the clean webpack plugin is failing #4931

Open
cstns opened this issue Dec 17, 2024 · 0 comments
Open

Investigate why the clean webpack plugin is failing #4931

cstns opened this issue Dec 17, 2024 · 0 comments
Assignees
Labels
area:frontend For any issues that require work in the frontend/UI bug Something isn't working needs-triage Needs looking at to decide what to do

Comments

@cstns
Copy link
Contributor

cstns commented Dec 17, 2024

Current Behavior

Changing the login layout surfaced a webpack but which would need more investigation.

The initial logo wass replaced with a new one but I did not catch it locally because webpack crashed.

[webpack-cli] Error: clean-webpack-plugin: Cannot delete files/folders outside the current working directory. Can be overridden with the `dangerouslyAllowCleanPatternsOutsideProject` option.
    at CleanWebpackPlugin.removeFiles (/home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/clean-webpack-plugin/dist/clean-webpack-plugin.js:211:15)
    at CleanWebpackPlugin.handleDone (/home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/clean-webpack-plugin/dist/clean-webpack-plugin.js:173:12)
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/clean-webpack-plugin/dist/clean-webpack-plugin.js:89:12
    at Hook.eval [as callAsync] (eval at create (/home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:9:1)
    at Watching._done (/home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/webpack/lib/Watching.js:314:28)
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/webpack/lib/Watching.js:229:21
    at Compiler.emitRecords (/home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/webpack/lib/Compiler.js:1044:4)
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/webpack/lib/Watching.js:205:22
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/webpack/lib/Compiler.js:1007:14
    at Hook.eval [as callAsync] (eval at create (/home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1)
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/webpack/lib/Compiler.js:1004:27
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/neo-async/async.js:2818:7
    at done (/home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/neo-async/async.js:3522:9)
    at Hook.eval [as callAsync] (eval at create (/home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:6:1)
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/webpack/lib/Compiler.js:833:33
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/graceful-fs/graceful-fs.js:143:16
    at /home/cstns/Workspace/FlowFuse/dev-env/packages/flowfuse/node_modules/graceful-fs/graceful-fs.js:61:14
    at FSReqCallback.oncomplete (node:fs:187:23)

Upon restart it did not clear it's former built assets (including the deleted logo) and continued to serve stale images

Expected Behavior

weback should clean up after itself, not sure why it's considering the dist directory outside of the 'current working directory'

Steps To Reproduce

delete an image/asset, check if the application picks up on it

Environment

  • FlowFuse version: 2.11
  • Node.js version: n/a
  • npm version: n/a
  • Platform/OS: n/a
  • Browser: n/a

Have you provided an initial effort estimate for this issue?

I have provided an initial effort estimate

@cstns cstns added bug Something isn't working needs-triage Needs looking at to decide what to do area:frontend For any issues that require work in the frontend/UI labels Dec 17, 2024
@cstns cstns self-assigned this Dec 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:frontend For any issues that require work in the frontend/UI bug Something isn't working needs-triage Needs looking at to decide what to do
Projects
Status: No status
Development

No branches or pull requests

1 participant