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

chore: Download latest bundle analysis artifact from base branch #2994

Merged
merged 1 commit into from
Dec 11, 2023

Conversation

usame-algan
Copy link
Member

@usame-algan usame-algan commented Dec 11, 2023

What it solves

Follow up for #2803

The download-artifact action we use downloads artifacts in chronological order so it always compares with the oldest dev bundle instead of the newest. There is an open issue on the board but no fix so far (see discussion). We switch to a custom bash script that is also linked in the discussion to download and unzip the bundle from dev.

Screenshots

Screenshot 2023-12-11 at 15 55 05

Checklist

  • I've tested the branch on mobile 📱
  • I've documented how it affects the analytics (if at all) 📊
  • I've written a unit/e2e test for it (if applicable) 🧑‍💻

Copy link

github-actions bot commented Dec 11, 2023

Branch preview

✅ Deploy successful!

https://fix_bundle_analysis--walletweb.review-wallet-web.5afe.dev

Copy link

github-actions bot commented Dec 11, 2023

ESLint Summary View Full Report

Annotations are provided inline on the Files Changed tab. You can also see all annotations that were generated on the annotations page.

Type Occurrences Fixable
Errors 0 0
Warnings 0 0
Ignored 0 N/A
  • Result: ✅ success
  • Annotations: 0 total

Report generated by eslint-plus-action

@usame-algan usame-algan force-pushed the fix-bundle-analysis branch 2 times, most recently from 2e7e134 to 514d651 Compare December 11, 2023 12:11
Copy link

github-actions bot commented Dec 11, 2023

Coverage report

St.
Category Percentage Covered / Total
🟡 Statements
76.77% (-0.89% 🔻)
10989/14314
🔴 Branches
51.86% (-1.94% 🔻)
2269/4375
🟡 Functions
60.4% (-0.93% 🔻)
1673/2770
🟡 Lines
78.14% (-0.84% 🔻)
9941/12722
Show files with reduced coverage 🔻
St.
File Statements Branches Functions Lines
🟡
... / transactions.ts
60.53% (-3.51% 🔻)
29.03% (-3.23% 🔻)
28.57% (-4.76% 🔻)
64.29% (-3.06% 🔻)
🟢
... / safeCoreSDK.ts
88% (-2% 🔻)
90.91% 85.71%
90.91% (-2.27% 🔻)
🟢 src/utils/hex.ts
33.33% (-66.67% 🔻)
0% (-100% 🔻)
0% (-100% 🔻)
100%
🟡
... / sdk.ts
67.06% (-2.35% 🔻)
35.29%
63.64% (-9.09% 🔻)
67.11% (-1.32% 🔻)
🟡
... / settingsSlice.ts
72.58% (-3.23% 🔻)
83.33%
65.22% (-4.35% 🔻)
63.83% (-4.26% 🔻)
🟡
... / safeTx.ts
66.67% (-2.08% 🔻)
100%
50% (+5.56% 🔼)
60% (-6.67% 🔻)
🟢
... / hooks.ts
77.36%
57.58% (-3.03% 🔻)
68.42% 80.85%
🟢
... / useIsValidExecution.ts
84.44% (-2.22% 🔻)
58.33% (-8.33% 🔻)
80%
85.71% (-2.38% 🔻)
🔴
... / index.tsx
55.56% 19.05%
28.57% (-14.29% 🔻)
53.66%
🔴
... / index.tsx
38.46% (-2.56% 🔻)
0% 0% 45.45%
🔴
... / TxSecurityContext.tsx
50% (-6.25% 🔻)
0% 0%
50% (-3.85% 🔻)
🟢
... / index.tsx
100%
61.11% (-38.89% 🔻)
100% 100%
🟢
... / index.tsx
96.67% (-3.33% 🔻)
51.72% 100%
96.3% (-3.7% 🔻)
🔴
... / index.tsx
46.67% (-53.33% 🔻)
100%
0% (-100% 🔻)
50% (-50% 🔻)
🔴
... / ExecuteForm.tsx
42.86% (-54.02% 🔻)
0% (-87.88% 🔻)
0% (-100% 🔻)
43.55% (-53.17% 🔻)
🟢
... / index.tsx
77.78% (-22.22% 🔻)
100%
0% (-100% 🔻)
87.5% (-12.5% 🔻)
🔴
... / useWalletCanRelay.ts
35% (-35% 🔻)
0% (-83.33% 🔻)
0% (-50% 🔻)
41.18% (-29.41% 🔻)
🟡
... / index.tsx
60% (-33.33% 🔻)
16.67% (-58.33% 🔻)
25% (-50% 🔻)
64.29% (-28.57% 🔻)
🔴
... / relaying.ts
33.33% (-33.33% 🔻)
0% 0% 50%
🔴
... / useGasLimit.ts
34.78% (-43.48% 🔻)
0% (-35.29% 🔻)
0% (-62.5% 🔻)
36.36% (-40.91% 🔻)
🔴
... / index.tsx
52.63% (-26.32% 🔻)
0%
0% (-33.33% 🔻)
55.56% (-22.22% 🔻)
🟢
... / index.tsx
88%
85.29% (-5.88% 🔻)
50% 87.5%
🔴
... / useAdvancedParams.ts
36.36% (-63.64% 🔻)
0% (-100% 🔻)
0% (-100% 🔻)
40% (-60% 🔻)
🔴
... / useUserNonce.ts
41.67% (-50% 🔻)
0% (-100% 🔻)
0% (-100% 🔻)
50% (-40% 🔻)
🔴
... / SignForm.tsx
58.7% (-35.18% 🔻)
38.46% (-50.82% 🔻)
33.33% (-66.67% 🔻)
59.09% (-36.46% 🔻)
🟢
... / ConfirmationTitle.tsx
100%
66.67% (-33.33% 🔻)
100% 100%
🟢
... / useDecodeTx.ts
94.44% (-5.56% 🔻)
58.33% (-16.67% 🔻)
100%
93.75% (-6.25% 🔻)
🟢
... / index.tsx
75% (-0.86% 🔻)
88.89% (+8.89% 🔼)
66.67% (+16.67% 🔼)
80.95% (+3.17% 🔼)

