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

FileChooser raises NotImplementedError/ModuleNotFoundError without pywin32 on windows 10 #735

Open
nWestie opened this issue Jan 12, 2023 · 2 comments
Assignees

Comments

@nWestie
Copy link

nWestie commented Jan 12, 2023

When using plyer FileChooser without kivy, it raises an error when it cannot find the win32 module. After installing pywin32, it works fine. Could pywin32 be added as a dependancy of plyer, to reduce confusion? Kivy installs it automatically on windows.
See also: #602
the full error/traceback:

Traceback (most recent call last):
File "C:\Users<USER>\scripts.venv\lib\site-packages\plyer\utils.py", line 96, in _ensure_obj
mod = import(module, fromlist='.')
from win32com.shell.shell import (
ModuleNotFoundError: No module named 'win32com'
Traceback (most recent call last):
File "c:\Users<USER>\Scripts\linecounter.py", line 3, in
fileName = filechooser.open_file(
return self._file_selection_dialog(mode="open", *args, **kwargs)
File "C:\Users<USER>\scripts.venv\lib\site-packages\plyer\facades\filechooser.py", line 74, in _file_selection_dialog
raise NotImplementedError()
NotImplementedError

I am on windows 10, with python 3.10

@misl6
Copy link
Member

misl6 commented Jan 14, 2023

Hi @nWestie

Could pywin32 be added as a dependancy of plyer, to reduce confusion? Kivy installs it automatically on windows.

Yes, do you want to take care of the PR and testing? (I do not have a Windows setup available ATM)

@nWestie
Copy link
Author

nWestie commented Jan 14, 2023

sure, I think I can figure out how to do that, I'll give it a shot this week sometime

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

No branches or pull requests

2 participants