[PR #5370] [CLOSED] [rolldown bug]: Error: Panic in async function #5965

Closed
opened 2026-03-13 12:43:00 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/5370
Author: @himself65
Created: 10/16/2025
Status: Closed

Base: canaryHead: himself65/2025/10/16/BUG-2


📝 Commits (1)

📊 Changes

1 file changed (+41 additions, -23 deletions)

View changed files

📝 packages/better-auth/src/types/api.ts (+41 -23)

📄 Description

Summary by cubic

Fixes a rolldown build panic in async code by aligning getSession endpoint types with better-call. Makes getSession consistent across response and header modes.

  • Refactors

    • Switched InferSessionAPI to StrictEndpoint<P, O, R> and InputContext.
    • Introduced GetSessionFn with overloads for asResponse and returnHeaders.
    • Removed PrettifyDeep and updated helper import to ./helper.
  • Bug Fixes

    • Addresses BUG-2: resolved the panic by tightening endpoint typings and removing unsafe deep-prettify.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/5370 **Author:** [@himself65](https://github.com/himself65) **Created:** 10/16/2025 **Status:** ❌ Closed **Base:** `canary` ← **Head:** `himself65/2025/10/16/BUG-2` --- ### 📝 Commits (1) - [`26eb3db`](https://github.com/better-auth/better-auth/commit/26eb3dbd44cf6f08eb51bb135baa35794bb99658) WTF ### 📊 Changes **1 file changed** (+41 additions, -23 deletions) <details> <summary>View changed files</summary> 📝 `packages/better-auth/src/types/api.ts` (+41 -23) </details> ### 📄 Description <!-- This is an auto-generated description by cubic. --> ## Summary by cubic Fixes a rolldown build panic in async code by aligning getSession endpoint types with better-call. Makes getSession consistent across response and header modes. - **Refactors** - Switched InferSessionAPI to StrictEndpoint<P, O, R> and InputContext. - Introduced GetSessionFn with overloads for asResponse and returnHeaders. - Removed PrettifyDeep and updated helper import to ./helper. - **Bug Fixes** - Addresses BUG-2: resolved the panic by tightening endpoint typings and removing unsafe deep-prettify. <!-- End of auto-generated description by cubic. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-03-13 12:43:00 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#5965