Skip to content

Commit a865120

Browse files
authored
Merge pull request #6 from openSVM/copilot/fix-108b85b9-2783-4996-a557-976f2f1ef253
Fix CI failure by updating yarn.lock to match package.json dependencies
2 parents bb115d1 + e2bd023 commit a865120

File tree

9 files changed

+1459
-74
lines changed

9 files changed

+1459
-74
lines changed

.github/workflows/build-all-platforms.yml

Lines changed: 33 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,10 @@ jobs:
2222
cache: 'yarn'
2323

2424
- name: Install dependencies
25-
run: yarn install --frozen-lockfile
25+
run: |
26+
for i in 1 2 3; do
27+
yarn install --frozen-lockfile && break || sleep 10
28+
done
2629
2730
- name: Build web application
2831
run: ./scripts/build-web.sh
@@ -48,7 +51,10 @@ jobs:
4851
cache: 'yarn'
4952

5053
- name: Install dependencies
51-
run: yarn install --frozen-lockfile
54+
run: |
55+
for i in 1 2 3; do
56+
yarn install --frozen-lockfile && break || sleep 10
57+
done
5258
5359
- name: Build browser extensions
5460
run: ./scripts/build-extensions.sh
@@ -82,7 +88,10 @@ jobs:
8288
java-version: '17'
8389

8490
- name: Install dependencies
85-
run: yarn install --frozen-lockfile
91+
run: |
92+
for i in 1 2 3; do
93+
yarn install --frozen-lockfile && break || sleep 10
94+
done
8695
8796
- name: Build mobile applications
8897
run: ./scripts/build-mobile.sh
@@ -115,7 +124,10 @@ jobs:
115124
sudo apt-get install -y libnss3-dev libatk-bridge2.0-dev libdrm2 libxkbcommon-dev libgtk-3-dev libgbm-dev libasound2-dev rpm fakeroot dpkg
116125
117126
- name: Install dependencies
118-
run: yarn install --frozen-lockfile
127+
run: |
128+
for i in 1 2 3; do
129+
yarn install --frozen-lockfile && break || sleep 10
130+
done
119131
120132
- name: Build web application
121133
run: yarn build
@@ -145,7 +157,11 @@ jobs:
145157
cache: 'yarn'
146158

147159
- name: Install dependencies
148-
run: yarn install --frozen-lockfile
160+
shell: bash
161+
run: |
162+
for i in 1 2 3; do
163+
yarn install --frozen-lockfile && break || sleep 10
164+
done
149165
150166
- name: Build web application
151167
run: yarn build
@@ -176,7 +192,10 @@ jobs:
176192
cache: 'yarn'
177193

178194
- name: Install dependencies
179-
run: yarn install --frozen-lockfile
195+
run: |
196+
for i in 1 2 3; do
197+
yarn install --frozen-lockfile && break || sleep 10
198+
done
180199
181200
- name: Build web application
182201
run: yarn build
@@ -212,7 +231,10 @@ jobs:
212231
java-version: '17'
213232

214233
- name: Install dependencies
215-
run: yarn install --frozen-lockfile
234+
run: |
235+
for i in 1 2 3; do
236+
yarn install --frozen-lockfile && break || sleep 10
237+
done
216238
217239
- name: Build all platforms
218240
run: ./scripts/build-all-platforms.sh
@@ -250,7 +272,10 @@ jobs:
250272
cache: 'yarn'
251273

252274
- name: Install dependencies
253-
run: yarn install --frozen-lockfile
275+
run: |
276+
for i in 1 2 3; do
277+
yarn install --frozen-lockfile && break || sleep 10
278+
done
254279
255280
- name: Run tests
256281
run: yarn test --watchAll=false --coverage

.github/workflows/build-android.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,10 @@ jobs:
3838
${{ runner.os }}-yarn-
3939
4040
- name: Install dependencies
41-
run: yarn install --frozen-lockfile
41+
run: |
42+
for i in 1 2 3; do
43+
yarn install --frozen-lockfile && break || sleep 10
44+
done
4245
4346
- name: Build web application
4447
run: yarn build

.github/workflows/build-linux-native.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,10 @@ jobs:
5959
alien
6060
6161
- name: Install dependencies
62-
run: yarn install --frozen-lockfile
62+
run: |
63+
for i in 1 2 3; do
64+
yarn install --frozen-lockfile && break || sleep 10
65+
done
6366
6467
- name: Build web application
6568
run: yarn build

.github/workflows/build-macos-native.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,14 @@ jobs:
4242
${{ runner.os }}-macos-native-
4343
${{ runner.os }}-yarn-
4444
45+
- name: Upgrade pip and setuptools
46+
run: python3 -m pip install --upgrade pip setuptools --break-system-packages
47+
4548
- name: Install dependencies
46-
run: yarn install --frozen-lockfile
49+
run: |
50+
for i in 1 2 3; do
51+
yarn install --frozen-lockfile && break || sleep 10
52+
done
4753
4854
- name: Build web application
4955
run: yarn build

.github/workflows/build-windows-native.yml

