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

File System 'Jitter' Results In Many Unnecessary Rebuild Triggers #50

Open
7enderhead opened this issue Sep 21, 2016 · 5 comments

Comments

@7enderhead
Copy link

commented Sep 21, 2016

  • editing rst files with Vim + savevers autbackup feature
  • this results in a file's timestamp to be changed multiple times on each save
  • sphinx-autobuild is triggered by the first change -> rebuild
  • all subsequent file system changes are already queued and get processed -> useless rebuilds
  • proof of concept quick and dirty hack in SphinxBuilder.call:
    • remember time of last call to build()
    • don't retrigger if delta below a certain threshold (5 seconds?)
  • this cures the problem, but I think this could be more cleanly addressed in the file system watchdog layer
@slestak

This comment has been minimized.

Copy link

commented Apr 5, 2019

--ignore argument resolves this I believe.

@nkuttler

This comment has been minimized.

Copy link

commented Aug 4, 2019

I think I have the same problem when using git:

  • all subsequent file system changes are already queued and get processed -> useless rebuilds

Whenever I switch branches I get a new sphinx build for each changed file into the queue, but I only need one single rebuild of the docs. Neither --delay nor --poll seem to help with this, I was hoping that polling would disable inotify (which I assume is used), and I was hoping that delaying would result in only the top queued rebuild being triggered.

If you need help fixing this please let me know, I use sphinx-autobuild on multiple projects and seem to face this everywhere.

@nkuttler

This comment has been minimized.

Copy link

commented Aug 6, 2019

Did somebody comment and delete their comment? -r doesn't solve the problem at all, excluding the repository is wrong because large parts of the sphinx documentation are docstrings and such.

@slestak

This comment has been minimized.

Copy link

commented Aug 6, 2019

I did delete my comment, I apologize. It was redundant with the --ignore info discussed above. I'll leave this here.

@nkuttler

This comment has been minimized.

Copy link

commented Aug 7, 2019

Neither --ignore nor --re-ignore seem related to the problem described here. The problem seems to be that watchdog fills up the queue with events that are irrelevant to sphinx-autobuild, and that the queue should be cleared sometimes. Otherwise sphinx-autobuild will repeat the same action with the same outcome over and over and just use up system resources.

Looking at the watchdog I couldn't find a way to do this either, so perhaps I need to find an entirely different solution to build my docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.