Skip to content

release: 0.6.0 #44

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

Merged
Changes from 1 commit
Commits
Show all changes
46 commits
Select commit Hold shift + click to select a range
2f70ad9
fix(internal): return in castToError instead of throwing (#43)
stainless-app[bot] Feb 22, 2025
bd9e536
chore(internal): remove unnecessary todo (#45)
stainless-app[bot] Feb 22, 2025
6450e47
docs: update URLs from stainlessapi.com to stainless.com (#46)
stainless-app[bot] Feb 28, 2025
cd888bc
chore(client): only accept standard types for file uploads (#47)
stainless-app[bot] Mar 4, 2025
c1031bd
chore(internal): fix tests failing on node v18 (#48)
stainless-app[bot] Mar 4, 2025
41da630
chore(internal): constrain synckit dev dependency (#49)
stainless-app[bot] Mar 4, 2025
1262a7b
fix(client): fix TypeError with undefined File (#50)
stainless-app[bot] Mar 4, 2025
e1e0fb5
fix(internal): clean up undefined File test (#51)
stainless-app[bot] Mar 4, 2025
2eded46
fix(tests): manually reset node:buffer File (#52)
stainless-app[bot] Mar 4, 2025
54a7db8
chore(types): improved go to definition on fetchOptions (#53)
stainless-app[bot] Mar 5, 2025
25092c5
chore(docs): improve docs for withResponse/asResponse (#54)
stainless-app[bot] Mar 5, 2025
71a1bef
chore(internal): codegen related update (#55)
stainless-app[bot] Mar 11, 2025
6431dc9
chore(internal): remove extra empty newlines (#56)
stainless-app[bot] Mar 14, 2025
23166e6
fix(exports): ensure resource imports don't require /index (#57)
stainless-app[bot] Mar 14, 2025
716b94c
fix(internal): add mts file + crypto shim types (#58)
stainless-app[bot] Mar 15, 2025
51d47fd
chore(internal): minor client file refactoring (#59)
stainless-app[bot] Mar 19, 2025
0049aac
chore(exports): cleaner resource index imports (#60)
stainless-app[bot] Mar 20, 2025
a9df2c1
chore(exports): stop using path fallbacks (#61)
stainless-app[bot] Mar 20, 2025
b79e1f2
codegen metadata
stainless-app[bot] Mar 27, 2025
e4008c3
chore(client): move misc public files to new `core/` directory, depre…
stainless-app[bot] Mar 27, 2025
dab2433
fix(client): send `X-Stainless-Timeout` in seconds (#63)
stainless-app[bot] Apr 3, 2025
38e00c9
chore(internal): add aliases for Record and Array (#64)
stainless-app[bot] Apr 3, 2025
62c4790
chore(client): make jsonl methods consistent with other streaming met…
stainless-app[bot] Apr 4, 2025
8aa007b
fix(api): improve type resolution when importing as a package (#66)
stainless-app[bot] Apr 4, 2025
65686bf
fix(mcp): remove unused tools.ts (#67)
stainless-app[bot] Apr 5, 2025
3ced793
fix(client): send all configured auth headers (#68)
stainless-app[bot] Apr 8, 2025
af4a60a
chore(tests): improve enum examples (#69)
stainless-app[bot] Apr 9, 2025
dbd4446
chore(internal): upload builds and expand CI branch coverage
stainless-app[bot] Apr 10, 2025
726127a
chore(internal): improve node 18 shims
stainless-app[bot] Apr 10, 2025
e8cd029
chore(internal): reduce CI branch coverage
stainless-app[bot] Apr 10, 2025
702757c
fix(internal): fix file uploads in node 18 jest
stainless-app[bot] Apr 11, 2025
e3c6fb8
chore(client): minor internal fixes
stainless-app[bot] Apr 15, 2025
b3a1e96
chore(perf): faster base64 decoding
stainless-app[bot] Apr 23, 2025
d78258c
chore(ci): add timeout thresholds for CI jobs
stainless-app[bot] Apr 23, 2025
c60c38f
chore(internal): codegen related update
stainless-app[bot] Apr 24, 2025
678516c
chore(ci): only use depot for staging repos
stainless-app[bot] Apr 24, 2025
eafa310
chore(internal): refactor utils
stainless-app[bot] Apr 29, 2025
fea4ecb
docs(readme): fix typo
stainless-app[bot] May 1, 2025
e94c558
chore(internal): codegen related update
stainless-app[bot] May 3, 2025
b52aa07
chore(internal): share typescript helpers
stainless-app[bot] May 3, 2025
f50f5ad
feat(api): manual updates
stainless-app[bot] May 7, 2025
f0edc96
feat(api): manual updates
stainless-app[bot] May 9, 2025
77b6f44
feat(api): manual updates
stainless-app[bot] May 9, 2025
078548f
feat(api): manual updates
stainless-app[bot] Jun 3, 2025
3c6b1d3
feat(api): manual updates
stainless-app[bot] Jun 6, 2025
3d0b02e
release: 0.6.0
stainless-app[bot] Jun 6, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
chore(perf): faster base64 decoding
  • Loading branch information
stainless-app[bot] committed Apr 23, 2025
commit b3a1e96efe94fd726a49c050eb1a6e0069171983
14 changes: 8 additions & 6 deletions src/internal/utils/base64.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,17 @@ export const toBase64 = (data: string | Uint8Array | null | undefined): string =

export const fromBase64 = (str: string): Uint8Array => {
if (typeof (globalThis as any).Buffer !== 'undefined') {
return new Uint8Array((globalThis as any).Buffer.from(str, 'base64'));
const buf = (globalThis as any).Buffer.from(str, 'base64');
return new Uint8Array(buf.buffer, buf.byteOffset, buf.byteLength);
}

if (typeof atob !== 'undefined') {
return new Uint8Array(
atob(str)
.split('')
.map((c) => c.charCodeAt(0)),
);
const bstr = atob(str);
const buf = new Uint8Array(bstr.length);
for (let i = 0; i < bstr.length; i++) {
buf[i] = bstr.charCodeAt(i);
}
return buf;
}

throw new GitpodError('Cannot decode base64 string; Expected `Buffer` or `atob` to be defined');
Expand Down