Skip to content

fix: use item tags for incompatible formats#4097

Merged
IgorEisberg merged 1 commit into
mainfrom
value-formats
Feb 26, 2026
Merged

fix: use item tags for incompatible formats#4097
IgorEisberg merged 1 commit into
mainfrom
value-formats

Conversation

@IgorEisberg
Copy link
Copy Markdown
Collaborator

This improves validation of value format compatibility with a resource type, and output <item> tag if the value format is incompatible (e.g. a string value for a drawable, etc).

As I replied in #4096, aapt2 will reject values that are not a file or a reference for certain types (like layout) even if we output them as <item> tags with the format attribute. Such values are non-standard (custom post-processing most likely) and can only be patched by changing aapt2 behavior, which is out of the scope of this PR.

@iBotPeaches iBotPeaches added this to the 3.0.2 milestone Feb 26, 2026
@IgorEisberg IgorEisberg merged commit b764953 into main Feb 26, 2026
18 checks passed
@IgorEisberg IgorEisberg deleted the value-formats branch February 26, 2026 12:05
iBotPeaches added a commit to iBotPeaches/apktool.org that referenced this pull request Mar 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants