Problem
The XML <summary> for ZipArchiveEx.FixupWindowsPathSeparators starts with HACK: and then describes aapt2 behavior rather than what the method does. This method is a legitimate, permanently-needed workaround (it is actively called from Aapt2LinkAssetPack and BuildArchive), so the HACK: label is misleading. A <summary> should describe the method's behavior; the aapt2 rationale belongs in <remarks>.
Location
- File(s):
src/Xamarin.Android.Build.Tasks/Utilities/ZipArchiveEx.cs
- Line(s): 168-171
Current Code
/// <summary>
/// HACK: aapt2 is creating zip entries on Windows such as `assets\subfolder/asset2.txt`
/// </summary>
public void FixupWindowsPathSeparators (Action<string, string> onRename)
Suggested Fix
Rewrite the doc comment so the <summary> describes the method and the aapt2 detail moves into <remarks>:
/// <summary>
/// Rewrites zip entry names that use backslash path separators to use forward slashes.
/// </summary>
/// <remarks>
/// aapt2 creates zip entries on Windows with mixed separators such as `assets\subfolder/asset2.txt`,
/// which must be normalized to forward slashes for a valid archive.
/// </remarks>
public void FixupWindowsPathSeparators (Action<string, string> onRename)
Guidelines
- Comment-only change; do not alter method behavior.
- Follow dotnet/android formatting conventions (tabs, space before
().
Acceptance Criteria
Fix-finder metadata
- Script:
00-todo-fixme-hack
- Score:
30/30 (actionability: 10, safety: 10, scope: 10)
Generated by Nightly Fix Finder · 53.9 AIC · ⌖ 19.8 AIC · ⊞ 9.4K · ◷
Problem
The XML
<summary>forZipArchiveEx.FixupWindowsPathSeparatorsstarts withHACK:and then describes aapt2 behavior rather than what the method does. This method is a legitimate, permanently-needed workaround (it is actively called fromAapt2LinkAssetPackandBuildArchive), so theHACK:label is misleading. A<summary>should describe the method's behavior; the aapt2 rationale belongs in<remarks>.Location
src/Xamarin.Android.Build.Tasks/Utilities/ZipArchiveEx.csCurrent Code
Suggested Fix
Rewrite the doc comment so the
<summary>describes the method and the aapt2 detail moves into<remarks>:Guidelines
().Acceptance Criteria
HACK:prefix is removed from the doc comment.<remarks>).Fix-finder metadata
00-todo-fixme-hack30/30(actionability: 10, safety: 10, scope: 10)