Giter VIP home page Giter VIP logo

aospdtgen's People

Contributors

dependabot[bot] avatar itsvixano avatar kardebayan avatar krascgq avatar sebaubuntu avatar wbs306 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aospdtgen's Issues

assert PartitionModel.SYSTEM in self.partitions

`PS C:\Users\x\Desktop> python -m aospdtgen -o C:\Users\x\Desktop\rom C:\Users\x\Desktop\images
Android device tree generator
Version 0.1.0

[INFO] Parsing all_files.txt
[INFO] Figuring out partitions scheme
Traceback (most recent call last):
File "C:\Users\x\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Users\x\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in run_code
exec(code, run_globals)
File "C:\Users\x\AppData\Local\Programs\Python\Python310\lib\site-packages\aospdtgen_main
.py", line 11, in
main()
File "C:\Users\x\AppData\Local\Programs\Python\Python310\lib\site-packages\aospdtgen\main.py", line 31, in main
dump = DeviceTree(args.dump_path)
File "C:\Users\x\AppData\Local\Programs\Python\Python310\lib\site-packages\aospdtgen\device_tree.py", line 43, in init
self.partitions = Partitions(self.path)
File "C:\Users\x\AppData\Local\Programs\Python\Python310\lib\site-packages\aospdtgen\utils\partitions.py", line 26, in init
assert PartitionModel.SYSTEM in self.partitions
AssertionError`

i try in wsl&windows,dont work.
model: realme q3
kernel-souce: https://github.com/realme-kernel-opensource/realmeQ3_Q3pro_AndroidS_kernel-source
vendor-source: https://github.com/realme-kernel-opensource/realmeQ3_Q3pro_AndroidS_vendor-source

AttributeError: 'NoneType' object has no attribute 'name [ SM-t220]

python3 -m aospdtgen output/
Android device tree generator
Version 1.0.0

[INFO] Figuring out partitions scheme
[WARNING] Unknown HAL type native
[INFO] Parsing build props and device info
[INFO] Parsing fstab
[INFO] Extracting boot image
[INFO] Cloning AIK...
Traceback (most recent call last):
File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/home/ubuntu/.local/lib/python3.8/site-packages/aospdtgen/main.py", line 11, in
main()
File "/home/ubuntu/.local/lib/python3.8/site-packages/aospdtgen/main.py", line 31, in main
dump = DeviceTree(args.dump_path)
File "/home/ubuntu/.local/lib/python3.8/site-packages/aospdtgen/device_tree.py", line 62, in init
self.boot_configuration = BootConfiguration(self.path)
File "/home/ubuntu/.local/lib/python3.8/site-packages/aospdtgen/utils/boot_configuration.py", line 26, in init
self.boot_image_info = self.boot_aik_manager.unpackimg(self.boot)
File "/home/ubuntu/.local/lib/python3.8/site-packages/sebaubuntu_libs/libaik/init.py", line 109, in unpackimg
image_prefix = image.name
AttributeError: 'NoneType' object has no attribute 'name'

getting this error. please help me

errors to obtaing the Device Tree with Xiaomi Firmwares

Android device tree generator
Version 0.1.0

