[Github-comments] [geany] Geany Freezes when unable to safe an edited file to it's FTP dir, no timeout on atempt saving file (#828)

Thomas Martitz notifications at xxxxx
Wed Dec 23 00:14:57 UTC 2015


Am 22.12.2015 um 23:58 schrieb elextr:
> On 23 December 2015 at 07:54, Thomas Martitz <notifications at github.com>
> wrote:
>
> > Am 22.12.2015 um 22:41 schrieb elextr:
> > >
> > > Once we had the buffer copy we could spawn the plain file write or
> > > |g_file_set_contents| methods as separate threads.
> > >
> > >
> >
> > We have that, haven't we?
> >
> > I was suggested a poll() so that we don't introduce threads into geany,
> > however for this specific use case a fire-and-forget worker thread might
> > be easier to deal with.
> >
>
> ​Nah, we need the result back. But g_task can call a callback when the job
> finishes.
>
> ​More complex is how to handle user actions that involve the file before
> svaing is finished. Examples are reload, another save, build. This is
> really the place where incomplete asynchronous saving can cause problems,
> and its fairly complex to handle.

I didnt suggest an asynchronous saving. Just one where the main thread 
can keeps responsive instead of freeze (and perhaps offer cancellation 
of the saving if it takes too long).

I agree that most, if not all, user interaction should be blocked during 
save, but that doesn't mean the UI has to freeze up.

Best regards.


---
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/828#issuecomment-166766696
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20151222/7df248eb/attachment.html>


More information about the Github-comments mailing list