Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

Brackets sometimes doesn't pick up file modifications #7638

Closed
dbkaplun opened this issue Apr 25, 2014 · 39 comments
Closed

Brackets sometimes doesn't pick up file modifications #7638

dbkaplun opened this issue Apr 25, 2014 · 39 comments

Comments

@dbkaplun
Copy link

Is there any way to manually reload an open file from disk? If a file has been modified outside of Brackets, sometimes Brackets doesn't pick up these changes. It would be great to be able to do it manually.

@peterflynn
Copy link
Member

@Beardtree Can you describe steps that cause that to happen? Brackets should always pick up changes made externally without you needing to take any special steps.

@dbkaplun
Copy link
Author

It happens sporadically -- I am not sure what causes this and will try to figure it out. I am running Ubuntu 14.04 so I think it is related to inotify's max_user_watches.

It would be nice to have the option to force-reload from disk, even with automatic reloading, since it is not always possible to detect file changes.

@marcelgerber
Copy link
Contributor

I'm seeing the same on Windows sometimes, even while I don't have valid steps.

@peterflynn peterflynn self-assigned this Apr 28, 2014
@peterflynn peterflynn added this to the Brackets 1.0 milestone Apr 28, 2014
@peterflynn
Copy link
Member

Reviewed - to me to continue investigating

@peterflynn
Copy link
Member

@Beardtree @SAplayer Is there any chance some of the files you're viewing/editing are accessed through a symlink? There's a known issue with file watchers and symlinks (#6692) that we plan to fix.

Also, the next time you hit this can you check the console for errors? In particular, any errors that seem related to the Node process Brackets runs? (Or if you see an error saying "File watchers went offline!").

Lastly -- if you can manage it, maybe try running Brackets for a while with all extensions disabled, to see if the problem still happens then.

@peterflynn
Copy link
Member

Oh, also @Beardtree @SAplayer do you have a sense of how often you're seeing this? Once a day, couple times a week, less...?

@marcelgerber
Copy link
Contributor

I saw it only one or two times until now, while I did something in git (but nothing big, I know there were some issues with big checkouts and so on).

@zaggino
Copy link
Contributor

zaggino commented Apr 29, 2014

This happens sometimes to me when switching Git branches (doesn't matter if through extension or just in command line) but I've never been able to replicate it 100%.

@ingorichter
Copy link
Contributor

I always see this when switching branches with git extension installed.

@njx njx changed the title Feature request: Reload From Disk in File menu Brackets sometimes doesn't pick up file modifications May 1, 2014
@njx
Copy link

njx commented May 1, 2014

Reviewed. Changing title to reflect the underlying problem, and bumping to high priority to investigate whether we can figure out what's going on (especially if @ingorichter can repro). We might also want to consider adding a manual reload command as a stopgap, but that's a secondary issue.

@marcelgerber
Copy link
Contributor

I don't know if it's related, but I saw an issue with the file tree not updating when moving files around in Brackets. I moved a css file into a folder, but it wasn't updated in Brackets.
With the new "Show Errors in statusbar" I saw an error happened in ParseUtils.js, but I unfortunately can't remember more (I don't even know if this file is in Brackets core or in an extension...)

@njx
Copy link

njx commented May 1, 2014

I think ParseUtils is from the TODO extension (I ran into that the other day too).

@marcelgerber
Copy link
Contributor

Ah yes. I thought I filed another bug about that as well ;)
We should probably file a bug there. I can do that tomorrow.

@MiguelCastillo
Copy link
Contributor

@peterflynn I run into this issue ALL the time, but I believe it has to do with my folders being symlinks. I have to reload Brackets quite a bit.

@njx
Copy link

njx commented May 1, 2014

Yeah, I run into that often because I usually have an extension I'm working on living in some other folder and temporary symlinked into my dev folder so I can have it and the Brackets source code open at the same time.

@MiguelCastillo
Copy link
Contributor

@njx the extension I code are all symlinked... Just makes sense for me :)

@awakekat
Copy link

awakekat commented May 6, 2014

Having what sounds like a similar problem. I use codekit for compiling scss and slim files. When I start a project and the css and html files are created they show up in the finder and code kit's refreshed list of files but not in Brackets - even when I right click the Brackets file tree and choose Refresh File Tree - nothing. I have to shut down and restart Brackets to see the index.html file and css files.
sprint 38 experimental build 0.38.0-12606 (release 4df8afd)
OSX Version 10.9.2

@baursak
Copy link

baursak commented Jul 9, 2014

Today I have started to use Brackets (0.42) and at first Live Preview worked well with my HTML files with Javascript snippets inside their body (just needed to save entire HTML file so that Javascript snippet changes would be picked up by Brackets). - However a couple of hours later it stopped working as before. - To see changes I have now to save HTML and after that to refresh manually Chrome. - First I cleaned cache (as suggested). - Then reinstalled Brackets. - But happy hours are gone :( - What else have I to do??? (Windows 7 x 64 + Emmet plugin, nothing else)

@zaggino
Copy link
Contributor

zaggino commented Jul 10, 2014

@baursak Do you have any errors at all in the console? (F12 to open)

@peterflynn
Copy link
Member

@baursak Can you file a new issue? That does not sound related to what other people are describing here, so it'd be better not to mix the two discussion threads...

@baursak
Copy link

baursak commented Jul 10, 2014

Posted this here #8351

@nethip
Copy link
Contributor

nethip commented Feb 5, 2015

Moving this to 1.3

@andyburke
Copy link

I mistakenly began discussing this issue in #7344. But this seems to be exactly what I am experiencing, see comments here:

#7344 (comment)
#7344 (comment)
#7344 (comment)

@ryanstewart
Copy link
Contributor

Moving this to tackle in 1.4.

@dynamicdan
Copy link

This also happens when files are modified outside of brackets via the command line or scripts. Most likely related to the "within 1 second" issue that is also logged here. File changes don't get picked up when they happen within 1 second.

#7929

@nethip nethip modified the milestones: Release 1.5, Release 1.4 Aug 26, 2015
@jpcaram
Copy link

jpcaram commented Sep 1, 2015

This is consistently happening to me when the file is edited externally. No symlinks but on network drive. Edits to my files take minutes (big logs). Refreshing the file tree as suggested does not fix it.

I used to be able to fix it by doing touch myfile.txt but not any more. No idea why.

@menocomp
Copy link

The same issue is still happen to me.
Whenever I run npm commands that add changes to the package.json file, that file never change and I have to restart brackets.

@busykai
Copy link
Contributor

busykai commented Feb 29, 2016

@nethip, I have a grasp of what might be going on with this. let me take this issue.

@marcelgerber
Copy link
Contributor

Finally fixed by #12353.
Closing.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests