X Tutup
Skip to content

Commit 74ce964

Browse files
committed
Do not fail if bpython._version does not exist
Signed-off-by: Sebastian Ramacher <sebastian+dev@ramacher.at>
1 parent 1094abe commit 74ce964

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

bpython/__init__.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,13 @@
2121
# THE SOFTWARE.
2222

2323
import os.path
24-
import bpython._version
2524

25+
try:
26+
from bpython._version import __version__ as version
27+
except ImportError:
28+
version = 'unkown'
2629

27-
__version__ = bpython._version.__version__
30+
__version__ = version
2831
package_dir = os.path.abspath(os.path.dirname(__file__))
2932

3033

0 commit comments

Comments
 (0)
X Tutup