mirror of
https://github.com/stack-auth/stack.git
synced 2026-06-13 21:01:21 +08:00
Merge dev into update-oauth-docs
This commit is contained in:
commit
e75af8ed98
@ -1,5 +1,13 @@
|
||||
# @stackframe/stack-backend
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Various changes
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/stack-backend",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"clean": "rimraf src/generated && rimraf .next && rimraf node_modules",
|
||||
|
||||
@ -78,34 +78,42 @@ async function _sendEmailWithoutRetries(options: SendEmailOptions): Promise<Resu
|
||||
if (options.emailConfig.type === 'shared' && emailableApiKey) {
|
||||
await traceSpan('verifying email addresses with Emailable', async () => {
|
||||
toArray = (await Promise.all(toArray.map(async (to) => {
|
||||
const emailableResponseResult = await Result.retry(async (attempt) => {
|
||||
const res = await fetch(`https://api.emailable.com/v1/verify?email=${encodeURIComponent(options.to as string)}&api_key=${emailableApiKey}`);
|
||||
if (res.status === 249) {
|
||||
const text = await res.text();
|
||||
console.log('Emailable is taking longer than expected, retrying...', text, { to: options.to });
|
||||
return Result.error(new Error("Emailable API returned a 249 error for " + options.to + ". This means it takes some more time to verify the email address. Response body: " + text));
|
||||
try {
|
||||
const emailableResponseResult = await Result.retry(async (attempt) => {
|
||||
const res = await fetch(`https://api.emailable.com/v1/verify?email=${encodeURIComponent(options.to as string)}&api_key=${emailableApiKey}`);
|
||||
if (res.status === 249) {
|
||||
const text = await res.text();
|
||||
console.log('Emailable is taking longer than expected, retrying...', text, { to: options.to });
|
||||
return Result.error(new Error("Emailable API returned a 249 error for " + options.to + ". This means it takes some more time to verify the email address. Response body: " + text));
|
||||
}
|
||||
return Result.ok(res);
|
||||
}, 4, { exponentialDelayBase: 4000 });
|
||||
if (emailableResponseResult.status === 'error') {
|
||||
throw new StackAssertionError("Timed out while verifying email address with Emailable", {
|
||||
to: options.to,
|
||||
emailableResponseResult,
|
||||
});
|
||||
}
|
||||
return Result.ok(res);
|
||||
}, 4, { exponentialDelayBase: 4000 });
|
||||
if (emailableResponseResult.status === 'error') {
|
||||
captureError("emailable-api-timeout", emailableResponseResult.error);
|
||||
const emailableResponse = emailableResponseResult.data;
|
||||
if (!emailableResponse.ok) {
|
||||
throw new StackAssertionError("Failed to verify email address with Emailable", {
|
||||
to: options.to,
|
||||
emailableResponse,
|
||||
emailableResponseText: await emailableResponse.text(),
|
||||
});
|
||||
}
|
||||
const json = await emailableResponse.json();
|
||||
console.log('emailableResponse', json);
|
||||
if (json.state === 'undeliverable' || json.disposable) {
|
||||
console.log('email not deliverable', to, json);
|
||||
return null;
|
||||
}
|
||||
return to;
|
||||
} catch (error) {
|
||||
// if something goes wrong with the Emailable API (eg. 500, ran out of credits, etc.), we just send the email anyway
|
||||
captureError("emailable-api-error", error);
|
||||
return to;
|
||||
}
|
||||
const emailableResponse = emailableResponseResult.data;
|
||||
if (!emailableResponse.ok) {
|
||||
throw new StackAssertionError("Failed to verify email address with Emailable", {
|
||||
to: options.to,
|
||||
emailableResponse,
|
||||
emailableResponseText: await emailableResponse.text(),
|
||||
});
|
||||
}
|
||||
const json = await emailableResponse.json();
|
||||
console.log('emailableResponse', json);
|
||||
if (json.state === 'undeliverable' || json.disposable) {
|
||||
console.log('email not deliverable', to, json);
|
||||
return null;
|
||||
}
|
||||
return to;
|
||||
}))).filter((to): to is string => to !== null);
|
||||
});
|
||||
}
|
||||
|
||||
@ -1,5 +1,15 @@
|
||||
# @stackframe/stack-dashboard
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Various changes
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
- @stackframe/stack@2.8.28
|
||||
- @stackframe/stack-ui@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/stack-dashboard",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"clean": "rimraf .next && rimraf node_modules",
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# @stackframe/dev-launchpad
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Various changes
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/dev-launchpad",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "serve -p 8100 -s public",
|
||||
|
||||
@ -1,5 +1,14 @@
|
||||
# @stackframe/e2e-tests
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Various changes
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
- @stackframe/js@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/e2e-tests",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
import { wait } from "@stackframe/stack-shared/dist/utils/promises";
|
||||
import { it } from "../../../../../helpers";
|
||||
import { Auth, ContactChannels, backendContext, niceBackendFetch } from "../../../../backend-helpers";
|
||||
|
||||
@ -35,6 +36,7 @@ it("can't send a verification code while logged out", async ({ expect }) => {
|
||||
it("should send a verification code per e-mail", async ({ expect }) => {
|
||||
await Auth.Password.signUpWithEmail();
|
||||
await ContactChannels.sendVerificationCode();
|
||||
await wait(1000);
|
||||
expect(await backendContext.value.mailbox.fetchMessages({ noBody: true })).toMatchInlineSnapshot(`
|
||||
[
|
||||
MailboxMessage {
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
# @stackframe/mock-oauth-server
|
||||
|
||||
## 2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
## 2.8.26
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/mock-oauth-server",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
|
||||
@ -1,5 +1,14 @@
|
||||
# @stackframe/stack-docs
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Various changes
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
- @stackframe/stack@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/stack-docs",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
"private": true,
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# @stackframe/example-cjs-test
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- @stackframe/stack@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/example-cjs-test",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "next dev --port 8110",
|
||||
|
||||
@ -1,5 +1,14 @@
|
||||
# @stackframe/example-demo-app
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
- @stackframe/stack@2.8.28
|
||||
- @stackframe/stack-ui@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/example-demo-app",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"description": "",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
|
||||
@ -1,5 +1,14 @@
|
||||
# @stackframe/docs-examples
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
- @stackframe/stack@2.8.28
|
||||
- @stackframe/stack-ui@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/docs-examples",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"description": "",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# @stackframe/e-commerce-demo
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- @stackframe/stack@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/e-commerce-demo",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "next dev --port 8111",
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# @stackframe/js-example
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- @stackframe/js@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/js-example",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"description": "",
|
||||
"main": "index.js",
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# @stackframe/example-middleware-demo
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- @stackframe/stack@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/example-middleware-demo",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "next dev --port 8112",
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# @stackframe/example-partial-prerendering
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- @stackframe/stack@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/example-partial-prerendering",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "next dev --port 8109",
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# react-example
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- @stackframe/react@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "react-example",
|
||||
"private": true,
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"type": "module",
|
||||
"scripts": {
|
||||
"dev": "vite --force --port 8120",
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# @stackframe/example-supabase
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- @stackframe/stack@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/example-supabase",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"private": true,
|
||||
"scripts": {
|
||||
"dev": "next dev --turbo --port 8115",
|
||||
|
||||
@ -1,5 +1,12 @@
|
||||
# @stackframe/init-stack
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/init-stack",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"description": "The setup wizard for Stack. https://stack-auth.com",
|
||||
"main": "dist/index.js",
|
||||
"type": "module",
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
{
|
||||
"//": "THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY",
|
||||
"name": "@stackframe/js",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"sideEffects": false,
|
||||
"main": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
{
|
||||
"//": "THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY",
|
||||
"name": "@stackframe/react",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"sideEffects": false,
|
||||
"main": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
# @stackframe/stack-sc
|
||||
|
||||
## 2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
## 2.8.26
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/stack-sc",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"exports": {
|
||||
"./force-react-server": {
|
||||
"types": "./dist/index.react-server.d.ts",
|
||||
|
||||
@ -1,5 +1,11 @@
|
||||
# @stackframe/stack-shared
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Various changes
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/stack-shared",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"scripts": {
|
||||
"build": "rimraf dist && tsup-node",
|
||||
"typecheck": "tsc --noEmit",
|
||||
|
||||
@ -1,5 +1,12 @@
|
||||
# @stackframe/stack-ui
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@stackframe/stack-ui",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"main": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
"sideEffects": false,
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
{
|
||||
"//": "THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY",
|
||||
"name": "@stackframe/stack",
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"sideEffects": false,
|
||||
"main": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
|
||||
@ -1,5 +1,15 @@
|
||||
# @stackframe/stack
|
||||
|
||||
## 2.8.28
|
||||
|
||||
### Patch Changes
|
||||
|
||||
- Various changes
|
||||
- Updated dependencies
|
||||
- @stackframe/stack-shared@2.8.28
|
||||
- @stackframe/stack-ui@2.8.28
|
||||
- @stackframe/stack-sc@2.8.28
|
||||
|
||||
## 2.8.27
|
||||
|
||||
### Patch Changes
|
||||
|
||||
@ -11,7 +11,7 @@
|
||||
|
||||
"//": "NEXT_LINE_PLATFORM template",
|
||||
"private": true,
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"sideEffects": false,
|
||||
"main": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
"//": "THIS FILE IS AUTO-GENERATED FROM TEMPLATE. DO NOT EDIT IT DIRECTLY",
|
||||
"name": "@stackframe/template",
|
||||
"private": true,
|
||||
"version": "2.8.27",
|
||||
"version": "2.8.28",
|
||||
"sideEffects": false,
|
||||
"main": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
|
||||
Loading…
Reference in New Issue
Block a user