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

[Windows] ModuleNotFoundError: No module named 'pkg_resources' #101

Closed
robinhood2014 opened this issue Nov 9, 2023 · 5 comments
Closed
Milestone

Comments

@robinhood2014
Copy link

Describe the bug
On Windows, when I run radio, I get the following error output:

Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "C:\Users\donni\AppData\Local\Programs\Python\Python312\Scripts\radio.exe\__main__.py", line 4, in <module>
  File "C:\Users\donni\AppData\Local\Programs\Python\Python312\Lib\site-packages\radioactive\__main__.py", line 11, in <module>
    from radioactive.handler import Handler
  File "C:\Users\donni\AppData\Local\Programs\Python\Python312\Lib\site-packages\radioactive\handler.py", line 10, in <module>
    from pyradios import RadioBrowser
  File "C:\Users\donni\AppData\Local\Programs\Python\Python312\Lib\site-packages\pyradios\__init__.py", line 3, in <module>
    from pyradios.radios import RadioBrowser
  File "C:\Users\donni\AppData\Local\Programs\Python\Python312\Lib\site-packages\pyradios\radios.py", line 6, in <module>
    import pkg_resources
ModuleNotFoundError: No module named 'pkg_resources'

To Reproduce
Steps to reproduce the behavior:

  1. Open Windows PowerShell or PowerShell 7.
  2. Type radio with any or no parameters.
  3. See error

Expected behavior
E.g. when running radio with no parameters, I expected a welcome message as described by Derek Taylor a.k.a. "DistroTube" at 5:25 of his video covering this app. Below this, I expected the program to print a message in red letters saying, "No station to play. please [sic] search for a station first!"

Screenshots
I've enclosed two screenshots illustrating the different scenarios. The first screenshot is the result of the native Windows version; I obtained the second from running the same command in a Windows Subsystem for Linux (WSL) environment.
Screenshot 2023-11-08 212557
Screenshot 2023-11-08 212415

Desktop

  • OS: Windows 11
  • Browser: Microsoft Edge
  • Version: 119

Additional context
It's possible that this might not be a bug at all, but instead a result of me being a bonehead and forgetting to install a dependency for the native Windows version. Whatever the case may be, please let me know what's up.

Copy link

github-actions bot commented Nov 9, 2023

Hi, @robinhood2014,
Thanks for your contribution 💙 .
Contributors 🧑‍🤝‍🧑 like you make the open source community 🌍 such an amazing place to learn 📖 , inspire 👼, and create 🎨 .
We will investigate 👀 and get back to you as soon as possible 👍 . Just make sure you have given us sufficient information ℹ️.

By that time enjoy this meme 👇 , hope you like it 😄

meme

Use this action on your projects. Use jokes on issues instead.

@WyntrHeart
Copy link

Same issue on Android 9 using Termux

@WyntrHeart
Copy link

Fixed this by installing "setuptools" which provides the module "pkg_resources". Since pip doesn't install this package automatically it should be listed as a dependency for radio-active

@robinhood2014
Copy link
Author

@WyntrHeart Confirmed fixed on Windows. I'm not sure why Python pulls in the "pkg_resources" module by default on desktop Linux but not on any other platform.

@deep5050
Copy link
Owner

Thank you for the bug working..

@deep5050 deep5050 added this to the 2.10.0 milestone Nov 13, 2023
@deep5050 deep5050 pinned this issue Nov 13, 2023
@deep5050 deep5050 closed this as completed Jan 9, 2024
@deep5050 deep5050 unpinned this issue Jan 16, 2024
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

3 participants