Repository navigation
Speed up deploy archive creation - #7450
Conversation
Resolve excluded archive paths to device/inode pairs once instead of calling samefile() for every walked entry against every exclusion, and store the precompressed .gz/.br/.zst frontend sidecars instead of deflating them again. Split out of #7054. Claude-Session: https://claude.ai/code/session_018nWB9r2HcC5tkT72UxWgGj
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Merging this PR will improve performance by 4.67%
Performance Changes
Tip Curious why performance improved? Comment Comparing Footnotes
|
Split out of #7054 per @masenf's request to land the deploy speedups as separate, individually measured patches. This one only touches archive creation.
Changes
files_to_excludeto(st_dev, st_ino)pairs once, instead of callingPath.samefile()for every walked file and directory against every exclusion (andexists()on each exclusion every time)..gz/.br/.zstfrontend sidecars infrontend.zipinstead of deflating them a second time. Everything else, including every backend entry, staysZIP_DEFLATED.Measurement
build.zip_app()on an already-built.web(716 frontend files), 9 iterations × 2 processes, median:frontend.zipbackend.zipfrontend.zipsizeThe whole
zip_durationphase of an export on this app is ~0.25 s, so this is a small absolute win; it is also the simplest patch in the set.Measurement setup
Five-page app from the
blanktemplate (Radix Themes + Tailwind v4 plugins), Linux x86_64, 4 vCPU, Python 3.14, Node 22.22, npm 10.9, bun 1.4.2. Each run is a fresh interpreter callingreflex.utils.export.export()the same wayreflex exportdoes; durations are the phase timings the export already reports to telemetry (compileincludes the dependency install). Medians of 3 runs unless noted. Vite dominates every export (~6.5 s); these numbers isolate the part this PR touches.Type of change
Checklist
tests/unitssuite passes locally except the 14reflex_bench/drivers/test_browser.pycases that need a Playwright browser launch, which fail identically on untouchedmainin this sandboxruff check,ruff format --check,codespell, andpyright reflex testspass locallyhttps://claude.ai/code/session_018nWB9r2HcC5tkT72UxWgGj
Generated by Claude Code