Skip to content
Snippets Groups Projects
  1. Jun 13, 2024
    • Max Loh's avatar
      ASL update fields to finalized declarations, part 1 · b7a302e9
      Max Loh authored
      Includes: system_app_safety_label change to declaration, data labels ephemeral change, data labels category/type name consolidation
      
      Bug: b/329902686
      Test: Unit tests
      Change-Id: I74ce395ca14209eeedd05af7f18f9152f35ba605
      b7a302e9
  2. Jun 10, 2024
    • Victor Chang's avatar
      Fix frameworks/base/tools/localedata/extract_icu_data.py · 87f5809f
      Victor Chang authored
      LocaleDataTables.cpp will be generated in a separate CL.
      
      likelySubtags.txt has been removed from ICU4C. ICU4C reads the encoded
      mapping from  lsrnum in external/icu/icu4c/source/data/misc/langInfo.txt
      instead.
      
      For this script, we read the text mapping from likelySubtags.xml in CLDR
      instead for simplicity.
      
      The size of mapping increases significantly due to CLDR-16380 fixed in CLDR 44.
      
      Bug: 330126402
      Test: croot frameworks/base && ./tools/localedata/extract_icu_data.py $ANDROID_BUILD_TOP > libs/androidfw/LocaleDataTables.cpp
      Change-Id: I66b83035ad858ab9482a981c6e63be104741cd52
      87f5809f
  3. Jun 07, 2024
    • Michael Wright's avatar
      Remove execute bit from non-executable files. · 6a5fcafd
      Michael Wright authored
      This is almost certainly a mistake in all cases, and any files that are
      text-based have been spot checked to make sure they don't contain a
      shebang or have any other indications of intentionally being executable.
      
      Commands run:
          fdfind -t x -e java -x chmod -x
          fdfind -t x -e kt -x chmod -x
          fdfind -t x -e ogg -x chmod -x
          fdfind -t x -e xml -x chmod -x
          fdfind -t x -e aidl -x chmod -x
          fdfind -t x -e html -x chmod -x
          fdfind -t x -e png -x chmod -x
      
      Bug: 345485143
      Test: N/A
      Flag: Exempt, mechanical change
      Change-Id: I2902380611eb51d0c0e18f2f31e41f37163bd922
      6a5fcafd
  4. Jun 04, 2024
    • Max Loh's avatar
      ASL allow DataType to be easily compared (for lint annotation logic) · 769cee8e
      Max Loh authored
      For Android Studio annotations checking, the linter can parse both the annotations and human-readable XML into corresponding ASL java objects (the human-readable XML parsing logic already exists in this java library). The linter can then nestedly iterate through the map of data categories and map of data types; if corresponding entries don't exist in the XML-parsed ASL or the DataType are not equal, it can be flagged to the developer.
      
      Bug: 329902686
      Test: Unit tests.
      Change-Id: I3263157c57489dd782e70a385bc6f364b47655b4
      769cee8e
  5. May 21, 2024
    • Makoto Onuki's avatar
      Update Ravenwood OWNERRS · f0a0f9b7
      Makoto Onuki authored
      Bug: n/a
      Test: n/a
      Change-Id: I3c359283b8efa04d0731018c0d6647586221f8cc
      f0a0f9b7
    • Makoto Onuki's avatar
      [Hoststubgen] Allow substitution methods to have... · 11ba7649
      Makoto Onuki authored
      ... smaller visibility.
      
      Fix: 340893548
      Test: $ANDROID_BUILD_TOP/frameworks/base/ravenwood/scripts/run-ravenwood-tests.sh
      Flag: EXEMPT change affects only Ravenwood (hostside) tests
      Change-Id: Ib0b781754f55b759eb76c432f2f5d23f326b0e8c
      11ba7649
    • Priyanka's avatar
      Update location of output. · 9ea3a5c8
      Priyanka authored
      Fixes: 341863041
      Test: run commands in the Winscope README and check mapping updated
      Change-Id: I154874a376c62ad2bb6e38ef9ca4c0865493cf34
      9ea3a5c8
  6. May 15, 2024
  7. May 14, 2024
  8. May 08, 2024
    • Ronald Braunstein's avatar
      Use import for test-mapping rather than requesting files remain in sync · 787328b5
      Ronald Braunstein authored
      If there were intervening parent directories with extra TEST_MAPPING
      files, then "imports" might pick up extra modules, but in this case that
      won't happen.
      This change will ensure these two TEST_MAPPING file remain in sync.
      
      Test: atest -p frameworks/base/tools/hoststubgen:ravenwood-presubmit --dry-run
      	Finding Tests...
      	Found 'RavenwoodBivalentTest' as MODULE
      	Found 'RavenwoodMockitoTest' as MODULE
      	Found 'RavenwoodMinimumTest' as MODULE
      	Found 'RavenwoodCoreTest' as MODULE
      	Found 'CtsUtilTestCasesRavenwood' as MODULE
      Change-Id: I89d308e1596fa689aeb3c2e476c7707c0ff4dd8f
      787328b5
  9. May 07, 2024
    • Makoto Onuki's avatar
      [Ravenwood] Tweak build files · dfade847
      Makoto Onuki authored
      ... to allow other modules to refer to the text
      files.
      
      Bug: 292141694
      Test: ./scripts/run-all-tests.sh
      
      Change-Id: I46f0c0e238a6d7f8dc1a30cf111296a529c83664
      dfade847
    • Ryan Prichard's avatar
      aapt2: fix dangling reference to diag · cbcff740
      Ryan Prichard authored
      The lambdas that ManifestFixer::BuildRules attach to XmlActionExecutor
      outlive ManifestFixer::BuildRules, so they need to capture diag
      by-value instead of by-reference.
      
      Bug: 339119172
      Test: aapt2_tests
      Change-Id: I6b9b6a8733875247a5be12111413b45b99727e1f
      cbcff740
  10. Apr 30, 2024
    • Makoto Onuki's avatar
      [Ravenwood] Update TEST_MAPPINGs · ff419803
      Makoto Onuki authored
      Test: Treehugger
      Bug: 292141694
      Change-Id: I87b14fbac29fdefecd9c503c2c97d16b00151e58
      ff419803
    • Makoto Onuki's avatar
      [Ravenwood] Improve "supported API" CSV · 7c7f4903
      Makoto Onuki authored
      - Now we show all methods including unsupported ones, with actual
        policies.
      - Also show inherited APIs. e.g. Now Object.toString() will always be
        included in every class.
      
      Bug: 292141694
      Test: ./ravenwood/scripts/ravenwood-stats-collector.sh
          and examine the generated files
      Test: ./ravenwood/scripts/run-ravenwood-tests.sh
      
      Change-Id: I43bd40cf5013b0eb8f900dbc2f4b4b3fd158ad3f
      7c7f4903
  11. Apr 29, 2024
    • Mark Punzalan's avatar
      [aapt2] Add --non-updatable-system flag · cc694e55
      Mark Punzalan authored
      This adds `updatableSystem="false"` to the root <manifest> tag if no
      versionCode is specified (either explicitly or through --version-code).
      This attribute makes the APK not updatable (see b/266131956).
      
      Bug: 328302305
      Test: atest aapt2_tests
      Test: Manually ran `aapt2 link --non-updatable-system` and verified the
      resulting APK.
      
      Change-Id: I51cdbcdac7c03de10aac9bc22f5081e12fa142ab
      cc694e55
  12. Apr 26, 2024
    • Dario Freni's avatar
      Remove aapt2_results. · f4d8b9c2
      Dario Freni authored
      This rule was introduced in 2017 as a way to run unit tests in a continuous build target. We have better ways to achieve the same today.
      
      Bug: 337281646
      Bug: 332609042
      Test: presubmit
      Change-Id: Iba9934f39df2ebb883ded941d438b3528b3f29c2
      f4d8b9c2
    • Dario Freni's avatar
      Fix typo in aapt2_results genrule. · 3577d5d0
      Dario Freni authored
      Test: presubmit
      Change-Id: Ie32c7af67c17e4ffee8d5ce1fc74aa184925b755
      3577d5d0
  13. Apr 25, 2024
  14. Apr 24, 2024
    • Jeff DeCew's avatar
      Support new generated CustomFeatureFlags · c2556685
      Jeff DeCew authored
      * Broaden jarjar Flags rules for NFC.  Note that this brings the NFC rules in line with other packages
      * Opt classes named CustomFeatureFlags into Ravenwood
      
      Flag: none
      Bug: 336768870
      Test: presubmit
      Change-Id: Ib1e76ebd04915554f464ec9a3d101b07925e18be
      c2556685
  15. Apr 23, 2024
    • Michael Wright's avatar
      V is 35. · e4e3d4a1
      Michael Wright authored
      It's not bromine, it's not a gauge of film: it's the next Android
      release.
      
      Bug: 335304236
      Test: presubmit
      Change-Id: I20b47bf5c4d922f2e2061bd1ef0606fb5a7f7efb
      e4e3d4a1
  16. Apr 18, 2024
    • Kean Mariotti's avatar
      Avoid outer/inner class name clashes · 804f0134
      Kean Mariotti authored
      In some cases, protoc-gen-javastream could emit outer classes
      and inner classes with the same name, which is invalid java.
      
      This commit extends protoc-gen-javastream to append an "OuterClass"
      suffix, if the outer class name clashes with any message.
      This behavior is consistent with the standard protoc.
      
      Bug: 276433199
      Test: presubmit
      Change-Id: I4e92d70c10c4d92d103b00f15b159acc08dffff2
      804f0134
    • Kean Mariotti's avatar
      Emit extension fields · 2163c8ae
      Kean Mariotti authored
      Extend protoc-gen-javastream to emit a message's extension fields
      (in addition to the current enums, nested types and regular fields).
      
      Bug: 276433199
      Test: presubmit
      Change-Id: Ibf25ff58796abcd59aa242bdf4295ba3ff2baf67
      2163c8ae
    • Kean Mariotti's avatar
      cleanup messages allow list · 18a165ea
      Kean Mariotti authored
      - Pass around container by reference instead of value
        (avoid unneeded deep-copies)
      - Use std::unordered_set instead of std::set (no need to be sorted)
      - Rename variable "messages_to_compile" to "messages_allowlist"
        to reduce confusion with other message lists in the code
      - Remove raw pointer
      
      Bug: 321668269
      Test: presubmit
      Change-Id: I43eaf5c1db3d15b066a95f34373211aadf6417b4
      18a165ea
  17. Apr 11, 2024
  18. Apr 09, 2024
  19. Apr 08, 2024
  20. Apr 05, 2024
    • Makoto Onuki's avatar
      Ravenwood/HostStubGen refactor and bug fixes · e2f3e57f
      Makoto Onuki authored
      [Fixed the NPE in the sysui test]
      
      
      - Bug fix: Now native substitution methods can handle bytes correctly.
      
      - Spec change: disallow using DisabledOnNonRavenwood on types.
      
      It turned out the device side test runner can't handle it if a class rule
      uses Assume.
      
      We could still support it with a non-class rule, but to avoid confusion,
      let's disallow using it on classes for the time being.
      
      - Add more tests
      
      - Some refactoring for future changes.
      
      Test: ./ravenwood/scripts/run-ravenwood-tests.sh
      Test: v2/sysui/unit_test on ABTD: https://android-build.corp.google.com/abtd/run/L40000030002931752/
      Bug: 292141694
      Bug: 332973325
      Change-Id: I6d8df1e879840b60326e2beeeee2d8ee7b2ff925
      e2f3e57f
  21. Apr 04, 2024
  22. Apr 03, 2024
    • Makoto Onuki's avatar
      Ravenwood/HostStubGen refactor and bug fixe · ec5e313e
      Makoto Onuki authored
      - Bug fix: Now native substitution methods can handle bytes correctly.
      
      - Spec change: disallow using DisabledOnNonRavenwood on types.
      
      It turned out the device side test runner can't handle it if a class rule
      uses Assume.
      
      We could still support it with a non-class rule, but to avoid confusion,
      let's disallow using it on classes for the time being.
      
      - Add more tests
      
      - Some refactoring for future changes.
      
      Test: ./ravenwood/scripts/run-ravenwood-tests.sh
      Bug: 292141694
      Change-Id: I6e2fd389ef63d31472f5eafcd9a58ac9e52e8117
      ec5e313e
    • Pablo Gamito's avatar
      Improve performance of ProtoLog · 7de1d5a2
      Pablo Gamito authored
      Wrap all protolog calls in an if condition using a cached state variable to make sure we don't have any overhead if the protolog message is disbaled
      
      Bug: 327341670
      
      Test: android.platform.test.scenario.calculator.OpenAppMicrobenchmark#testOpen v2/android-crystalball-eng/health/microbench/startup/hscapps/compile-speed-profile/hotlaunch/open-calculator
      Change-Id: Ic031fe076c0897d168b1e7982ad27824b2db999c
      7de1d5a2
  23. Apr 01, 2024
  24. Mar 28, 2024
    • Priyanka Advani's avatar
      Revert "Aslgen tests" · 9d5ad5cf
      Priyanka Advani authored
      Revert submission 26719621
      
      Reason for revert: Culprit for test breakages in b/331778845
      
      Reverted changes: /q/submissionid:26719621
      
      Change-Id: I16025e4a452b55017cb2717a12fdab05ccc01931
      9d5ad5cf
    • Priyanka Advani's avatar
      Revert "Adding more supported fields/logic to aslgen." · 45bd8e28
      Priyanka Advani authored
      Revert submission 26719621
      
      Reason for revert: Culprit for test breakages in b/331778845
      
      Reverted changes: /q/submissionid:26719621
      
      Change-Id: I3e69645c070d5aca4825e2b233513c7790a15239
      45bd8e28
    • Max Loh's avatar
      Adding more supported fields/logic to aslgen. · d4c7fa82
      Max Loh authored
      Includes top-level version number, transparency_info. Refactored non-Marshallable conversion logic from AndroidSafetyLabel to AslConverter. Added logic to support some more non-required fields without throwing an error.
      
      Bug: 329902686
      Test: A future CL will add a lot of unit tests, after which unit tests can be written in tandem with implementation.
      Change-Id: If4fb73cdcc40abac77ec82e436ca11ebe4feb48d
      d4c7fa82
    • Max Loh's avatar
      Aslgen tests · 5b444b94
      Max Loh authored
      Contains logic for testing as well as a couple of initial tests for HR to OD conversion. More tests will be added later. Also fixed a bug with data type parsing.
      
      Bug: 329902686
      Test: JUnit unit tests, verified by running atest
      Change-Id: I6103f5f93169f25a430cab16c2d1cb1fc4b89d44
      5b444b94
  25. Mar 20, 2024
    • Max Loh's avatar
      ASL validation logic · bd237be4
      Max Loh authored
      Adds validation logic for isSharingOptional, isCollectionOptional, and various expected elements in the input XML file.
      
      Bug: 287487923
      Test: TODO in future CLs
      Change-Id: I0a2261ec3c71a1d2df977810d065dfc5a4dda5e3
      bd237be4
    • Max Loh's avatar
      Refactor with interface pattern, and throw exception for unsupported formats · 9dd4e469
      Max Loh authored
      Revised methods allow marshalling/unmarshalling from a list of XML nodes, allowing DataCategory to be incorporated seamlessly.
      Factory pattern makes it easier to maintain createFromHrElements.
      go/asl-tc-aosp
      
      Bug: 287487923
      Test: TODO in future CLs
      Change-Id: I9fff3c1e28df74ef934da6355632c91e0ec91e79
      9dd4e469
Loading