question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Not all Webpack blocks included in Canary install

See original GitHub issue

What version of Next.js are you using?

11.1.3-canary.41

What version of Node.js are you using?

14.16.1

What browser are you using?

Vivaldi, Firefox

What operating system are you using?

macOS

How are you deploying your application?

yarn run dev

Describe the Bug

In order to test Framer’s new Handshake feature, I followed their steps outlined here and installed the latest Canary build of Next. However, the build fails because Next Cannot find module './blocks/images' It seems it’s not installed because indeed, the file/folder is not in my node_modules no matter how many times I’ve clean cache or delete the node_modules The same issue has already been raised here but subsequently closed without resolution. I can confirm that somewhere after beta 7 this broke.

I’ve attached a screenshot of the relevant code and file tree.

Screenshot 2021-10-04 at 12 42 01

Expected Behavior

Next installs all its own dependencies

To Reproduce

Follow the steps outlined in the Framer Handshake guide

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:8 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
styflecommented, Nov 2, 2021

@kevroadrunner Nice find! I was able to reproduce.

$ yarn init -y && yarn add next
✨  Done in 4.30s.

$ yarn autoclean
info ".yarnclean" does not exist. Autoclean will delete files specified by ".yarnclean". Run "autoclean --init" to create ".yarnclean" with the default entries.
✨  Done in 0.03s.

$ yarn autoclean --init
info Created ".yarnclean". Please review the contents of this file then run "yarn autoclean --force" to perform a clean.
✨  Done in 0.03s.

$ yarn autoclean
info This command required the "--force" flag to perform the clean. This is a destructive operation. Files specified in ".yarnclean" will be deleted.
✨  Done in 0.03s.

$ yarn autoclean --force
info Removed 774 files
info Saved 1.87 MB.
✨  Done in 0.48s.

You can see it removed 774 files which are probably all necessary to run Next.js, including node_modules/next/dist/build/webpack/config/blocks/images/**

That being said, yarn has a lot of warnings around this behavior explaining its destructive nature and that you should review the contents before running.

So this is not a Next.js bug, this would impact all npm packages in node_modules.

I suggest updating your .yarnclean file to delete fewer files.

1reaction
maxsteenbergencommented, Oct 4, 2021

I did try that earlier and again just now: the issue persists.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Webpack Canary - GitHub
Canary tooling for checking webpack dependencies against specific webpack versions ... The squawk command can receive all the CLI options listed bellow, ...
Read more >
Google Chrome Canary Build doesn't fully update - Part Deux
Attempt to install the update. Chrome prompts you to restart. After restart the version stays at 10.0.639.0 and does not update fully.
Read more >
Library functions available for canary scripts
Explains the built-in functions included in CloudWatch Synthetics that you can use to write your own canary scripts.
Read more >
Canary Deployments - GitLab Docs
A popular Continuous Deployment strategy, where a small portion of the fleet is updated to the new version of your application.
Read more >
terraform-aws-modules/lambda/aws
Terraform module, which creates almost all supported AWS Lambda resources as well as taking care of building and packaging of required ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found