Skip to content

Commit c1daaa1

Browse files
fix: disable fallback upload mechanism that was deleting large files
The fallback was being triggered and removing all JS files >100KB, which corrupted the main bundle. Changes: - Disabled fallback upload completely (if: false) - Set main upload to fail properly (continue-on-error: false) - Increased memory limit to 8GB for main upload - This ensures the complete 1.6MB bundle is uploaded intact
1 parent 7be12a0 commit c1daaa1

1 file changed

Lines changed: 9 additions & 25 deletions

File tree

.github/workflows/ci.yml

Lines changed: 9 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -195,8 +195,8 @@ jobs:
195195
196196
echo "✅ Artifact preparation completed"
197197
198-
#FIX: Disable zstdmt to prevent buffer overflow
199-
- name: ⚡ Upload Pages artifact (fixed)
198+
#Upload complete artifact without modifications
199+
- name: ⚡ Upload Pages artifact
200200
id: upload-artifact
201201
uses: actions/upload-pages-artifact@v4
202202
with:
@@ -205,31 +205,15 @@ jobs:
205205
retention-days: 1
206206
env:
207207
# Increase buffer sizes to prevent overflow
208-
NODE_OPTIONS: '--max-old-space-size=4096'
208+
NODE_OPTIONS: '--max-old-space-size=8192'
209209
# Set environment for stable tar operations
210210
TAR_OPTIONS: '--no-same-permissions --no-same-owner'
211-
continue-on-error: true
211+
continue-on-error: false
212212

213-
- name: ⚡ Fallback upload (if main upload fails)
214-
if: steps.upload-artifact.outcome == 'failure'
213+
- name: ⚡ Fallback upload (DISABLED - was corrupting files)
214+
if: false
215215
run: |
216-
echo "⚠️ Main upload failed, trying fallback approach..."
217-
218-
# Create a smaller artifact by being more aggressive with optimization
219-
mkdir -p dist-fallback
220-
cp -r dist/* dist-fallback/
221-
222-
# Remove source maps completely
223-
find dist-fallback/ -name "*.map" -delete
224-
225-
# Remove large vendor chunks that can be recreated
226-
find dist-fallback/ -name "*vendor*.js" -size +500k -delete
227-
228-
# Remove any non-essential JS files larger than 100k
229-
find dist-fallback/ -name "*.js" -size +100k -not -name "index.*" -delete
230-
231-
# Remove any non-essential CSS files larger than 50k
232-
find dist-fallback/ -name "*.css" -size +50k -not -name "index.*" -delete
216+
echo "⚠️ Fallback mechanism disabled to prevent file corruption"
233217
234218
# Remove any large image files that aren't critical
235219
find dist-fallback/ -name "*.jpg" -o -name "*.jpeg" -o -name "*.png" -o -name "*.gif" -o -name "*.webp" | while read file; do
@@ -262,8 +246,8 @@ jobs:
262246
263247
echo "✅ Fallback artifact prepared safely"
264248
265-
- name: ⚡ Upload fallback artifact
266-
if: env.SKIP_PAGES_STEPS != 'true' && steps.upload-artifact.outcome == 'failure'
249+
- name: ⚡ Upload fallback artifact (DISABLED)
250+
if: false
267251
uses: actions/upload-pages-artifact@v4
268252
with:
269253
path: './dist-fallback'

0 commit comments

Comments
 (0)