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 chooser freezes UI #29

Open
deniederhut opened this issue Jul 19, 2019 · 9 comments
Open

File chooser freezes UI #29

deniederhut opened this issue Jul 19, 2019 · 9 comments

Comments

@deniederhut
Copy link

Describe the bug
In --dev mode (possibly also others) vixen freezes under Edit Project -> Path -> Browse if you cancel before choosing a filename.

Software Version
ViXeN version: 1.0rc3.dev0 from master via pip

To Reproduce

  1. Start vixen in dev
  2. New project
  3. Browse to path
  4. Click cancel

Expected behavior
Filechooser should close.

Operating System (please complete the following information):
MacOS

Log file
Nothing in logs about this

Additional context
xref openjournals/joss-reviews#1501

@deniederhut
Copy link
Author

Hm. It looks like actually choosing a folder might also be freezing?

@deniederhut deniederhut changed the title Cancel button in file chooser freezes UI File chooser freezes UI Jul 19, 2019
@prabhuramachandran
Copy link
Collaborator

Thanks for the issues, I will take a look over this weekend and fix them as possible. The issue with the web-UI is that there isn't an easy way to ask for a file on the browser so I resort to using tkinter for this and that seems to be flaky.

@prabhuramachandran
Copy link
Collaborator

Hi @deniederhut -- I think I may have fixed the freezes, it was hard to reproduce but I would appreciate it if you could please try with vixen master to see if this does indeed fix the issue. Unfortunately, you will need to test with Python 3.6 for now until I get #27 fixed with a Jigna release.

@deniederhut
Copy link
Author

Looks like the file chooser still freezes for me. Is there some way to turn on more verbose logging so I have something more useful to send you?

@prabhuramachandran
Copy link
Collaborator

Would it be possible to test with the latest binary release? https://github.com/vixen-project/vixen/releases That may eliminate a build issue.

As far as logging goes, there isn't much going on to really be able to log. I still do not have any idea of how you installed vixen, what Python version are you using (what distribution), can you also try the following in a Python shell:

import tkinter
print(tkinter.TkVersion)
print(tkinter.TclVersion)

Then you can try this:

import vixen.ui_utils as UU
UU.askdirectory()

Does that also freeze?

Under the covers, this is effectively what is called when you press "browse" for a directory. Similarly for a file etc. I wish there were a way of doing this from the browser but last I checked that is not easy.

Also, you should be able to edit the textbox left of the browse button and type out a directory -- just to see if the app is working.

@deniederhut
Copy link
Author

Python 3.6.8, and I am installing from master.

Here are the tkinter versions:

>>> print(tkinter.TkVersion)
8.6
>>> print(tkinter.TclVersion)
8.6

Calling askdirectory from Python and the clicking cancel returns an empty string:

>>> import vixen.ui_utils as UU
>>> UU.askdirectory()
''"

and then the UI freezes. Calling it and choosing a directory returns the directory, raises a warning, and the UI freezes.

>>> import vixen.ui_utils as UU
>>> UU.askdirectory()
objc[1996]: Class FIFinderSyncExtensionHost is implemented in both /System/Library/PrivateFrameworks/FinderKit.framework/Versions/A/FinderKit (0x7fff9a321c90) and /System/Library/PrivateFrameworks/FileProvider.framework/OverrideBundles/FinderSyncCollaborationFileProviderOverride.bundle/Contents/MacOS/FinderSyncCollaborationFileProviderOverride (0x119e20cd8). One of the two will be used. Which one is undefined.
'/Users/dillon/test-images'

@deniederhut
Copy link
Author

The macos binary looks like it is working -- are you vendoring some dependencies inside the app?

@prabhuramachandran
Copy link
Collaborator

@deniederhut -- Thanks so much for testing this and the information. What distribution is this with? brew? or conda? Also what version of MacOS? I am still on High Sierra (10.13.6).

I am glad the binary is working, yes it vendorizes everything including Python, Tcl/Tk etc. (and fits in 25MB or less). Honestly, our expectation is for people to use the binary as we do not expect people to be Python users. In any case, your issue suggests that I should look around for a cleaner way to do this and also see how best to reproduce this issue. I see there is a tkfilebrowser but was hoping to avoid any additional dependencies.

@deniederhut
Copy link
Author

From anaconda - Python 3.6.8 :: Anaconda, Inc

Also High Sierra 10.13.6 but I really need to just bite the bullet and run the update.

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

No branches or pull requests

2 participants