9f884e6c55
We use the timestamps in builds to determine a downgrade, which might
not be always the truth. For examples, two builds cut from different
branches may carry timestamps in a reverse order. An incremental package
won't be able to be pushed nor applied, based on the timestamp
comparison.
We used to handle such a case with manual work, by setting the
post-timestamp to (pre-timestamp + 1) in the package metadata. This CL
automates the process by adding a new flag --override_timestamp.
Note that it doesn't change anything in the installed image, but only
affects the assertions for pushing / installing the package.
With the change in this CL:
- If it's a downgrade without any extra flag, fail the package
generation (we only print warnings prior to this CL);
- If it's a downgrade with --downgrade flag, generate a downgrade
package with forced data wipe (same as before);
- If it's a downgrade with --override_timestamp, generate a normal
incremental with hacked timestamp (pre-timestamp + 1) (new in this CL
to avoid the manual change);
- If it's not a downgrade but with any of the above two flags specified,
fail the package generation.
Bug: 33744169
Test: Generate an incremental from builds with reversed timestamps.
Change-Id: I8b187d32708b4a7c3e20f8c6adb8f9527b73b965
Merged-In: I8b187d32708b4a7c3e20f8c6adb8f9527b73b965
(cherry picked from commit
|
||
---|---|---|
.. | ||
acp | ||
apicheck | ||
atree | ||
droiddoc | ||
fs_config | ||
fs_get_stats | ||
ijar | ||
makeparallel | ||
releasetools | ||
rgb2565 | ||
signapk | ||
signtos | ||
zipalign | ||
ziptime | ||
adbs | ||
Android.mk | ||
buildinfo.sh | ||
check_builds.sh | ||
check_radio_versions.py | ||
compare_fileslist.py | ||
diff_package_overlays.py | ||
dump-package-stats | ||
event_log_tags.py | ||
fileslist.py | ||
filter-product-graph.py | ||
findleaves.py | ||
fixlinebreaks.sh | ||
generate-notice-files.py | ||
java-event-log-tags.py | ||
java-layers.py | ||
merge-event-log-tags.py | ||
mktarball.sh | ||
normalize_path.py | ||
parsedeps.py | ||
post_process_props.py | ||
print_module_licenses.sh | ||
product_debug.py | ||
warn.py |