GithubHelp home page GithubHelp logo

Comments (5)

davvid avatar davvid commented on May 25, 2024 1

Oh sweet, glad that we've narrowed in on a root cause.

You're in luck! We already have a git config --global cola.refreshonfocus true setting that makes it refresh whenever the window is focused.

https://git-cola.readthedocs.io/en/latest/git-cola.html#cola-refreshonfocus

Note to self: expose that setting in the settings dialog so that it's easier to discover.

Thanks for the link to the Qt signal threading approach. That might be a good approach -- I'll study it a bit to see if there's something we can adopt from that approach. Thanks for following up!

from git-cola.

sthalik avatar sthalik commented on May 25, 2024

It even affects line-by-line reverts. I'm getting it on a smaller codebase without any ongoing builds.

from git-cola.

davvid avatar davvid commented on May 25, 2024

Dang, sorry about that. As a quick test, does disabling the file system notifications help?

git config --global cola.inotify false

Hopefully we can find a way to reproduce this issue so that we can narrow in on a fix.

We have a lot of places where we use queued Qt signals ~ git grep type=Qt.QueuedConnection

This is done because some signals can be delivered from background tasks. We queue the signals so that the main thread services them. Using direct (default) connections can cause widgets to be created / modified by a background task, which is not allowed by Qt.

I mention that in case there's some subset of these signals that can use the default (non-queued) connections to avoid this issue. 🤞 for a reproducer or the possibility that git config cola.inotify false is a viable workaround.

from git-cola.

sthalik avatar sthalik commented on May 25, 2024

I can't reproduce it with inotify disabled. Actually it works great that way— if only the tree got refreshed each time the Cola window is focused/unminimized there wouldn't be a need for inotify for my use-case.

If you want more control over Qt signal threading, maybe try using my nuclear solution. Unless the GIL interferes with that. Other than that I'm ready to test any patches that emit extra debug info.

from git-cola.

sthalik avatar sthalik commented on May 25, 2024

I was having tons of issues with inotify enabled:

  • multi-second UI freezes even with no write activity
  • rebase failing if Cola/DAG were open
  • this bug report's race condition
  • having multiple Colas with the same repo open by accident taking CPU and IO resources

Now with both of your suggestions applied, all these issues were resolved and my user experience has greatly improved. I won't be personally needing to use inotify anymore, but please tag me if you make attempts at fixing Windows issues.

Thanks.

from git-cola.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.