mirror of
https://github.com/frappe/bench.git
synced 2025-01-10 00:37:51 +00:00
fix: version check backward compatibility (#1409)
This code wasn't triggering because VersionNotFound exception gets thrown before it ever reaches to this point.
This commit is contained in:
parent
ba853c943b
commit
23eede5fd3
@ -284,7 +284,7 @@ def get_current_version(app, bench_path="."):
|
|||||||
with open(init_path) as f:
|
with open(init_path) as f:
|
||||||
current_version = get_version_from_string(f.read())
|
current_version = get_version_from_string(f.read())
|
||||||
|
|
||||||
except AttributeError:
|
except (AttributeError, VersionNotFound):
|
||||||
# backward compatibility
|
# backward compatibility
|
||||||
with open(setup_path) as f:
|
with open(setup_path) as f:
|
||||||
current_version = get_version_from_string(f.read(), field="version")
|
current_version = get_version_from_string(f.read(), field="version")
|
||||||
|
Loading…
Reference in New Issue
Block a user