Skip to content
This repository has been archived by the owner on Jul 1, 2023. It is now read-only.

file updates after the first one are not detected when using gedit #13

Open
lx4r opened this issue Apr 19, 2018 · 3 comments
Open

file updates after the first one are not detected when using gedit #13

lx4r opened this issue Apr 19, 2018 · 3 comments

Comments

@lx4r
Copy link
Owner

lx4r commented Apr 19, 2018

reported on Linux Mint, reproduced on Ubuntu

@lx4r lx4r added the bug label Apr 19, 2018
@lx4r
Copy link
Owner Author

lx4r commented Apr 23, 2018

rebuilt binary and now everything seems to work fine

@lx4r lx4r closed this as completed Apr 23, 2018
@lx4r
Copy link
Owner Author

lx4r commented Apr 28, 2018

weird, bug appeared again, suspecting a problem with fs.watch and Linux as the bug does not appear on Windows 10

@lx4r lx4r reopened this Apr 28, 2018
@lx4r
Copy link
Owner Author

lx4r commented Apr 30, 2018

I did some more testing and I was only able to reproduce the bug using gedit on Ubuntu 17.10. The issue appeared both when I opened the file in gedit first and then in MarkdownFox and the other way round.
I was not able to reproduce the issue with nano, Visual Studio Code or Atom (all also on Ubuntu 17.10).
A possible cause for the issue could be that gedit handles file saving different than the other editors and maybe removes the old file and saves a new one. I imagine such behaviour could cause problems with the file's inode and Node's fs.watch (see docs). Unfortunately I have no idea how to fix this except using the more inefficient fs.watchFile and I don't want to do that.

TL;DR: Don't know how to fix this issue that seems to be specific for gedit. Help appreciated.

@lx4r lx4r changed the title file updates after the first one are not detected file updates after the first one are not detected when using gedit Apr 30, 2018
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

1 participant