forked from Mirror/pmbootstrap
Cosmetic: pmb.parse.sanity_check: nicer comments (!1818)
Create one block of legacy errors, instead of having own blocks, each with their own comment stating the obvious.
This commit is contained in:
parent
a791bf4ecb
commit
5ad84a4c08
1 changed files with 1 additions and 7 deletions
|
@ -25,27 +25,21 @@ def sanity_check(info, path):
|
||||||
# Resolve path for more readable error messages
|
# Resolve path for more readable error messages
|
||||||
path = os.path.realpath(path)
|
path = os.path.realpath(path)
|
||||||
|
|
||||||
# "flash_methods" is legacy
|
# Legacy errors
|
||||||
if "flash_methods" in info:
|
if "flash_methods" in info:
|
||||||
raise RuntimeError("deviceinfo_flash_methods has been renamed to"
|
raise RuntimeError("deviceinfo_flash_methods has been renamed to"
|
||||||
" deviceinfo_flash_method. Please adjust your"
|
" deviceinfo_flash_method. Please adjust your"
|
||||||
" deviceinfo file: " + path)
|
" deviceinfo file: " + path)
|
||||||
|
|
||||||
# "external_disk*" is legacy
|
|
||||||
if "external_disk" in info or "external_disk_install" in info:
|
if "external_disk" in info or "external_disk_install" in info:
|
||||||
raise RuntimeError("Instead of deviceinfo_external_disk and"
|
raise RuntimeError("Instead of deviceinfo_external_disk and"
|
||||||
" deviceinfo_external_disk_install, please use the"
|
" deviceinfo_external_disk_install, please use the"
|
||||||
" new variable deviceinfo_external_storage in your"
|
" new variable deviceinfo_external_storage in your"
|
||||||
" deviceinfo file: " + path)
|
" deviceinfo file: " + path)
|
||||||
|
|
||||||
# "msm_refresher" is legacy
|
|
||||||
if "msm_refresher" in info:
|
if "msm_refresher" in info:
|
||||||
raise RuntimeError("It is enough to specify 'msm-fb-refresher' in the"
|
raise RuntimeError("It is enough to specify 'msm-fb-refresher' in the"
|
||||||
" depends of your device's package now. Please"
|
" depends of your device's package now. Please"
|
||||||
" delete the deviceinfo_msm_refresher line in: " +
|
" delete the deviceinfo_msm_refresher line in: " +
|
||||||
path)
|
path)
|
||||||
|
|
||||||
# "flash_fastboot_vendor_id" is legacy
|
|
||||||
if "flash_fastboot_vendor_id" in info:
|
if "flash_fastboot_vendor_id" in info:
|
||||||
raise RuntimeError("Fastboot doesn't allow specifying the vendor ID"
|
raise RuntimeError("Fastboot doesn't allow specifying the vendor ID"
|
||||||
" anymore (#1830). Try removing the"
|
" anymore (#1830). Try removing the"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue