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.

Whitelist globs not matching

See original GitHub issue

I’m not sure if the whitelist globs are working, and I’m not sure how to test it either. I know the globs themselves match when using minimatch, but format on save doesn’t work on those files. I’ve also tried blacklisting what I don’t want, and that doesn’t seem to work. My globs look like:

/Users/USERNAME/Sites/PROJECT/**/*

Does it not use the full path? I’ve also tried just **/PROJECT/**/*.

Output of Prettier: Debug—and it looks like it’s a problem with Prettier: Debug itself and has nothing to do with my problem, but it may be relevant:

[Enter steps to reproduce:]

Atom: 1.18.0 x64 Electron: 1.3.15 OS: Mac OS X 10.12.6 Thrown From: prettier-atom package 0.29.0

Stack Trace

Uncaught Error: ENOENT: no such file or directory, open ‘package.json’

At fs.js:640

Error: ENOENT: no such file or directory, open 'package.json'
    at Error (native)
    at Object.fs.openSync (fs.js:640:18)
    at Object.module.(anonymous function) [as openSync] (ELECTRON_ASAR.js:168:20)
    at Object.fs.readFileSync (fs.js:508:33)
    at Object.fs.readFileSync (ELECTRON_ASAR.js:501:29)
    at /packages/prettier-atom/node_modules/load-json-file/index.js:11:38)
    at Function.module.exports.sync (/packages/prettier-atom/node_modules/read-pkg/index.js:40:25)
    at getDebugInfo (/packages/prettier-atom/dist/helpers.js:196:34)
    at displayDebugInfo (/packages/prettier-atom/dist/displayDebugInfo.js:7:14)
    at /packages/prettier-atom/dist/main.js:49:3)
    at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:265:35)
    at /Applications/Atom.app/Contents/Resources/app/src/command-registry.js:3:65
    at Object.didConfirmSelection (/Applications/Atom.app/Contents/Resources/app/node_modules/command-palette/lib/command-palette-view.js:106:35)
    at SelectListView.confirmSelection (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-select-list/src/select-list-view.js:313:26)
    at HTMLDivElement.core:confirm (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-select-list/src/select-list-view.js:81:20)
    at CommandRegistry.module.exports.CommandRegistry.handleCommandEvent (/Applications/Atom.app/Contents/Resources/app/src/command-registry.js:265:35)
    at /Applications/Atom.app/Contents/Resources/app/src/command-registry.js:3:65
    at KeymapManager.module.exports.KeymapManager.dispatchCommandEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:610:22)
    at KeymapManager.module.exports.KeymapManager.handleKeyboardEvent (/Applications/Atom.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:401:28)
    at WindowEventHandler.module.exports.WindowEventHandler.handleDocumentKeyEvent (/Applications/Atom.app/Contents/Resources/app/src/window-event-handler.js:100:42)
    at HTMLDocument.<anonymous> (/Applications/Atom.app/Contents/Resources/app/src/window-event-handler.js:3:65)

Commands

     -1:56.7.0 core:save (input.hidden-input)
     -1:55.9.0 core:undo (input.hidden-input)
  2x -1:54.5.0 core:save (input.hidden-input)
     -1:51.5.0 core:undo (input.hidden-input)
     -1:50.8.0 core:save (input.hidden-input)
     -0:19.6.0 command-palette:toggle (input.hidden-input)
     -0:16.9.0 core:confirm (input.hidden-input)
     -0:16.9.0 prettier:debug (input.hidden-input)

Non-Core Packages

busy-signal 1.3.0 
change-case 0.6.5 
flow-ide 1.4.1 
intentions 1.1.2 
language-babel 2.57.7 
language-javascript-jsx 0.3.7 
language-pug 0.0.21 
linter 2.1.2 
linter-ui-default 1.2.2 
minimap 4.27.1 
prettier-atom 0.29.0 
save-workspace 0.4.0 
selection-highlight 0.1.6 
simple-drag-drop-text 0.3.4 
split-diff 1.3.0 

Thanks!

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
pwolfertcommented, Aug 3, 2017

Upgrading gave me this option, which works for me:

screen shot 2017-08-03 at 9 32 00 am
0reactions
robwisecommented, Aug 27, 2017

I agree but I can’t reproduce the original issue (it seems to work fine AFAICT). I will close for now and we can reopen if others have this issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

npm glob pattern not matching subdirectories - Stack Overflow
json , I have a scripts block that uses **/*Test.js to match files. When run via npm , they do not match sub-directories...
Read more >
GLOB Patterns - WhiteSource Knowledge Base - Confluence
"GLOB patterns" or "globs" are the wildcards used in a process of matching strings. GLOB patterns are similar to regular expressions (a.k.a ...
Read more >
ignore::Match - Rust - Docs.rs
The highest precedent glob matched indicates the path should be ignored. Whitelist(T). [−] Expand description. The highest precedent glob matched indicates ...
Read more >
Managing Library Whitelist Rules - Mend Documentation
Whitelist rules are regular expressions (regex) for matching libraries in your inventory or tickets. Libraries can be added to your Whitelist ...
Read more >
WhiteBlackList (ClassGraph 4.6.20 API) - javadoc.io
Whitelisted items (whole-string match). protected java.util.Set<java.lang.String>, whitelistGlobs. Whitelist glob strings. protected java.util.
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