Traceback (most recent call last):
File "/usr/local/lib/python3.10/runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/local/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/home/bm0x/aospdtgen/aospdtgen/main.py", line 11, in
main()
File "/home/bm0x/aospdtgen/aospdtgen/main.py", line 30, in main
dump = DeviceTree(args.dump_path)
File "/home/bm0x/aospdtgen/aospdtgen/devicetree.py", line 31, in init
self.all_files = [file for file in self.all_files_txt.open().read().splitlines()
File "/usr/local/lib/python3.10/pathlib.py", line 1117, in open
return self._accessor.open(self, mode, buffering, encoding, errors,
NotADirectoryError: [Errno 20] Not a directory: 'nabu_dpp_android_images_2.05.07.native.user.dpp_20220507.0000.00_13.0_4a3b03edc2.tgz/all_files.txt'

[pdx-223] [firmware provided] AttributeError: 'NoneType' object has no attribute 'name'

Hello. I saw this issue for other devices but the requester did not submit the requested firmware files. I will link mine.

Full firmware: https://drive.google.com/file/d/15_1OQ86wLb5t9VFdj84G67FOf0fDF3jp/view?usp=share_link
dumpyara dump: https://drive.google.com/file/d/1SvTHSng8UG5k1jwT6w6CnSSGapC5KmpD/view?usp=share_link

The script is failing for me with the following error:

[noellemercer@fedora Documents]$ python3 -m aospdtgen -o tree ./dump
Android device tree generator
Version 1.0.0

[INFO] Figuring out partitions scheme
[WARNING] Unknown HAL type native
[INFO] Parsing build props and device info
[INFO] Parsing fstab
[INFO] Extracting boot image
[INFO] Cloning AIK...
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/home/noellemercer/.local/lib/python3.11/site-packages/aospdtgen/__main__.py", line 11, in <module>
    main()
  File "/home/noellemercer/.local/lib/python3.11/site-packages/aospdtgen/main.py", line 31, in main
    dump = DeviceTree(args.dump_path)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/noellemercer/.local/lib/python3.11/site-packages/aospdtgen/device_tree.py", line 62, in __init__
    self.boot_configuration = BootConfiguration(self.path)
                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/noellemercer/.local/lib/python3.11/site-packages/aospdtgen/utils/boot_configuration.py", line 26, in __init__
    self.boot_image_info = self.boot_aik_manager.unpackimg(self.boot)
                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/noellemercer/.local/lib/python3.11/site-packages/sebaubuntu_libs/libaik/__init__.py", line 109, in unpackimg
    image_prefix = image.name
                   ^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'name'

Dumpyara log:

[noellemercer@fedora dumpyara]$ ./dumpyara.sh "XQ-CT72_Customized HK_64.1.A.0.891.zip"
GitHub token not found. Dumping just locally...
File detected. Copying...
Already up to date.
Already up to date.
Already up to date.
Already up to date.
Already up to date.
Create Temp and out dir
grep: warning: stray \ before /
Extracting firmware on: /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891
grep: warning: stray \ before /
grep: warning: stray \ before /
sin detected
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/appslog_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/bluetooth_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/bootloader_112_X-FLASH-ALL-F8AF.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/bootloader_X_BOOT_SM8450_LA2_0_T_112_X-FLASH-ALL-5E20.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/bootloader_X_BOOT_SM8450_LA2_0_T_112_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/boot_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/cdt_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/diag_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/dsp_X-FLASH-ALL-6348.ext4
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/dtbo_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/elabel-XQ-CT72-row-s20000504_20220419071931_private_X-FLASH-LTALABEL-6348.ext4
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/featenabler_X-FLASH-ALL-6348.elf
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/metadata_X-FLASH-ALL-6348.ext4
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/misc_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/modemst1_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/modemst2_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/modem_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/oem_other_X-FLASH-ALL-6348.ext4
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/oem_X-FLASH-ALL-6348.ext4
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/partition-image-LUN0_124936192_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/partition-image-LUN0_249896960_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/partition-image-LUN0_499818496_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/partition-image-LUN1_8192_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/partition-image-LUN2_8192_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/persist_X-FLASH-ALL-6348.ext4
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/rdimage_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/recovery_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/super_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/userdata_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/vbmeta_system_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/vbmeta_X-FLASH-ALL-6348.img
Extracting sparse files from SIN... Done!
Restoring image from sparse files... Done!
Successfully restored image to /home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tmp/vendor_boot_X-FLASH-ALL-6348.img
super image inside a sin detected
Creating super.img.raw ...
find: ‘/home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/bootimg’: No such file or directory
Extracting system partition
Extracting system_ext partition
Extracting vendor partition
Extracting odm partition
Extracting product partition
Extracting vendor_dlkm partition
[sudo] password for noellemercer: 
find: ‘/home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/modem’: No such file or directory
find: ‘/home/noellemercer/Documents/dumpyara/working/XQ-CT72_Customized_HK_64.1.A.0.891/tz*’: No such file or directory
system/system/build.prop
# qssi-user 13 64.1.A.0.891 1 release-keys
- manufacturer: sony
- platform: taro
- codename: pdx223
- flavor: qssi-user
- release: 13
- id: 64.1.A.0.891
- incremental: 1
- tags: release-keys
- fingerprint: Sony/pdx223/pdx223:12/SKQ1.220714.001/1:user/release-keys
- is_ab: true
- brand: Sony
- branch: qssi-user-13-64.1.A.0.891-1-release-keys
- repo: sony_pdx223_dump
Dump done locally.

Thank you.

AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'split'

Android device tree generator
Version 0.1.0

[INFO] Parsing all_files.txt
[INFO] Figuring out partitions scheme
[WARNING] Unknown HAL type native
Traceback (most recent call last):
File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/home/red/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 11, in
main()
File "/home/red/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 31, in main
dump = DeviceTree(args.dump_path)
File "/home/red/.local/lib/python3.10/site-packages/aospdtgen/device_tree.py", line 43, in init
self.partitions = Partitions(self.path)
File "/home/red/.local/lib/python3.10/site-packages/aospdtgen/utils/partitions.py", line 35, in init
self.partitions[PartitionModel.VENDOR] = AndroidPartition(PartitionModel.VENDOR, vendor, self.dump_path)
File "/home/red/.local/lib/python3.10/site-packages/aospdtgen/utils/partition.py", line 119, in init
self.manifest.import_file(manifest_path)
File "/home/red/.local/lib/python3.10/site-packages/sebaubuntu_libs/libvintf/manifest.py", line 73, in import_file
self.entries.append(AidlHal.from_entry(entry))
File "/home/red/.local/lib/python3.10/site-packages/sebaubuntu_libs/libvintf/aidl.py", line 67, in from_entry
interfaces = set([AidlInterface.from_fqname(interface)
File "/home/red/.local/lib/python3.10/site-packages/sebaubuntu_libs/libvintf/aidl.py", line 67, in
interfaces = set([AidlInterface.from_fqname(interface)
File "/home/red/.local/lib/python3.10/site-packages/sebaubuntu_libs/libvintf/aidl.py", line 40, in from_fqname
name, instance = string.split("/", 1)
AttributeError: 'xml.etree.ElementTree.Element' object has no attribute 'split'

Handling symbolic links as a file?

Android device tree generator
Version 0.1.0

[INFO] Figuring out partitions scheme
Traceback (most recent call last):
  File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/home/someone5678/android/dump/aospdtgen/aospdtgen/__main__.py", line 11, in <module>
    main()
  File "/home/someone5678/android/dump/aospdtgen/aospdtgen/main.py", line 31, in main
    dump = DeviceTree(args.dump_path)
  File "/home/someone5678/android/dump/aospdtgen/aospdtgen/device_tree.py", line 36, in __init__
    self.partitions = Partitions(self.path)
  File "/home/someone5678/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partitions.py", line 25, in __init__
    self.partitions[PartitionModel.SYSTEM] = AndroidPartition(PartitionModel.SYSTEM, system)
  File "/home/someone5678/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 38, in __init__
    self.files = get_files_list(self.path)
  File "/home/someone5678/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 29, in get_files_list
    files.extend(get_files_list(i))
  File "/home/someone5678/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 29, in get_files_list
    files.extend(get_files_list(i))
  File "/home/someone5678/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 25, in get_files_list
    for i in path.iterdir():
  File "/usr/lib/python3.10/pathlib.py", line 1017, in iterdir
    for name in self._accessor.listdir(self):
FileNotFoundError: [Errno 2] No such file or directory: '../dumpyara/working/miui_MONDRIAN_V14.0.23.2.13.DEV_16aad31db7_13.0/system/system/lib/libc.so'

As I found, currently, aospdtgen following all symbolic links instead of just handling it as a file.
To workaround for above issue I should delete all symlink files by running command
find . -type l -delete .
After that I can finally generate dt.

What could be some sort of default config.fs that we can come up with?

Hi There,

I have used this tool to generate device tree and building lineageos 18.0

Its done till 70% and had 3 errors until now. Fixed them. Currently stuck at not having default config.fs which declares the users like this
https://github.com/LineageOS/android_device_sony_tama-common/blob/lineage-19.1/config.fs

I have found my device's /etc/passwd file non empty so I can create those users as I found from that file. But having this auto generated is a really good step that we can automate is what I felt.

Let me know about your views on this. If I am able to successfully build lineageos and use it then I will create a documentation/video series explaining how to build lineageos for a device with aospdtgen given they have dump from dumpyara

In case either you or someone have already created such documenation/video series explaining how to build androidos using this(aospdtgen) and dumpyara, please link me to it. I can add the errors I face in case they are not covered in that documentation.

Error installing sebaubuntu-libs

$ pip install sebaubuntu-libs

ERROR: Ignored the following versions that require a different python version: 1.0.0 Requires-Python >=3.9,<4.0; 1.0.1 Requires-Python >=3.9,<4.0; 1.0.2 Requires-Python >=3.9,<4.0; 1.0.3 Requires-Python >=3.9,<4.0; 1.0.4 Requires-Python >=3.9,<4.0; 1.0.5 Requires-Python >=3.9,<4.0; 1.0.6 Requires-Python >=3.9,<4.0
ERROR: Could not find a version that satisfies the requirement sebaubuntu-libs (from versions: none)
ERROR: No matching distribution found for sebaubuntu-libs

TypeError: 'type' object is not subscriptable

Enviroment:
WSL2 // ubuntu 20.

Install is ok:
edward@NRT39609:~/aospdtgen$ pip3 install .
Processing /home/edward/aospdtgen
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... done
Requirement already satisfied: pyelftools<0.28,>=0.27 in /home/edward/.local/lib/python3.8/site-packages (from aospdtgen==0.1.0) (0.27)
Requirement already satisfied: Jinja2<4.0.0,>=3.0.3 in /home/edward/.local/lib/python3.8/site-packages (from aospdtgen==0.1.0) (3.0.3)
Requirement already satisfied: MarkupSafe>=2.0 in /home/edward/.local/lib/python3.8/site-packages (from Jinja2<4.0.0,>=3.0.3->aospdtgen==0.1.0) (2.1.1)
Building wheels for collected packages: aospdtgen
Building wheel for aospdtgen (PEP 517) ... done
Created wheel for aospdtgen: filename=aospdtgen-0.1.0-py3-none-any.whl size=63209 sha256=b7467f9c84edabf8f3ab60dcde141b2d7d50df11761d525a45aaef231183b267
Stored in directory: /tmp/pip-ephem-wheel-cache-ypbae0o2/wheels/21/ab/33/92962f9c14ee6bb9ea800fe79cd54d505f94dac906c038ec16
Successfully built aospdtgen
Installing collected packages: aospdtgen
Attempting uninstall: aospdtgen
Found existing installation: aospdtgen 0.1.0
Uninstalling aospdtgen-0.1.0:
Successfully uninstalled aospdtgen-0.1.0
Successfully installed aospdtgen-0.1.0

Running the generator fails.

edward@NRT39609:~/aospdtgen$ python3 -m aospdtgen -h
Traceback (most recent call last):
File "/usr/lib/python3.8/runpy.py", line 185, in _run_module_as_main
mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
File "/usr/lib/python3.8/runpy.py", line 144, in _get_module_details
return _get_module_details(pkg_main_name, error)
File "/usr/lib/python3.8/runpy.py", line 111, in _get_module_details
import(pkg_name)
File "/home/edward/aospdtgen/aospdtgen/init.py", line 7, in
from aospdtgen.proprietary_files.section import register_sections
File "/home/edward/aospdtgen/aospdtgen/proprietary_files/section.py", line 3, in
from aospdtgen.proprietary_files.elf import get_needed_shared_libs, get_shared_libs
File "/home/edward/aospdtgen/aospdtgen/proprietary_files/elf.py", line 18, in
def get_shared_libs(files: list[Path]):
TypeError: 'type' object is not subscriptable

AttributeError: 'NoneType' object has no attribute 'name' [Sony stock firmware (pdx-201)]

Android device tree generator
Version 0.1.0

[INFO] Figuring out partitions scheme
[WARNING] Unknown HAL type native
[INFO] Parsing build props and device info
[INFO] Parsing fstab
[INFO] Extracting boot image
[INFO] Cloning AIK...
Traceback (most recent call last):
File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/home/erik/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 11, in
main()
File "/home/erik/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 31, in main
dump = DeviceTree(args.dump_path)
File "/home/erik/.local/lib/python3.10/site-packages/aospdtgen/device_tree.py", line 62, in init
self.boot_configuration = BootConfiguration(self.path)
File "/home/erik/.local/lib/python3.10/site-packages/aospdtgen/utils/boot_configuration.py", line 26, in init
self.boot_image_info = self.boot_aik_manager.unpackimg(self.boot)
File "/home/erik/.local/lib/python3.10/site-packages/sebaubuntu_libs/libaik/init.py", line 109, in unpackimg
image_prefix = image.name

I tried using aospdtgen to generate a device tree for Huawei P10 but error

Hello,
I tried using aospdtgen to generate a device tree for Huawei P10
The firmware of the phone is EMUI 9 (Android 9)
But an error occurred:

Android device tree generator
Version 1.0.1

[INFO] Figuring out partitions scheme
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type None
[WARNING] Unknown HAL type native
[WARNING] Unknown HAL type native
[INFO] Parsing build props and device info
[INFO] Parsing fstab
[INFO] Extracting boot image
Traceback (most recent call last):
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/home/coconutat/.local/lib/python3.8/site-packages/aospdtgen/__main__.py", line 11, in <module>
    main()
  File "/home/coconutat/.local/lib/python3.8/site-packages/aospdtgen/main.py", line 31, in main
    dump = DeviceTree(args.dump_path)
  File "/home/coconutat/.local/lib/python3.8/site-packages/aospdtgen/device_tree.py", line 62, in __init__
    self.boot_configuration = BootConfiguration(self.path)
  File "/home/coconutat/.local/lib/python3.8/site-packages/aospdtgen/utils/boot_configuration.py", line 25, in __init__
    assert self.boot, "No boot image found"
AssertionError: No boot image found

I know it's because the firmware of Huawei EMUI 9 does not include boot.img. Because Huawei's firmware is deeply customized.
According to some accounts, Huawei's boot.img section is included in the system. img. Additionally, Huawei's kernel partitions are independent.
If necessary, I can upload my img and dumpyara unpacking files,
Additionally:
How to use dumpyara to unpack Huawei's special format. First use Huawei's .APP unpacking tool unpack the .APP files , then use simg2img converts all img files and compresses them into zip. Now we can use dumpyara to unpack it.

AssertionError when Running aospdtgen on MIUI Dump

Operating System: Ubuntu 23.04
Python Version: 3.10
aospdtgen Version: 1.1.1

I encountered an AssertionError when attempting to generate an Android device tree using aospdtgen with a MIUI dump from the ZIYIGlobal variant. This error occurs during the initial phase where the tool tries to figure out the partition scheme.

Version 1.1.1

[INFO] Figuring out partitions scheme
Traceback (most recent call last):
...
File "/home/ruslan/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partitions.py", line 27, in __init__
    assert PartitionModel.SYSTEM in self.partitions
AssertionError

I would appreciate any guidance on resolving this issue or any workarounds available. Thank you!

PS: Firmware OTA file here

xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 1, column 2

Android device tree generator
Version 1.0.0

[INFO] Figuring out partitions scheme
[WARNING] Unknown HAL type native
Traceback (most recent call last):
  File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/home/build/.local/lib/python3.10/site-packages/aospdtgen/__main__.py", line 11, in <module>
    main()
  File "/home/build/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 31, in main
    dump = DeviceTree(args.dump_path)
  File "/home/build/.local/lib/python3.10/site-packages/aospdtgen/device_tree.py", line 36, in __init__
    self.partitions = Partitions(self.path)
  File "/home/build/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partitions.py", line 36, in __init__
    self.partitions[PartitionModel.VENDOR] = AndroidPartition(PartitionModel.VENDOR, vendor)
  File "/home/build/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 56, in __init__
    self.manifest.import_file(manifest_path)
  File "/home/build/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/vintf/manifest.py", line 57, in import_file
    tree = ElementTree.parse(file)
  File "/usr/lib/python3.10/xml/etree/ElementTree.py", line 1222, in parse
    tree.parse(source, parser)
  File "/usr/lib/python3.10/xml/etree/ElementTree.py", line 580, in parse
    self._root = parser._parse_whole(source)
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 1, column 2

Firmware here if nedded

There are some data after the end of the payload data

beforespace@beforespace-desktop:~$ python3 -m dumpyara '/media/beforespace/HDD/androidhacking/k40s/miui_MUNCH_V14.0.9.0.TLMCNXM_596329468b_13.0.zip'
Dumpyara
Version 1.0.5

[INFO] Step 1 - Extracting archive
[INFO] Pattern ..tar.md5 not found
[INFO] Step 2 - Preparing partition images
[INFO] Found multipartition image: payload.bin
Extracting 'abl.img'
Extracting 'aop.img'
Extracting 'bluetooth.img'
Extracting 'boot.img'
Extracting 'cmnlib.img'
Extracting 'cmnlib64.img'
Extracting 'devcfg.img'
Extracting 'dsp.img'
Extracting 'dtbo.img'
Extracting 'featenabler.img'
Extracting 'hyp.img'
Extracting 'imagefv.img'
Extracting 'keymaster.img'
Extracting 'modem.img'
Extracting 'odm.img'
Extracting 'product.img'
Extracting 'qupfw.img'
Extracting 'system.img'
Extracting 'system_ext.img'
Extracting 'tz.img'
Extracting 'uefisecapp.img'
Extracting 'vbmeta.img'
Extracting 'vbmeta_system.img'
Extracting 'vendor.img'
Extracting 'vendor_boot.img'
Extracting 'xbl.img'
Extracting 'xbl_config.img'
Extracting 'mi_ext.img'
[INFO] Pattern super(?!.
(_empty)).*.img not found
[INFO] Step 3 - Extracting partitions
[INFO] Extracting boot
[INFO] Cloning AIK...
[INFO] Extracting dtbo
[INFO] Extracting vendor_boot
[INFO] Cloning AIK...
[INFO] Extracting tz
[INFO] Extracting odm
[INFO] Extracting product
[INFO] Extracting system
[INFO] Extracting system_ext
[INFO] Extracting vendor
[INFO] Extracting modem
[ERROR] Error extracting modem.img
[ERROR]
7-Zip [64] 16.02 : Copyright (c) 1999-2016 Igor Pavlov : 2016-05-21
p7zip Version 16.02 (locale=zh_CN.UTF-8,Utf16=on,HugeFiles=on,64 bits,36 CPUs Intel(R) Xeon(R) CPU E5-2699 v3 @ 2.30GHz (306F2),ASM,AES-NI)

Scanning the drive for archives:
1 file, 282112000 bytes (270 MiB)

Extracting archive: /home/beforespace/miui_MUNCH_V14.0.9.0.TLMCNXM_596329468b_13.0/temp_raw_images/modem.img

ERRORS:
Unexpected end of archive

--
Path = /home/beforespace/miui_MUNCH_V14.0.9.0.TLMCNXM_596329468b_13.0/temp_raw_images/modem.img
Type = FAT
ERRORS:
Unexpected end of archive
Physical Size = 469762048
File System = FAT16
Cluster Size = 16384
Free Space = 187645952
Headers Size = 8843264
Sector Size = 4096
ID = 12345678

ERROR: Data Error : image/modem_pr/mcfg/configs/mcfg_hw/oem_hw_null.txt
ERROR: Data Error : image/modem_pr/mcfg/configs/mcfg_sw/oem_sw_null.txt

Sub items Errors: 2

Archives with Errors: 1

Open Errors: 1

Sub items Errors: 2

[INFO] Step 4 - Finalizing
[INFO] Creating all_files.txt

Done! You can find the dump in /home/beforespace/miui_MUNCH_V14.0.9.0.TLMCNXM_596329468b_13.0

Issues with OnePlusN10 dump

This device does not seem to contain a value you look for in build.prop
AssertionError: Property ro.product.bootimage.model could not be found in build.prop

I added this manually and it continues, however it would be nice if this was not necessary.
this is the dump:
https://dumps.tadiphone.dev/dumps/oneplus/oneplusn10/

After adding that, I do get a device tree generated, however I also get these warnings:

[2022-05-12 20:56:32,780] [manifest.py:76 WARNING] import_file: Unknown HAL type native
[2022-05-12 20:56:33,972] [__init__.py:104 INFO] __init__: Cloning AIK...
[2022-05-12 20:56:37,883] [__init__.py:104 INFO] __init__: Cloning AIK...

Hopefully this helps!

FileNotFoundError: [Errno 2] No such file or directory

Android device tree generator
Version 1.0.0

[INFO] Figuring out partitions scheme
Traceback (most recent call last):
File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/home/aos/AndroidTools/aospdtgen/aospdtgen/main.py", line 11, in
main()
File "/home/aos/AndroidTools/aospdtgen/aospdtgen/main.py", line 31, in main
dump = DeviceTree(args.dump_path)
File "/home/aos/AndroidTools/aospdtgen/aospdtgen/device_tree.py", line 36, in init
self.partitions = Partitions(self.path)
File "/usr/local/lib/python3.10/dist-packages/sebaubuntu_libs/libandroid/partitions/partitions.py", line 25, in init
self.partitions[PartitionModel.SYSTEM] = AndroidPartition(PartitionModel.SYSTEM, system)
File "/usr/local/lib/python3.10/dist-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 38, in init
self.files = get_files_list(self.path)
File "/usr/local/lib/python3.10/dist-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 29, in get_files_list
files.extend(get_files_list(i))
File "/usr/local/lib/python3.10/dist-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 29, in get_files_list
files.extend(get_files_list(i))
File "/usr/local/lib/python3.10/dist-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 29, in get_files_list
files.extend(get_files_list(i))
[Previous line repeated 2 more times]
File "/usr/local/lib/python3.10/dist-packages/sebaubuntu_libs/libandroid/partitions/partition.py", line 25, in get_files_list
for i in path.iterdir():
File "/usr/lib/python3.10/pathlib.py", line 1017, in iterdir
for name in self._accessor.listdir(self):
FileNotFoundError: [Errno 2] No such file or directory: '/home/aos/AndroidTools/DumprX/out/system/system/priv-app/BuiltInPrintService/lib/arm64/libwfds.so'

ROM: lisa_global_images_V14.0.3.0.TKOMIXM_20230324.0000.00_13.0_global_b96438c491.tgz

Im using it for devicecodename "marble"

Yeah it's my 1st time so don't know im doing in right way or not, so pls tell. After command im getting this error: sharmagrit@SharmagRit:~/aospdtgen$ python3 -m aospdtgen /home/sharmagrit/miui_MARBLE_V14.0.19.0.TMRCNXM_cdffc8d82e_13.0/
Android device tree generator
Version 1.0.0

[INFO] Figuring out partitions scheme
Traceback (most recent call last):
File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/home/sharmagrit/aospdtgen/aospdtgen/main.py", line 11, in
main()
File "/home/sharmagrit/aospdtgen/aospdtgen/main.py", line 31, in main
dump = DeviceTree(args.dump_path)
File "/home/sharmagrit/aospdtgen/aospdtgen/device_tree.py", line 36, in init
self.partitions = Partitions(self.path)
File "/home/sharmagrit/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partitions.py", line 27, in init
assert PartitionModel.SYSTEM in self.partitions
AssertionError

AttributeError: 'NoneType' object has no attribute 'name' (pdx203)

Getting this error when generating from dumped dynamic partitions (hence I also don't know if I need to put something else there)

Version 1.0.0

[INFO] Figuring out partitions scheme
[WARNING] Unknown HAL type native
[INFO] Parsing build props and device info
[INFO] Parsing fstab
[INFO] Extracting boot image
[INFO] Cloning AIK...
Traceback (most recent call last):
  File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/home/ryliea/.local/lib/python3.10/site-packages/aospdtgen/__main__.py", line 11, in <module>
    main()
  File "/home/ryliea/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 31, in main
    dump = DeviceTree(args.dump_path)
  File "/home/ryliea/.local/lib/python3.10/site-packages/aospdtgen/device_tree.py", line 62, in __init__
    self.boot_configuration = BootConfiguration(self.path)
  File "/home/ryliea/.local/lib/python3.10/site-packages/aospdtgen/utils/boot_configuration.py", line 26, in __init__
    self.boot_image_info = self.boot_aik_manager.unpackimg(self.boot)
  File "/home/ryliea/.local/lib/python3.10/site-packages/sebaubuntu_libs/libaik/__init__.py", line 109, in unpackimg
    image_prefix = image.name
AttributeError: 'NoneType' object has no attribute 'name'

Original firmware : 58.2.C.5.2
Extracted Super.img : super_x-FLASH-ALL-2389.img
Dumped Super.tar : super_dumped.tar
Boot image : Boot.img ( I don't know what procedure I have to make with it nor where to put it in working directory )

How to make a device tree that has a common tree?

I used your tool to make my device tree from a ROM, but it didn't include the common files from another repository. How do I use this tool to make a device tree that incorporates a common tree?

build/make/core/base_rules.mk:324: error: system/core/rootdir: MODULE.TARGET.ETC.init.rc already defined by device/samsung/m21/rootdir.

Extracting process is suddenly being killed

Hi, There!

I'm so impressed with all your works and here I'm tryna use this tool the create a skeleton dt for my device. But the problem is I got this error while tryna execute this script

$ python3 -m dumpyara -o ~/dt/rom ~/dt/rom/miui_MI8SE_V12.5.1.0.QEBCNXM_d9815dfb66_10.0.zip
Dumpyara
Version 1.0.0

[INFO] Step 1 - Extracting archive
[INFO] Step 2 - Preparing partition images
[INFO] Copying boot.img
[INFO] Copying dtbo.img
[INFO] Copying tz.mbn
[INFO] Decompressing system.new.dat.br
Killed

Any ideas? Thanks a million.

Info:
Python version: 3.9.13
Device: MI 8 SE a.k.a Sirius
OS: Ubuntu 18.04.6 LTS

assert PartitionModel.SYSTEM in self.partitions AssertionError

aospdtgen$ python3 -m aospdtgen '/home/ninja/Desktop/working'
Android device tree generator
Version 0.1.0

[INFO] Figuring out partitions scheme
Traceback (most recent call last):
File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/home/ninja/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 11, in
main()
File "/home/ninja/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 31, in main
dump = DeviceTree(args.dump_path)
File "/home/ninja/.local/lib/python3.10/site-packages/aospdtgen/device_tree.py", line 36, in init
self.partitions = Partitions(self.path)
File "/usr/local/lib/python3.10/dist-packages/sebaubuntu_libs/libandroid/partitions/partitions.py", line 27, in init
assert PartitionModel.SYSTEM in self.partitions
AssertionError

Will it be able to replace gsi roms in the future?

Error on building on5xelte device tree

root@fv-az90-984:/home/diwas/on5xelte# python3 -m aospdtgen /home/diwas/on5xelte
Android device tree generator
Version 0.1.0
[INFO] Parsing all_files.txt [INFO] Figuring out partitions scheme Traceback (most recent call last): File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
return _run_code(code, main_globals, None, File "/usr/lib/python3.8/runpy.py", line 87, in _run_code exec(code, run_globals) File "/usr/local/lib/python3.8/dist-packages/aospdtgen/main.py", line 11, in main() File "/usr/local/lib/python3.8/dist-packages/aospdtgen/main.py", line 31, in main dump = DeviceTree(args.dump_path) File "/usr/local/lib/python3.8/dist-packages/aospdtgen/device_tree.py", line 43, in init self.partitions = Partitions(self.path) File "/usr/local/lib/python3.8/dist-packages/aospdtgen/utils/partitions.py", line 37, in init
assert PartitionModel.VENDOR in self.partitions
AssertionError

Failure during generating X6C6F device tree

Dump link: https://dumps.tadiphone.dev/dumps/lenovo/x6c6f

Git commit: 14cb0d6

[amy@daisy rom]$ python3 -m aospdtgen /home/amy/Downloads/x6c6f-full_P98928JA1-user-11-RP1A.200720.011-tb8766p164bspP3-release-keys/
Android device tree generator
Version 0.1.0

[2022-05-31 21:07:44,381] [manifest.py:76 WARNING] import_file: Unknown HAL type native
[2022-05-31 21:07:44,513] [__init__.py:104 INFO] __init__: Cloning AIK...
Traceback (most recent call last):
  File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/home/amy/.local/lib/python3.10/site-packages/aospdtgen/__main__.py", line 11, in <module>
    main()
  File "/home/amy/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 31, in main
    dump.dump_to_folder(args.output)
  File "/home/amy/.local/lib/python3.10/site-packages/aospdtgen/devicetree.py", line 123, in dump_to_folder
    (folder / f"{partition.model.name}.prop").write_text(partition.build_prop.get_readable_list(IGNORED_PROPS))
  File "/usr/lib/python3.10/pathlib.py", line 1153, in write_text
    return f.write(data)
UnicodeEncodeError: 'ascii' codec can't encode character '\xae' in position 758: ordinal not in range(128)
[amy@daisy rom]$

Lack dash sign for some proprietary files

Some proprietary files like apk, vintf, etc. file need the dash sign in proprietary-files.txt to build. But I don't know how to modify the source code to do this thing. Can we add this sign when doing section.get_files()?

[V1.0.1] Fails to build tree from recovery .img same as #50

same as #50
Android device tree generator
Version 1.0.1

[INFO] Figuring out partitions scheme
Traceback (most recent call last):
File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/home/kartik/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 11, in
main()
File "/home/kartik/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 31, in main
dump = DeviceTree(args.dump_path)
File "/home/kartik/.local/lib/python3.10/site-packages/aospdtgen/device_tree.py", line 36, in init
self.partitions = Partitions(self.path)
File "/home/kartik/.local/lib/python3.10/site-packages/sebaubuntu_libs/libandroid/partitions/partitions.py", line 27, in init
assert PartitionModel.SYSTEM in self.partitions
AssertionError

UnicodeDecodeError when calling unpackimg()

I met this error when it was unpacking the boot.img, only if I set LC_ALL=C before execute this command or comment the code setup_locale() it works. Is there any better solutions? I think the locale change in somewhere when executing the script. My default locale is zh_CN.UTF-8, running on Archlinux, Python 3.10

$ python -m aospdtgen /home/wbs/android/dumpyara/working/out 


Android device tree generator

Version 0.1.0

[2022-06-12 12:17:11,938] [manifest.py:76 WARNING] import_file: Unknown HAL type native
[2022-06-12 12:17:12,398] [__init__.py:104 INFO] __init__: Cloning AIK...
Traceback (most recent call last):
  File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/home/wbs/.local/lib/python3.10/site-packages/aospdtgen/__main__.py", line 11, in <module>
    main()
  File "/home/wbs/.local/lib/python3.10/site-packages/aospdtgen/main.py", line 30, in main
    dump = DeviceTree(args.dump_path)
  File "/home/wbs/.local/lib/python3.10/site-packages/aospdtgen/devicetree.py", line 75, in __init__
    self.boot_configuration = BootConfiguration(self.path / "boot.img",
  File "/home/wbs/.local/lib/python3.10/site-packages/aospdtgen/utils/boot_configuration.py", line 28, in __init__
    self.boot_image_info = self.boot_aik_manager.unpackimg(self.boot)
  File "/home/wbs/.local/lib/python3.10/site-packages/sebaubuntu_libs/libaik/__init__.py", line 112, in unpackimg
    process = self._execute_script("unpackimg.sh", image)
  File "/home/wbs/.local/lib/python3.10/site-packages/sebaubuntu_libs/libaik/__init__.py", line 193, in _execute_script
    return check_output(command, stderr=STDOUT, universal_newlines=True)
  File "/usr/lib/python3.10/subprocess.py", line 420, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "/usr/lib/python3.10/subprocess.py", line 503, in run
    stdout, stderr = process.communicate(input, timeout=timeout)
  File "/usr/lib/python3.10/subprocess.py", line 1139, in communicate
    stdout = self.stdout.read()
  File "/usr/lib/python3.10/encodings/ascii.py", line 26, in decode
    return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe5 in position 562: ordinal not in range(128)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.