Lines changed: 26 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,11 @@ jobs:
4343
${{ runner.os }}-yarn-
4444
4545
- name: Install dependencies
46-
run: yarn install --frozen-lockfile
46+
shell: bash
47+
run: |
48+
for i in 1 2 3; do
49+
yarn install --frozen-lockfile && break || sleep 10
50+
done
4751
4852
- name: Build web application
4953
run: yarn build
@@ -77,29 +81,30 @@ jobs:
7781
$version = (Get-Content package.json | ConvertFrom-Json).version
7882
$timestamp = Get-Date -Format "yyyyMMdd-HHmmss"
7983
80-
# Create metadata file
81-
@"
82-
SVMSeek Wallet - Windows Native Build Artifacts
83-
===============================================
84-
Version: $version
85-
Build Date: $(Get-Date)
86-
Build System: Windows (GitHub Actions)
87-
Node Version: $(node --version)
84+
# Create metadata file using simple string concatenation
85+
$metadata = "SVMSeek Wallet - Windows Native Build Artifacts`n"
86+
$metadata += "===============================================`n"
87+
$metadata += "Version: $version`n"
88+
$metadata += "Build Date: $(Get-Date)`n"
89+
$metadata += "Build System: Windows (GitHub Actions)`n"
90+
$metadata += "Node Version: $(node --version)`n`n"
91+
$metadata += "Windows Native Packages:`n"
8892
89-
Windows Native Packages:
90-
$(Get-ChildItem -Recurse "native-builds/windows" -Include *.exe,*.msi | ForEach-Object {
91-
$size = [math]::Round($_.Length / 1MB, 2)
92-
"- $($_.Name): ${size}MB"
93-
})
93+
if (Test-Path "native-builds/windows") {
94+
Get-ChildItem -Recurse "native-builds/windows" -Include *.exe,*.msi | ForEach-Object {
95+
$size = [math]::Round($_.Length / 1MB, 2)
96+
$metadata += "- $($_.Name): ${size}MB`n"
97+
}
98+
}
9499
95-
Installation Instructions:
96-
1. NSIS Installer (.exe): Run and follow setup wizard
97-
2. Portable (.exe): Extract and run directly
98-
3. MSI Package (.msi): Use Windows Installer
100+
$metadata += "`nInstallation Instructions:`n"
101+
$metadata += "1. NSIS Installer (.exe): Run and follow setup wizard`n"
102+
$metadata += "2. Portable (.exe): Extract and run directly`n"
103+
$metadata += "3. MSI Package (.msi): Use Windows Installer`n`n"
104+
$metadata += "Distribution Ready: Yes`n"
105+
$metadata += "Digitally Signed: No (requires code signing certificate)`n"
99106
100-
Distribution Ready: Yes
101-
Digitally Signed: No (requires code signing certificate)
102-
"@ | Out-File -FilePath "native-builds/windows/windows-build-metadata.txt" -Encoding UTF8
107+
$metadata | Out-File -FilePath "native-builds/windows/windows-build-metadata.txt" -Encoding UTF8
103108
shell: powershell
104109

105110
- name: Upload Windows native artifacts

.github/workflows/realnet-tests.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,10 @@ jobs:
3838
${{ runner.os }}-yarn-
3939
4040
- name: Install dependencies
41-
run: yarn install --frozen-lockfile
41+
run: |
42+
for i in 1 2 3; do
43+
yarn install --frozen-lockfile && break || sleep 10
44+
done
4245
4346
- name: Build application
4447
run: yarn build

package.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,10 @@
44
"private": true,
55
"description": "SVMSeek Wallet - Secure Solana wallet for SPL tokens and DeFi applications",
66
"homepage": "https://svmseek.com",
7+
"author": {
8+
"name": "OpenSVM",
9+
"email": "[email protected]"
10+
},
711
"dependencies": {
812
"@coral-xyz/anchor": "^0.31.1",
913
"@emotion/react": "^11.14.0",

src/setupTests.js

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -60,17 +60,31 @@ global.URL.createObjectURL = jest.fn(() => 'blob:mock-url');
6060
global.URL.revokeObjectURL = jest.fn();
6161

6262
// Mock crypto libraries to avoid flakiness
63-
jest.mock('tweetnacl', () => ({
64-
secretbox: jest.fn((plaintext, nonce, key) => new Uint8Array(plaintext.length + 16)),
65-
secretbox_open: jest.fn((ciphertext, nonce, key) => new Uint8Array(ciphertext.length - 16)),
66-
randomBytes: jest.fn((length) => new Uint8Array(length)),
67-
}));
63+
jest.mock('tweetnacl', () => {
64+
const mockSecretbox = jest.fn((plaintext, nonce, key) => new Uint8Array(plaintext.length + 16));
65+
mockSecretbox.open = jest.fn((ciphertext, nonce, key) => new Uint8Array(ciphertext.length - 16));
66+
mockSecretbox.nonceLength = 24;
67+
68+
return {
69+
secretbox: mockSecretbox,
70+
randomBytes: jest.fn((length) => {
71+
const array = new Uint8Array(length);
72+
for (let i = 0; i < length; i++) {
73+
array[i] = Math.floor(Math.random() * 256);
74+
}
75+
return array;
76+
}),
77+
};
78+
});
6879

69-
jest.mock('argon2-wasm', () => ({
80+
jest.mock('argon2-browser', () => ({
7081
hash: jest.fn(() => Promise.resolve({
7182
hash: new Uint8Array(32),
7283
encoded: 'mock-encoded-hash'
7384
})),
85+
ArgonType: {
86+
Argon2id: 2,
87+
},
7488
}));
7589

7690
jest.mock('scrypt-js', () => jest.fn((password, salt, N, r, p, keylen, callback) => {

0 commit comments

Comments
 (0)