Lisitrx
Lisitrx

Reputation: 41

Conflict pyinstaller vs pathlib --> removing pathlib causes deletion of anaconda navigator

I get the following error message when using the pyinstaller to convert python file to .exe:

The 'pathlib' package is an obsolete backport of a standard library package and is incompatible with PyInstaller. Please remove this package using conda remove then try again.

My python version is currently 3.10.9 Pyinstaller version 5.11.0

When I follow the advice to remove pathlib, pyinstaller works perfectly but my anaconda navigator gets deleted. I always have to re-install it, but then again pyinstaller is not working, because pathlib gets newly installed. Does someone faces the same issue and has a solution?

Edit: I don't need the anaconda navigator for the pyinstaller application itself, but would like to keep the navigator since I use it to open programs like VS Code, Jupyter etc and its not very convenient that it gets deleted just because of the conflict between pathlib and pyinstaller.

Upvotes: 1

Views: 2465

Answers (1)

Lisitrx
Lisitrx

Reputation: 41

I found a solution to this problem: Instead of using conda remove pathlib, I manually deleted the folder for the pathlib package in the anaconda3/Lib/site-packages folder. Doing this, anaconda navigator is not deleted, just the not needed old version of pathlib and pyinstaller works normally.

Upvotes: 2

Related Questions