Skip to content

Commit 3e67ef0

Browse files
committed
test: attempting fixes for both mac and win
1 parent ca9da77 commit 3e67ef0

File tree

3 files changed

+11
-4
lines changed

3 files changed

+11
-4
lines changed

benches/index.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,11 @@ import url from 'node:url';
77
import si from 'systeminformation';
88
import { fsWalk, resultsPath, suitesPath } from './utils.js';
99

10-
// Adding for more context
11-
Error.stackTraceLimit = 100;
12-
1310
const dirname = url.fileURLToPath(new URL('.', import.meta.url));
11+
console.log('dirname', dirname);
1412

1513
async function main(): Promise<void> {
14+
console.log('mkdir', path.join(dirname, 'results'));
1615
await fs.promises.mkdir(path.join(dirname, 'results'), { recursive: true });
1716
// Running all suites
1817
for await (const suitePath of fsWalk(suitesPath)) {
@@ -49,6 +48,7 @@ async function main(): Promise<void> {
4948
osInfo: 'platform, distro, release, kernel, arch',
5049
system: 'model, manufacturer',
5150
});
51+
console.log('write file', path.join(dirname, 'results', 'system.json'))
5252
await fs.promises.writeFile(
5353
path.join(dirname, 'results', 'system.json'),
5454
JSON.stringify(systemData, null, 2),

scripts/brew-install.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,5 @@ brew link --overwrite rustup-init
2121
# However rustup provides specific versions
2222
# Here we provide both toolchains
2323
rustup-init --default-toolchain 1.68.2 -y
24-
rustup add x86_64-apple-darwin aarch64-apple-darwin
24+
rustup add x86_64-apple-darwin
25+
rustup add aarch64-apple-darwin

src/native/quiche.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,11 +66,13 @@ function requireBinding(targets: Array<string>): Quiche {
6666
);
6767
for (const prebuildTarget of prebuildTargets) {
6868
try {
69+
console.log('trying path', prebuildTarget);
6970
return require(prebuildTarget);
7071
} catch (e) {
7172
if (e.code !== 'MODULE_NOT_FOUND') throw e;
7273
}
7374
try {
75+
console.log('trying path', url.pathToFileURL(prebuildTarget).href);
7476
return require(url.pathToFileURL(prebuildTarget).href);
7577
} catch (e) {
7678
if (e.code !== 'MODULE_NOT_FOUND') throw e;
@@ -79,11 +81,13 @@ function requireBinding(targets: Array<string>): Quiche {
7981
const npmTargets = targets.map((target) => `@matrixai/quic-${target}`);
8082
for (const npmTarget of npmTargets) {
8183
try {
84+
console.log('trying path', npmTarget);
8285
return require(npmTarget);
8386
} catch (e) {
8487
if (e.code !== 'MODULE_NOT_FOUND') throw e;
8588
}
8689
try {
90+
console.log('trying path', url.pathToFileURL(npmTarget).href);
8791
return require(url.pathToFileURL(npmTarget).href);
8892
} catch (e) {
8993
if (e.code !== 'MODULE_NOT_FOUND') throw e;
@@ -161,6 +165,8 @@ switch (process.platform) {
161165
);
162166
}
163167

168+
console.log('dirname', dirname);
169+
164170
export default nativeBinding;
165171

166172
export type { Quiche };

0 commit comments

Comments
 (0)