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
Stuck at 95% Emitting #1126
Comments
Can you try updating your node version to 8 and see if the problem persists. Honestly, there are not much details from the logs posted. |
Same here, latest node but works if |
Experiencing this as well, but for me disabling const mix = require('laravel-mix');
mix.options({ imgLoaderOptions: { enabled: false } })
.js('resources/assets/js/app.js', 'public/js')
.sass('resources/assets/sass/app.scss', 'public/css')
.version(); |
Same error here using Windows 7 |
@ruchern I updated to Node v8.4.0, and I still got stuck at 95% emitting :/ Upon just trying to run the
This essentially just looks like something was trying to compile under Node v6.x, but now that I'm using Node v8.x, it doesn't know how. So I ran I then tried my full mix file, which contains the stock tl;dr Didn't fix my issue. Thanks for the suggestion though. |
Related: #925 ?? |
By doing some trial and error I've found out there is a check in I'm using mix in a standalone project so it skips that part, but by manually setting my public path to You might want to look into this and see if manually setting the public path by using |
@wouter2203 That's one of the many solutions I tried when googling this topic. Unfortunately, this didn't work for me. @arcanedev-maroc Not sure. I'm not actually using |
Thanks @wouter2203.....It worked |
Just like @Zedonboy too. I use @wouter2203 suggestion and it worked. In my case, I am using webpack as a stand-alone for a WordPress theme. I used |
This problem is only with incorrect output path main.js. In my case: I have this script at root of project: const mix = require('laravel-mix');
mix
.setPublicPath('web/app/themes/theme/dist')
.sass('web/app/themes/theme/assets/styles/main.scss', 'styles/main.css')
.js('web/app/themes/theme/assets/scripts/main.js', 'scripts/main.js'); Everything works. But the output looks like this at theme folder:
Them I remove main.js implementation all works fine, but mix-manifest.js presents at root directory of project: const mix = require('laravel-mix');
mix
.sass('web/app/themes/theme/assets/styles/main.scss', 'web/app/themes/theme/dist/styles/main.css'); |
Hi All and @JeffreyWay , I finally figured out why my The story is this: I am using Windows 10. I have a directory called c:\w\myproject which is a "Junction Link" that I created (its similar to a symbolic link in unix world). This My fix: I have to first do Cheers! |
@cmosguy Interesting. I too am using a Junction Link for my projects. I'll have to try that out, and see if it works. |
Hope nobody objects to me chipping in, I am facing some of the same issues when trying to use mix.js in laravel mix. This is my webpack.mix.js file
The resulting mix file shows the following:
I have tried all suggesting mentioned here as well suggestions mentioned in other posts relating this is particular issue. The outcome is still the same. The css file is created but when it gets to creating the js file, the process is stuck at 95% Any ideas on how to resolve this problem will be greatly appreciated. Thanks |
@Zedonboy @wouter2203 @webstractions suggestions worked for me. const mix = require('laravel-mix'); mix.js('resources/js/app.js', 'public/js') Hope it helps. |
@cmosguy That was my problem! After compiling from command prompt by navigating to my project without taking the symbolic link first, it works just fine! Then after trying to compile through the symbolic link, it stops working. So just to confirm, @JeffreyWay, the problem is using the I have no idea why that's a problem, but I'll leave you to figure that out. Of course, I'd like to be able to compile through my symbolic link, as I made it as a time saver. I'd like to leave this issue open until that specific issue gets resolved. |
the answer to this issue is simple.....
`
| Hope This Solves the issue. |
@peterson-umoke I tried that before even submitting this issue, and that didn't work. My problem was in a stock Laravel project, not some non-Laravel project where I was using elixir externally. Thanks for the advise, and I'm glad that works for some people, but this didn't work for me. The problem I'm reporting is the Junction Link issue, which changing the public path won't fix. |
Hi @cmosguy you save my life. |
I had the same issue because the dir is in a symlinked folder on windows. Here's how I fixed it.
This forces the correct paths and I can compile it from either folder. |
I use mix.setPublicPath('assets/public'); and its fixed my issue. |
.setPublicPath('/mypath') worked here! |
For some reason this did not work for me while this did |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Stale bot says that this is stale, but the issue still exists. So long as I continue to compile my assets through a junction, this issue persists. |
I just ran into this y-day. When I tried to be clever and symlink |
Mine was due to an improper comment in webpack.mix.js |
Even if you start the CMD as Administrator? |
I fixed something like by rm package-lock.json yarn.lock npm cache clear --force npm install` See p.s. Hi Stale Bot! |
Correct. I've tried command prompt, power shell, and git bash. All exhibited the same problem, even when elevated. And again, if I don't |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Problem is not solved yet, |
Same issue on Ubuntu 22.04 |
Environment:
Description:
I've let this issue sit for awhile, as I've been researching the issues on this repository to fix things myself, and I can't for the life of me get this to work.
Essentially, on both my working project, and a brand new Laravel installation (5.4.33), when I run:
it looks like it's working, but then it sits at 95% emitting.
Here's my console output:
I tried waiting awhile, in hopes that it's just being really slow, but I gave up after 5 minutes of nothing new (From all of the benchmarks I've heard about, this really shouldn't take longer than 8 to 10 seconds).
Steps To Reproduce:
npm install
(oryarn install
)npm run dev
Additional Details:
I did this using a fresh Laravel install, so my
package.json
andwebpack.mix.js
come straight from the source code. I've also tried this over the past three or four weeks on my working project, but I've never once gotten this to fully work.I think that this might be JavaScript related. If I comment out the compilation of JavaScript, and just run the sass mixer, I'm able to run everything correctly (This just means I have to do my JavaScript the old fashioned way).
Here's the output:
Also, I my working project, I've gotten all of my custom JS scripts to compile using the
mix.scripts()
method, which makes me believe that this issue is exclusive to themix.js()
method.I'm open to any ideas that might work, just know that I've already tried the following:
node
andnpm
node_modules
dependencies(Edit) Diagnosis:
With the help of the commenters below, we've discovered that my issue running
npm run dev
using Command Prompt (on a Windows environment), where the current directory of the prompt is relying on a Symbolic Link. When running the same command without routing through the Symbolic Link, the command runs just fine.The text was updated successfully, but these errors were encountered: