зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1755956
- Fix python black failure. CLOSED TREE
This commit is contained in:
Родитель
c9f9939aa6
Коммит
4e4adb2951
|
@ -14,7 +14,7 @@ import pytoml
|
|||
# Try to read the package name or otherwise assume same name as the crate path.
|
||||
def _get_crate_name(crate_path):
|
||||
try:
|
||||
with open(mozpath.join(crate_path, "Cargo.toml"), encoding='utf-8') as f:
|
||||
with open(mozpath.join(crate_path, "Cargo.toml"), encoding="utf-8") as f:
|
||||
return pytoml.load(f)["package"]["name"]
|
||||
except Exception:
|
||||
return mozpath.basename(crate_path)
|
||||
|
|
Загрузка…
Ссылка в новой задаче