Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use File APIs when comparing paths in the AggregatedPackagesTransform. #2728

Merged
merged 1 commit into from
Jun 28, 2021

Conversation

copybara-service[bot]
Copy link

Use File APIs when comparing paths in the AggregatedPackagesTransform.

Using file APIs allows for platform-agnostic path comparisons where as File#parent() returns a String which will contain path separators that are OS specific and will fail to match with the known aggregated packages path that use UNIX-based file separator '/'. Specifically this fixes an issue for Windows users whose file separators are ''. Note that JarEntry path matching is String based but well formatted Jar files (which are Zip files) regardless of the host OS use forward slashes as path separator.

Fixes #2695

RELNOTES=Fix an issue where enableAggregatingTask would not correctly generate Hilt classes when compiling in a dev environment with Windows OS.

Using file APIs allows for platform-agnostic path comparisons where as File#parent() returns a String which will contain path separators that are OS specific and will fail to match with the known aggregated packages path that use UNIX-based file separator '/'. Specifically this fixes an issue for Windows users whose file separators are '\'. Note that JarEntry path matching is String based but well formatted Jar files (which are Zip files) regardless of the host OS use forward slashes as path separator.

Fixes #2695

RELNOTES=Fix an issue where `enableAggregatingTask` would not correctly generate Hilt classes when compiling in a dev environment with Windows OS.
PiperOrigin-RevId: 381943832
@copybara-service copybara-service bot merged commit a7c3c9e into master Jun 28, 2021
@copybara-service copybara-service bot deleted the test_381877388 branch June 28, 2021 21:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Using enableAggregatingTask does not generate classes
1 participant