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

🚨Error writing to cache using Vuetify À-la-carte #1397

Closed
aldrinmartoq opened this issue May 19, 2018 · 2 comments
Closed

🚨Error writing to cache using Vuetify À-la-carte #1397

aldrinmartoq opened this issue May 19, 2018 · 2 comments

Comments

@aldrinmartoq
Copy link

🐛 bug report

In a Vuetify project we are trying to reduce the build size using À la carte, but when parcel builds/serves/watch the project, the message "Error writing to cache" appears.

🎛 Configuration (.babelrc, package.json, cli command)

package.json:

{
  "name": "parcel-vuetify-error",
  "version": "1.0.0",
  "description": "Bug in parcel-bundler (Error writing to cache)",
  "main": "index.html",
  "author": "Aldrin Martoq",
  "license": "MIT",
  "private": true,
  "dependencies": {
    "vue": "^2.5.16",
    "vue-hot-reload-api": "^2.3.0",
    "vuetify": "^1.0.18"
  },
  "devDependencies": {
    "@vue/component-compiler-utils": "^1.2.1",
    "parcel-bundler": "^1.8.1",
    "pug": "^2.0.3",
    "stylus": "^0.54.5",
    "stylus-loader": "^3.0.2",
    "vue-template-compiler": "^2.5.16"
  }
}

🤔 Expected Behavior

There should be no errors writing to the cache, here is Vuetify without a la carte:

$ rm -fr .cache; node_modules/.bin/parcel build --log-level 3 src/index.full.html | tee
⏳  Building...

⏳  Building index.full.html...
⏳  Building main.full.js...
⏳  Building vuetify.js...
⏳  Building vue.runtime.esm.js...
⏳  Building vuetify.min.css...
⏳  Building App.vue...
✨  Built in 9.66s.

dist/main.full.f6ae72d6.js     294.06 KB    15.33s
dist/main.full.b08594c3.css    244.46 KB     1.56s
dist/index.full.html               394 B     856ms
dist/main.full.cdebc620.map          0 B    12.44s

😯 Current Behavior

Here is Vuetify using a la carte, with the error:

$ rm -fr .cache; node_modules/.bin/parcel build --log-level 3 src/index.a-la-carte.html | tee
⏳  Building...

⏳  Building index.a-la-carte.html...
⏳  Building main.a-la-carte.js...
⏳  Building vue.runtime.esm.js...
⏳  Building app.styl...
⏳  Building App.vue...
⏳  Building index.js...
⏳  Building index.js...
⏳  Building index.js...
⏳  Building index.js...
⏳  Building index.js...
🚨  Error writing to cache
⏳  Building index.js...
⏳  Building helpers.js...
⏳  Building VToolbar.js...
⏳  Building VToolbarSideIcon.js...
⏳  Building VBtn.js...
⏳  Building VApp.js...
⏳  Building VContent.js...
⏳  Building VContainer.js...
⏳  Building VFlex.js...
⏳  Building VLayout.js...
⏳  Building VAvatar.js...
⏳  Building console.js...
⏳  Building application.js...
⏳  Building theme.js...
⏳  Building options.js...
⏳  Building goTo.js...
⏳  Building _toolbar.styl...
⏳  Building applicationable.js...
⏳  Building colorable.js...
⏳  Building themeable.js...
⏳  Building ssr-bootable.js...
⏳  Building scroll.js...
⏳  Building _buttons.styl...
⏳  Building positionable.js...
⏳  Building routable.js...
⏳  Building toggleable.js...
⏳  Building registrable.js...
⏳  Building _app.styl...
⏳  Building resize.js...
⏳  Building _content.styl...
⏳  Building _grid.styl...
⏳  Building _avatars.styl...
⏳  Building grid.js...
⏳  Building app-theme.js...
⏳  Building app-breakpoint.js...
⏳  Building index.js...
⏳  Building index.js...
⏳  Building easing-patterns.js...
🚨  Error writing to cache
⏳  Building ripple.js...
🚨  Error writing to cache
⏳  Building colorUtils.js...
⏳  Building theme.js...
⏳  Building VIcon.js...
⏳  Building VProgressCircular.js...
🚨  Error writing to cache
🚨  Error writing to cache
🚨  Error writing to cache
🚨  Error writing to cache
⏳  Building transformSRGB.js...
⏳  Building transformCIELAB.js...
⏳  Building _icons.styl...
⏳  Building _progress-circular.styl...
🚨  Error writing to cache
🚨  Error writing to cache
✨  Built in 7.30s.

dist/main.a-la-carte.f3a6476e.css    112.77 KB     7.25s
dist/main.a-la-carte.0f673f2b.js     110.78 KB    60.22s
dist/index.a-la-carte.html               406 B     613ms
dist/main.a-la-carte.e4180cd3.map          0 B    51.50s

💁 Possible Solution

I couldn't find how to make the log show the root cause of the error 😞

🔦 Context

We need this to reduce our app size. In the mean time, we just disable the cache in production (one of the key features of parcel!).

💻 Code Sample

Sample project here: https://github.com/aldrinmartoq/parcel-vuetify-error-writing-to-cache

🌍 Your Environment

Software Version(s)
Parcel 1.7.1 & 1.8.1
Node 8.9.4
Yarn 1.6.0
Operating System Mac OS X 10.13.4 & Ubuntu Linux 18.04

Thank you very much,

Aldrin.

@DeMoorJasper
Copy link
Member

This is causing the issue: ENOENT: no such file or directory, stat '/Users/jasperdemoor/Downloads/parcel-vuetify-error-writing-to-cache-master/node_modules/vuetify/src/stylus/settings/*'

Apparently FSCache is trying to get mtime of a wildcard import, which doesn't work

@DeMoorJasper
Copy link
Member

See #1410 for the fix

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

No branches or pull requests

2 participants