Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ The three packages (`pgstencil`, `@pgstencil/auth`, `@pgstencil/stripe`) share o

## Unreleased

Nothing yet.
### Changed

- **`@pgstencil/auth` moves its exact Better Auth pin from 1.7.18 to 1.7.28**, which changes an application's lockfile and any dependency disclosure it publishes. Better Auth's own fixes in that range change what an application can observe: sending a new email OTP replaces the earlier code for that address instead of keeping it; deleting a user, `/revoke-session` and revoking all of a user's sessions now answer an error, `FAILED_TO_DELETE_USER` for a delete, where they reported success while the row or the cached sessions survived; and `user.delete.before` runs before the session and account deletes. An application that hooks user deletion or revokes sessions should check that it handles the new errors. Better Auth draws its random IDs in a different order, so an application that snapshots IDs under a seeded `RandomSource` sees them change once.

## 0.5.1 (2026-11-10)

Expand Down
2 changes: 1 addition & 1 deletion examples/better-auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"@hono/node-server": "2.1.11",
"@pgstencil/auth": "workspace:*",
"@pgstencil/stripe": "workspace:*",
"better-auth": "1.7.27",
"better-auth": "1.7.28",
"hono": "^4.13.7",
"kysely": "^0.29.5",
"pg": "^8.16.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"./better-auth-workers": "./src/better-auth-workers.ts"
},
"dependencies": {
"better-auth": "1.7.27",
"better-auth": "1.7.28",
"jose": "^6.2.18"
},
"peerDependencies": {
Expand Down
94 changes: 47 additions & 47 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tests/integration/snapshots/better-auth-cookies.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[
"__Host-pgstencil.session_token=znQJVUNBKgzMDfXmgy4tNwbzdAxy8Zpo.zBzOyU8x%2BWdTnRtM0x1jxEZDwz5qsEsXwqiYn3HRJMk%3D; Max-Age=86400; Path=/; HttpOnly; Secure; SameSite=Lax"
"__Host-pgstencil.session_token=WUE21FXrpzK25M6JkIkC2CnTS34plZ2u.PPhMXVYFn51UTB58RoFRU9ySvJEx%2BT6ZkKEUvcAiXho%3D; Max-Age=86400; Path=/; HttpOnly; Secure; SameSite=Lax"
]
6 changes: 3 additions & 3 deletions tests/integration/snapshots/better-auth-session.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
"createdAt": "2020-01-01T00:00:00.000Z",
"emailAuthenticated": true,
"expiresAt": "2020-01-02T00:00:00.000Z",
"id": "Z4QlCqqJmzirhpnjxhm1hzgQNDhFSWGL",
"id": "znQJVUNBKgzMDfXmgy4tNwbzdAxy8Zpo",
"ipAddress": "127.0.0.1",
"singleSession": false,
"token": "znQJVUNBKgzMDfXmgy4tNwbzdAxy8Zpo",
"token": "WUE21FXrpzK25M6JkIkC2CnTS34plZ2u",
"updatedAt": "2020-01-01T00:00:00.000Z",
"userAgent": "",
"userId": "WUE21FXrpzK25M6JkIkC2CnTS34plZ2u"
"userId": "bwvVXqVLKBczH9YszivbMD7xZs8efFOk"
}
]
4 changes: 2 additions & 2 deletions tests/integration/snapshots/billing/status.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
"cancel_at_period_end": false,
"end_reason": null,
"ended_at": null,
"id": "sub_w7C3rfCJSeBMAUHt",
"owner_id": "jqA6VlbZ1K4GrKS9aUQe7FgrckZrZA0M",
"id": "sub_MCk-RqE3hPYeCa-c",
"owner_id": "OHwuerzNiiwOkmtWXqazhH1xgT4hc1Vt",
"period_end": "2020-01-15T00:00:00.000Z",
"price_id": "price_dev_yearly",
"started_at": "2020-01-01T00:00:00.000Z",
Expand Down
18 changes: 9 additions & 9 deletions tests/integration/snapshots/billing/stripe-requests.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,31 +2,31 @@
{
"body": {
"email": "alice@example.test",
"metadata[pgstencil_owner]": "jqA6VlbZ1K4GrKS9aUQe7FgrckZrZA0M"
"metadata[pgstencil_owner]": "OHwuerzNiiwOkmtWXqazhH1xgT4hc1Vt"
},
"key": "D_OgPdV19cIvkrF1ykesk_OrFCxiC7p0MCk-RqE3hPY",
"key": "gH2lSz6u_itOGqkZ5v9DPPBuO_QCW9_7IX6ga3z7OHs",
"method": "POST",
"path": "/v1/customers"
},
{
"body": {
"allowed_payment_method_types[0]": "card",
"cancel_url": "<origin>/billing",
"client_reference_id": "jqA6VlbZ1K4GrKS9aUQe7FgrckZrZA0M",
"customer": "cus_HgmvnMSvObCu4iIM",
"client_reference_id": "OHwuerzNiiwOkmtWXqazhH1xgT4hc1Vt",
"customer": "cus_0nmnsfOSj-MgCIoi",
"expires_at": "1577840400",
"line_items[0][price]": "price_dev_yearly",
"line_items[0][quantity]": "1",
"metadata[pgstencil_operation]": "R8dOwvjxBK18jKWxM-4hcWYzE7JQT1pi-ds2_vipnBg",
"metadata[pgstencil_operation]": "3TN5eLl6ck0OQ41_uzAJdDkTgfYP86A91XX1wi-SsXU",
"mode": "subscription",
"payment_method_collection": "always",
"subscription_data[metadata][pgstencil_operation]": "R8dOwvjxBK18jKWxM-4hcWYzE7JQT1pi-ds2_vipnBg",
"subscription_data[metadata][pgstencil_owner]": "jqA6VlbZ1K4GrKS9aUQe7FgrckZrZA0M",
"subscription_data[metadata][pgstencil_operation]": "3TN5eLl6ck0OQ41_uzAJdDkTgfYP86A91XX1wi-SsXU",
"subscription_data[metadata][pgstencil_owner]": "OHwuerzNiiwOkmtWXqazhH1xgT4hc1Vt",
"subscription_data[trial_period_days]": "14",
"subscription_data[trial_settings][end_behavior][missing_payment_method]": "cancel",
"success_url": "<origin>/billing?checkout=R8dOwvjxBK18jKWxM-4hcWYzE7JQT1pi-ds2_vipnBg"
"success_url": "<origin>/billing?checkout=3TN5eLl6ck0OQ41_uzAJdDkTgfYP86A91XX1wi-SsXU"
},
"key": "R8dOwvjxBK18jKWxM-4hcWYzE7JQT1pi-ds2_vipnBg",
"key": "3TN5eLl6ck0OQ41_uzAJdDkTgfYP86A91XX1wi-SsXU",
"method": "POST",
"path": "/v1/checkout/sessions"
}
Expand Down