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

Add pbr fallback #1964

Merged
merged 1 commit into from
Nov 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion guake/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,12 @@ def guake_version():
try:
import importlib.metadata as importlib_metadata
except ImportError:
import importlib_metadata
try:
import importlib_metadata
except ImportError:
import pbr.version # Fallback for python < 3.8 unable to install importlib_metadata

return pbr.version.VersionInfo("guake").version_string()

return importlib_metadata.version("guake")

Expand Down
7 changes: 7 additions & 0 deletions releasenotes/notes/fix_importlib-3da97c56e3fadc21.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
release_summary: >
Add fallback for version number finding


fixes:
- |
- Guake suddenly not starting any more due to ModuleNotFoundError: No module named 'importlib_metadata' #1962