File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 11from __future__ import annotations
22
3- import importlib .metadata
43import sys
4+ from importlib .metadata import PackageNotFoundError , version
55
66__version__ : str
7+
78try :
8- __version__ = importlib .metadata .version ("chia-blockchain" )
9- except importlib .metadata .PackageNotFoundError :
10- # package is not installed
9+ __version__ = version ("chia-blockchain" )
10+ except (PackageNotFoundError , KeyError ):
1111 __version__ = "unknown"
1212
1313try :
Original file line number Diff line number Diff line change @@ -25,3 +25,4 @@ filterwarnings =
2525 ignore:cannot collect test class:pytest.PytestCollectionWarning
2626 ignore:The --rsyncdir command line argument and rsyncdirs config variable are deprecated.:DeprecationWarning
2727 ignore:record_property is incompatible with junit_family:pytest.PytestWarning
28+ ignore:Implicit None on return values is deprecated and will raise
You can’t perform that action at this time.
0 commit comments