File: mergeall-products/unzipped/test/ziptools/docetc/android11-demo-1.3/_README.txt
SUMMARY
-------
This folder demos ziptools' unzipping support for both content and
metadata in all three of the storage types available on Android 11,
and reflect both Android's state in fall 2021 and ziptools 1.3.
In sum: the same test was run on a Pixel 4a and a Galaxy Z Fold3,
both running Android 11. Results are nearly the same, and all
storage types support content and modtimes well. Results vary per
storage type for symlinks and Unix permissions, however. Moreover,
the Fold3 supports permissions in app-specific storage, but the Pixel
does not. In other words, Android 11's filesystem support varies by
both storage type _and_ vendor. Fragmentation spawns convolution!
ANDROID STORAGE TYPES
---------------------
Background: Android has three storage categories today, which
differ in speed, accessibility, and longevity. In brief:
Shared (at /sdcard or similar):
May run 10x-100x slower in 11, but can be accessed by any app
with simple permission, and outlives app uninstalls
App-specific (at /sdcard/Android/data/app):
May run faster, but requires special permission to be accessed
by other apps, and may be removed on app uninstall
App-private (at /data/data/app or similar):
May be similarly faster, but can be accessed only by the sole
associated app (sans SAF), and may be removed on app uninstall
The latter two are automatically deleted on app uninstall, unless
a new special flag is set by the app's manifest file, as noted at
learning-python.com/mergeall-android11-updates.html#uninstallretains.
Permission restrictions are more rigid; a tkinter GUI run in Pydroid
3, for instance, may have no access to content in Termux's storage.
Conversely, retained narrow permissions can make content unviewable.
Nit: Google often calls app-specific and app-private "app-specific
external and internal," respectively, presumably as a legacy; there
is nothing external about either storage type today, and there are
similar categories on removable drives, but this harkens back to a
time when "external" was actually a card. History may also be to
blame for having three storage categories in the first place, but
that's not much of an excuse for propagating the confusion today.
Also nit: Termux's app-private home folder can be accessed outside
the Termux app, by using its Storage Access Framework (SAF) interface.
A handful of file explorers provide access this way, but it's really
a bypass of the normal Android permission rules. For more details:
https://learning-python.com/
android-deltas-scripts/_README.html#termux-app-private-SAF
TEST DETAILS
------------
All tests here were run on September 3, 2021. The zipped-data
logfile here gives the initial state of this demo's test data
on macOS. This data was zipped by ziptools, and the same zipfile
was copied to both Android 11 devices.
The two content logfiles here demo ziptools extracts on Android 11,
for shared, app-specific, and app-private internal (non-removable)
storage types. To test, identical commands were run in the Termux
app, on Pixel 4a and Z Fold3 devices running Android 11.
TEST RESULTS
------------
On both the Pixel and Fold3, ziptools extracts support and retain
both content and modtimes in all three Android 11 storage types.
This includes folder modtimes dropped by copies in many Android
file-explorer apps. Mergeall's diffall and mergeall scripts prove
the same content and modtime results for all three storages.
Unix permissions and symlinks, however, fare differently across
both storage types and test devices:
On the Pixel:
Only app-private storage retains permissions and symlinks.
Shared and app-specific storage lose both.
On the Fold3:
Only app-private storage retains symlinks, but both app-specific
and app-private storage retain permissions. Shared storage
loses both permissions and symlinks as it does on the Pixel.
Thus, the Fold3's Android 11 implements permissions differently than
the Pixel's, and filesystem support varies by both storage type and
device vendor.
This convolution is obviously subpar from both documentation and
development perspectives. Given that storage types wholly define
content's scope, users are also left to choose between speed and
metadata, and cross-app utility. Fix me, please.