konsave icon indicating copy to clipboard operation
konsave copied to clipboard

[Bug] Everything has a Python warning

Open 103sbavert opened this issue 6 months ago • 7 comments

Describe the bug Every page or command has a Python deprecation warning from /usr/lib/python3.13/site-packages/konsave/__init__.py:3

Warning text:

/usr/lib/python3.13/site-packages/konsave/__init__.py:3: UserWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html. The pkg_resources package is slated for removal as early as 2025-11-30. Refrain from using this package or pin to Setuptools<81.
  from pkg_resources import get_distribution, DistributionNotFound

To reproduce

  1. Install Konsave
  2. Type konsave or any other feature/command

Expected behavior Only the content relevant to the feature appears without any deprecation warnings from Python

Screenshots Image

System information

  • Arch Linux
  • (Chaotic) AUR and pacman/yay
  • Konsave 2.2.0

103sbavert avatar Jun 04 '25 20:06 103sbavert

Hello, I added a pull request with a fix, so the changes are waiting to be approved. I don't know if the maintainer is still active. If not, you can take a look at my fork and try to copy this to your installed konsave scripts init.py and main.py Probably located in ~/.local/share/pipx/venvs/konsave/lib/python3.12/site-packages/konsave/ if you installed it via pipx

michal-gora avatar Jun 19 '25 16:06 michal-gora

I wasn't aware that this project is stale, I assumed it was under because KDE is big. I installed it using Pacman btw

103sbavert avatar Jun 19 '25 19:06 103sbavert

I hope he's just really busy and can work on this from time to time. Konsave is an amazing project and a game changer.

LaubeQ avatar Jun 20 '25 15:06 LaubeQ

I will try to contribute to your fork if I can and get time besides work

103sbavert avatar Jun 21 '25 19:06 103sbavert

Hi everyone, sorry this project has been quiet. I’ve been busy with college and other commitments. I’ll review the major issues tonight and fix them ASAP. Thanks for using Konsave <3

Prayag2 avatar Jun 23 '25 09:06 Prayag2

Hello Prayag2, thank you for the wonderful program. It's a wonder KDE doesn't include this functionality, but you have allowed me to rice away and when I goof up restore back to "known good". Thank you. Whenever you can get to this it will be appreciated, though after reading https://setuptools.pypa.io/en/latest/pkg_resources.html seems like it'll be more than a small change. I'm sorry I can't help.

Thank you again for your time, konsave is a must have for anyone with KDE and there's a lot of us out here hoping it is around a long, long time.

jbeckman1974 avatar Aug 10 '25 02:08 jbeckman1974

Hello, I added a pull request with a fix, so the changes are waiting to be approved. I don't know if the maintainer is still active. If not, you can take a look at my fork and try to copy this to your installed konsave scripts init.py and main.py Probably located in ~/.local/share/pipx/venvs/konsave/lib/python3.12/site-packages/konsave/ if you installed it via pipx

Thank you! Your fix worked for me. Not tested expensively, but a quick save and restore works. I guess the maintainer is super busy so not sure if he'll have time to look at the PR. In the meantime, for anyone who want to test @michal-gora's version without editing files:

pipx uninstall konsave 
pipx install git+https://github.com/michal-gora/konsave.git@pkg_resources_warning_fix

The uninstall won't remove any saved profiles. Just the original app itself.

eskay993 avatar Nov 10 '25 15:11 eskay993