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

TypeError: Cannot read property 'optOut' of undefined #6

Open
AndyOGo opened this issue Oct 5, 2016 · 8 comments
Open

TypeError: Cannot read property 'optOut' of undefined #6

AndyOGo opened this issue Oct 5, 2016 · 8 comments

Comments

@AndyOGo
Copy link

AndyOGo commented Oct 5, 2016

The configstore randomly throws this error.

.../node_modules/sync-files/node_modules/configstore/index.js:86
    return this.all[key];
                   ^
TypeError: Cannot read property 'optOut' of undefined
    at Object.Configstore.get (.../node_modules/sync-files/node_modules/configstore/index.js:86:17)
    at UpdateNotifier.check (.../node_modules/sync-files/node_modules/update-notifier/index.js:47:18)
    at module.exports (.../node_modules/sync-files/node_modules/update-notifier/index.js:127:17)
    at Object.<anonymous> (.../node_modules/sync-files/bin/sync-files.js:121:3)
    at Module._compile (module.js:413:34)
    at Object.Module._extensions..js (module.js:422:10)
    at Module.load (module.js:357:32)
    at Function.Module._load (module.js:314:12)
    at Function.Module.runMain (module.js:447:10)
    at startup (node.js:146:18)
@AndyOGo
Copy link
Author

AndyOGo commented Oct 21, 2016

This bug can be "disabled" by setting --no-notify-update

@wamoyo
Copy link

wamoyo commented Oct 25, 2018

I have the same issue. It only happens once in a while though. What does --no-notify-update mean?

@AndyOGo
Copy link
Author

AndyOGo commented Oct 26, 2018

Please see the usage secrion of the readme
https://github.com/byteclubfr/node-sync-files/blob/master/README.md#usage

@wamoyo
Copy link

wamoyo commented Oct 26, 2018

Right, that's the help text. But I don't understand the relationship between that option and this error?

@wamoyo
Copy link

wamoyo commented Oct 26, 2018

It's a great module, by the way! Hasn't given me any other problems ever : ) Even this occasional error messages isn't really a problem, just kind of confusing. Can't tell why it's coming up, or why it only happens sometimes.

@AndyOGo
Copy link
Author

AndyOGo commented Oct 26, 2018

Okay.
The stack trace above tells you where it comes from.
Or just debug it if you want to know, https://github.com/byteclubfr/node-sync-files/blob/master/bin/sync-files.js#L120-L122

@AndyOGo
Copy link
Author

AndyOGo commented Oct 26, 2018

btw update-notifier is another package
https://github.com/yeoman/update-notifier

@wamoyo
Copy link

wamoyo commented Oct 26, 2018

Thank, man!

podgorniy added a commit to podgorniy/media-manager that referenced this issue Apr 20, 2019
- loading indicator
- scroll to items when one is in zoomed view
- axios for requests (because it can cancel request)
- start for isomorphic-data-driven router
- add response delay (500-1500ms) when in dev mode
- tweak to fix `sync-files` bug at byteclubfr/node-sync-files#6
- build
podgorniy added a commit to podgorniy/media-manager that referenced this issue Apr 20, 2019
- loading indicator
- scroll to items when one is in zoomed view
- axios for requests (because it can cancel request)
- start for isomorphic-data-driven router
- add response delay (500-1500ms) when in dev mode
- tweak to fix `sync-files` bug at byteclubfr/node-sync-files#6
- build
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