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

'Could not get file path' when opening file outside of project #152

Closed
chrisdothtml opened this issue Nov 26, 2016 · 4 comments
Closed

'Could not get file path' when opening file outside of project #152

chrisdothtml opened this issue Nov 26, 2016 · 4 comments

Comments

@chrisdothtml
Copy link

If I open a file in Atom that is outside of the project directory, the 'Could not get file path' warning shows up. It also shows up every time I switch to the tab of the file.

I initially thought this was an Atom issue, then I disabled this package, and the issue stopped happening.

Based on what I've read about past issues with this warning, I'm guessing it's happening on init.js:90. It seems like it tries to get the path based on the current project, but it's unable to since the file isn't a part of the project directory.

@ricardofbarros
Copy link
Owner

ricardofbarros commented Feb 21, 2017

Hey @chrisdothtml, this is a known issue, what is your suggestion to fix it?

@chrisdothtml
Copy link
Author

@ricardofbarros scratch that, the error is in style-settings.js:25-27 where it tries to look for a matching project for the active file.

If it were me, I'd silently fail if the active file has no matching project. The only reason you're looking for a project in the first place is to see if they have a style set in their package.json, right? If it's a file that has no project (e.g. an unsaved file), I can't imagine anyone would want it to use the style settings from any other project

@ricardofbarros
Copy link
Owner

Hey @chrisdothtml, I've just release a new version that should fix this v.3.9.0. Care to test?

Thanks

@chrisdothtml
Copy link
Author

@ricardofbarros Fixed it for me, thanks!

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