Age | Commit message (Collapse) | Author |
|
It is no longer python2 compatible.
Test: pass
Change-Id: Ibb0b7aa33ba1be3e2f40893da70f81c858479f7e
|
|
Since other flags use - instead of _, keep no-care-map flag consistent
Test: th
Change-Id: Ibf981ecbf7b3804e20c52ef1de8f55732cbe6295
|
|
Sometimes shutdown takes a while due to adb issues, gracefully terminate
with a timeout. This will throw an exception if timeout occured, telling
the developer that something went wrong.
Test: python3 update_device.py ota.zip
Change-Id: I44edc6a291fc682b9439ab97f2880d47dc4e457b
|
|
Test: th
Change-Id: I63904fae1a6900a6fd7a079667332102f2bede55
|
|
Test: update_device.py --verify_only some_ota.zip
Change-Id: I4d07dfe138064fd8747699a92b98a17090533179
|
|
Python3 expects write() to accept bytes or str, depending on file type(w
or wb). Since zipfile returns bytes, we must open output file with "wb",
which is the default.
Test: python3 update_device.py some_ota.zip
Change-Id: I9f163341921d7681988ee1eb01e98f0ecd5e98c9
|
|
When rebooting, device will skip update_verifier if care_map.pb isn't
found. For better testing, push care_map.pb to device by default
Test: python2 update_device.py some_ota.zip
Bug: 181499957
Change-Id: Ic47735be7dd7b1c1541613a88cab69ef57394b5a
|
|
Now AllocateSpaceForPayload() API does non-trivial work, it would be
nice if we have an easy way to invoke it from CLI for testing purposes.
Test: update_device.py --allocate ota.zip
Change-Id: I497fea33e8935a5481d7d831d35dac881e42262e
|
|
Test: treehugger
Change-Id: I748be77b7d8fe4bbc63f1edc672e5c32be6e8c91
|
|
Test: treehugger
Change-Id: I996e8ece01d5a68e9093460f24c84031f8419c53
|
|
Test: serve an OTA
Change-Id: I2e787db375b8dd4b24bc51dff6fef1002c4b4c5e
|
|
Currently, we use central directory's extra fields and filenames to
determine starting position of a zipentry's file data. However, central
directory's extra field might differ from extra field in local file
header. For example, the Extended-Timestamp field has different formats
depending on whether it's in local file header or central directory. We
should use local file header for computing offsets.
Test: Serve an OTA by update_device.py
Change-Id: I00d150d874b9c874bb713569ea14938e036f854e
|
|
It's a merge from chrome OS with some reverts.
1. the fd watcher change, because the libbrillo version isn't
compatible in aosp.
commit 6955bcc4ffe4cc9d62a88186b9a7e75d095a7897
commit 493fecb3f48c8478fd3ef244d631d857730dd14d
2. two libcurl unittest. Because the RunOnce() of the fake message
loop seems to have different behavior in aosp.
commit d3d84218cafbc1a95e7d6bbb775b495d1bebf4d2
Put preprocessor guards to use the old code in aosp. And we can
switch to the new code in the other path after adopting the new
libbrillo & libchrome.
Test: unit tests pass, apply an OTA
Change-Id: Id613599834b0f44f92841dbeae6303601db5490d
|
|
Update the update_payload scripts to be compatible with
python2 and python3. Python2 compatibility is needed since
the repo is shared with Android.
BUG=chromium:1011631
TEST=Executed aosp/system/update_engine/scripts/run_unittests and
cros_generate_update_payload
Cq-Depend: chromium:1904837, chromium:1911499
Change-Id: Ie450b80b5f7550051b38d320173ccc0c915f65e7
Reviewed-on: https://chromium-review.googlesource.com/c/aosp/platform/system/update_engine/+/1904310
Commit-Queue: Andrew Lassalle <andrewlassalle@chromium.org>
Tested-by: Andrew Lassalle <andrewlassalle@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Amin Hassani <ahassani@chromium.org>
Auto-Submit: Andrew Lassalle <andrewlassalle@chromium.org>
|
|
Add an option to support installation of the secondary payload. This is
used to verify an android factory OTA, where it has one step to install the
secondary payload. The payload and its property file store under the
secondary/ directory of the update package.
Test: install a secondary payload from a factory OTA package
Change-Id: I1d2e1d6945f1daa9afaab6af8ce9aad0f7c2100f
|
|
When the update package gets larger than 2 GiB, payload.bin offset
mentioned in metadata file for ota-streaming-property-files gets
shifted (CrAU of payload.bin) because ZipInfo FileHeader() returns
incorrect value. To solve the issue, offset is re-calculated from
fixed bytes of central directory file header, filename length and
extra length.
Test: manually create an A/B update package and run it using
update_device.py
Bug: 111198589
Change-Id: Iadb2e8bbff478d9b006bb155d57fea35968d84b7
|
|
Test: update_device.py --extra-headers 'SWITCH_SLOT_ON_REBOOT=0' ...
Change-Id: I5902153329243e6dc55d767d87bc974f206d32e0
|
|
When using '--file' (and without '--no-push'), it tries to push the
package to /data/ota_package/debug.zip. However, that's not allowed
directly with 'adb push', unless by restarting adb with 'adb root'.
This CL works around the issue by pushing the file to /data/local/tmp
first, then moving it over to the desired place.
Test: update_device.py --file <marlin-ota.zip>
Change-Id: I608284cc90918fc01cf7584569d4d7d4165148ca
|
|
update_device imports BaseHTTPServer, which is python2 only.
If python3 is the default python, an import error will be
thrown.
Test: Set default python to 3.4. Call update_device.py
Change-Id: Id053e695c334c597736b9844e11be389264700ea
|
|
Pass the offset and size to UpdateHandler.
Also added support for payload offset in update_payload.Payload.
Test: applied a local OTA
Change-Id: Ib116ef2c23a11e298118f203814c4ea8dd1629af
|
|
Recent changes in update_engine are now comparing the appid against
the product id.
Test: applied a local OTA
Change-Id: I2907e94a89bea5ebfa8236c96eec7601af8ad4e5
|
|
Automatically detect if the device is running an update_engine with
USE_OMAHA or not, and use different command based on that.
Made the http server serving payload a fake omaha server as well.
Added support for overriding the payload public key on the device.
Bug: 27316596
Test: update a device that uses omaha
Change-Id: I230d58ff105189dc8a624d46ee79cbe90c5f09b0
|
|
We weren't actually using our own pylintrc file in repo upload hook,
which will be fixed by https://android-review.googlesource.com/#/c/platform/tools/repohooks/+/458996/
Even though both camel case and snake case are allowed for function
and method names, they still have to be consistent in a single file.
https://pylint.readthedocs.io/en/latest/user_guide/options.html#multiple-naming-styles
Bug: 27316596
Test: repo upload
Change-Id: I98adba957a547115ef3d8b00fe2e3e4931707b31
|
|
This new script allows to execute the update flow on an Android device
connected via adb to the host. At the moment, it supports both providing
the payload over the network with an "adb reverse" connection and to
push the payload to a file on the device.
Bug: 35903885
Test: system/update_engine/scripts/update_device.py ota.zip
Change-Id: I1c6d4df97ce85b6e30367a53b351353a954efbdc
|