Skip to content

fix(assets): remove '* Temp (LTR|RTL)' staging folders to restore build determinism#1087

Merged
Hotell merged 1 commit into
microsoft:mainfrom
Hotell:chore/remove-duplicate-temp-assets
Jun 15, 2026
Merged

fix(assets): remove '* Temp (LTR|RTL)' staging folders to restore build determinism#1087
Hotell merged 1 commit into
microsoft:mainfrom
Hotell:chore/remove-duplicate-temp-assets

Conversation

@Hotell

@Hotell Hotell commented May 20, 2026

Copy link
Copy Markdown
Collaborator

Follow-up to #1086 — must merge after that PR.

Removes the 20 assets/* Temp (LTR|RTL)/ folders flagged as known-dirty by the detector introduced in #1086, and drops the matching KNOWN_DUPLICATE_SOURCE allowlist from importer/generate.js. With the allowlist gone, the default --on-duplicate=fail now guards against any new colliding asset folder being added.

Why

These folders contain SVGs named after the opposite icon (e.g. assets/Arrow Undo Temp RTL/SVG/ic_fluent_arrow_redo_*.svg), have no metadata.json, and write into the same flat intermediate/ filenames as the canonical asset folders. The async copy in generate.js then resolves the collision non-deterministically, producing different lib/atoms/svg/*.js, barrel chunks, and font binaries on each clean build. #1086 added a detector + temporary allowlist for them; this PR removes the underlying source data and the allowlist.

Folders removed (20, 272 files total)

Icon family Folders
Arrow Redo assets/Arrow Redo Temp LTR/, assets/Arrow Redo Temp RTL/
Arrow Undo assets/Arrow Undo Temp LTR/, assets/Arrow Undo Temp RTL/
Table Freeze Column assets/Table Freeze Column Temp LTR/, assets/Table Freeze Column Temp RTL/
Table Freeze Column And Row assets/Table Freeze Column And Row Temp LTR/, assets/Table Freeze Column And Row Temp RTL/
Text Align Left assets/Text Align Left Temp LTR/, assets/Text Align Left Temp RTL/
Text First Line assets/Text First Line Temp LTR/, assets/Text First Line Temp RTL/
Text Grammar Arrow Left assets/Text Grammar Arrow Left Temp LTR/, assets/Text Grammar Arrow Left Temp RTL/
Text Grammar Arrow Right assets/Text Grammar Arrow Right Temp LTR/, assets/Text Grammar Arrow Right Temp RTL/
Text Hanging assets/Text Hanging Temp LTR/, assets/Text Hanging Temp RTL/
Text Paragraph assets/Text Paragraph Temp LTR/, assets/Text Paragraph Temp RTL/

Each folder contained only PDF/ and SVG/ subdirectories with .pdf / .svg files — no metadata.json or other tracked files.

Verification

Test Result
node importer/generate.js … --target=react --on-duplicate=fail on full assets/ 0 collisions, exit 0
Synthetic two-folder collision fixture exit 1 (detector still works)
Two clean nx run react-icons:build runs → diff -rq lib/ lib-cjs/ metadata.json No differences — React icon output is now byte-deterministic

Out of scope

Reviewer checklist

  • Design / icon-asset team: confirm these folders were staging artifacts and are not referenced by any active pipeline (iOS, Android, Flutter, docs generators)
  • Confirm monosize.baseline.json doesn't need updating (no React icon export changes expected — canonical folders already provide the same names)

Stack note

This PR's diff against main currently includes the commit from #1086 (a4427400a2). Once #1086 merges, this PR will rebase automatically and show only the cleanup commit.

@github-actions

github-actions Bot commented May 20, 2026

Copy link
Copy Markdown

📋 PR Validation Summary

Check the Build react library job summary for detailed reports:

  • 📦 Bundle Size — size comparison against the base branch
  • 📖 Docsite Preview — build artifact with local preview instructions

To view: click the link above → select the Build react library job → open the Summary tab.

@Hotell Hotell requested a review from etudie May 20, 2026 08:40
@Hotell Hotell force-pushed the chore/remove-duplicate-temp-assets branch from 9e60bbc to 47b74b6 Compare May 21, 2026 13:28
@Hotell Hotell changed the title chore(assets): remove '* Temp (LTR|RTL)' staging folders to restore build determinism fix(assets): remove '* Temp (LTR|RTL)' staging folders to restore build determinism May 21, 2026
@Hotell Hotell marked this pull request as ready for review May 21, 2026 15:20
@Hotell Hotell requested a review from dmytrokirpa May 21, 2026 15:20

@etudie etudie left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the bump, missed this PR!
Noting your rebase comment.

Looks good!

@Hotell Hotell force-pushed the chore/remove-duplicate-temp-assets branch from 47b74b6 to a32aad4 Compare June 15, 2026 10:58
@Hotell Hotell requested a review from a team as a code owner June 15, 2026 10:58
…llowlist

These 20 folders were staging artifacts that caused non-deterministic React
atom/font output via filename collisions in importer/generate.js (see microsoft#1086).
They contain SVGs named after the OPPOSITE icon (e.g. 'Arrow Undo Temp RTL/
SVG/ic_fluent_arrow_redo_*.svg'), have no metadata.json, and are not consumed
by any active pipeline.

With the folders gone, the KNOWN_DUPLICATE_SOURCE allowlist in
importer/generate.js is also removed; the default --on-duplicate=fail now
guards against any new colliding asset folders.

Verified: two clean 'nx run react-icons:build' runs after this change
produce byte-identical lib/, lib-cjs/, and metadata.json.

Follow-up to microsoft#1086.
@Hotell Hotell force-pushed the chore/remove-duplicate-temp-assets branch from a32aad4 to 74c6575 Compare June 15, 2026 16:14
@Hotell Hotell merged commit 56b3865 into microsoft:main Jun 15, 2026
6 checks passed
@Hotell Hotell deleted the chore/remove-duplicate-temp-assets branch June 15, 2026 16:25
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