Test suite run success

1288 tests passing in 178 suites.

Report generated by 🧪jest coverage report action from 16b9bde

@usame-algan usame-algan force-pushed the fix-bundle-analysis branch 6 times, most recently from af7d339 to 9f75fe7 Compare December 11, 2023 14:38
Copy link

github-actions bot commented Dec 11, 2023

📦 Next.js Bundle Analysis for safe-wallet-web

This analysis was generated by the Next.js Bundle Analysis action. 🤖

This PR introduced no changes to the JavaScript bundle! 🙌

@usame-algan usame-algan marked this pull request as ready for review December 11, 2023 14:56
Copy link
Member

@katspaugh katspaugh left a comment

Choose a reason for hiding this comment

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

If it works, it works, but not ideal that we have to do it "manually"...

set +x
curl -H "Accept: application/vnd.github+json" -H "Authorization: token $GH_TOKEN" -L -o "${DESTINATION}.zip" "$DOWNLOAD_URL"
set -x
unzip "${DESTINATION}.zip" -d "${DESTINATION}" && mkdir -p "${DESTINATION}/bundle" && mv "${DESTINATION}/__bundle_analysis.json" "${DESTINATION}/bundle/"
Copy link
Member Author

Choose a reason for hiding this comment

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

We need to unzip the contents of ${DESTINATION}.zip into the directory ${DESTINATION}/bundle. I tried using wildcards but without success so I hard-code the filename here.

@usame-algan
Copy link
Member Author

If it works, it works, but not ideal that we have to do it "manually"...

Agreed, I've left a message in a related issue on hashicorp/nextjs-bundle-analysis#66

@usame-algan usame-algan merged commit d9e7180 into dev Dec 11, 2023
15 checks passed
@usame-algan usame-algan deleted the fix-bundle-analysis branch December 11, 2023 15:31
@github-actions github-actions bot locked and limited conversation to collaborators Dec 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants