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
14 changes: 10 additions & 4 deletions apps/docs/components/MDX/auth_error_codes_table.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ To supplement HTTP status codes, Supabase Auth returns a string error code which
| `email_provider_disabled` | Signups are disabled for email and password. |
| `flow_state_expired` | PKCE flow state to which the API request relates has expired. Ask the user to sign in again. |
| `flow_state_not_found` | PKCE flow state to which the API request relates no longer exists. Flow states expire after a while and are progressively cleaned up, which can cause this error. Retried requests can cause this error, as the previous request likely destroyed the flow state. Ask the user to sign in again. |
| `hook_payload_invalid_content_type` | Payload from Auth does not have a valid Content-Type header. |
| `hook_payload_over_size_limit` | Payload from Auth exceeds maximum size limit. |
| `hook_timeout` | Unable to reach hook within maximum time allocated. |
| `hook_timeout_after_retry` | Unable to reach hook after maximum number of retries. |
Expand All @@ -30,13 +31,15 @@ To supplement HTTP status codes, Supabase Auth returns a string error code which
| `mfa_factor_name_conflict` | MFA factors for a single user should not have the same friendly name. |
| `mfa_factor_not_found` | MFA factor no longer exists. |
| `mfa_ip_address_mismatch` | The enrollment process for MFA factors must begin and end with the same IP address. |
| `mfa_phone_enroll_not_enabled` | Enrollment of MFA Phone factors is disabled. |
| `mfa_phone_verify_not_enabled` | Login via Phone factors and verification of new Phone factors is disabled. |
| `mfa_totp_enroll_not_enabled` | Enrollment of MFA TOTP factors is disabled. |
| `mfa_totp_verify_not_enabled` | Login via TOTP factors and verification of new TOTP factors is disabled. |
| `mfa_verification_failed` | MFA challenge could not be verified -- wrong TOTP code. |
| `mfa_verification_rejected` | Further MFA verification is rejected. Only returned if the [MFA verification attempt hook](https://supabase.com/docs/guides/auth/auth-hooks?language=add-admin-role#hook-mfa-verification-attempt) returns a reject decision. |
| `mfa_verified_factor_exists` | Verified phone factor already exists for a user. Unenroll existing verified phone factor to continue. |
| `mfa_totp_enroll_disabled` | Enrollment of MFA TOTP factors is disabled. |
| `mfa_totp_verify_disabled` | Login via TOTP factors and verification of new TOTP factors is disabled. |
| `mfa_phone_enroll_disabled` | Enrollment of MFA Phone factors is disabled. |
| `mfa_phone_verify_disabled` | Login via Phone factors and verification of new Phone factors is disabled. |
| `mfa_web_authn_enroll_not_enabled` | Enrollment of MFA Web Authn factors is disabled. |
| `mfa_web_authn_verify_not_enabled` | Login via WebAuthn factors and verification of new WebAuthn factors is disabled. |
| `no_authorization` | This HTTP request requires an `Authorization` header, which is not provided. |
| `not_admin` | User accessing the API is not admin, i.e. the JWT does not contain a `role` claim that identifies them as an admin of the Auth server. |
| `oauth_provider_not_supported` | Using an OAuth provider which is disabled on the Auth server. |
Expand All @@ -52,6 +55,8 @@ To supplement HTTP status codes, Supabase Auth returns a string error code which
| `provider_email_needs_verification` | Not all OAuth providers verify their user's email address. Supabase Auth requires emails to be verified, so this error is sent out when a verification email is sent after completing the OAuth flow. |
| `reauthentication_needed` | A user needs to reauthenticate to change their password. Ask the user to reauthenticate by calling the `supabase.auth.reauthenticate()` API. |
| `reauthentication_not_valid` | Verifying a reauthentication failed, the code is incorrect. Ask the user to enter a new code. |
| `refresh_token_not_found` | Session containing the refresh token not found. |
| `refresh_token_already_used` | Refresh token has been revoked and falls outside the refresh token reuse interval. See the [documentation on sessions](https://supabase.com/docs/guides/auth/sessions) for further information. |
| `request_timeout` | Processing the request took too long. Retry the request. |
| `same_password` | A user that is updating their password must use a different password than the one currently used. |
| `saml_assertion_no_email` | SAML assertion (user information) was received after sign in, but no email address was found in it, which is required. Check the provider's attribute mapping and/or configuration. |
Expand All @@ -63,6 +68,7 @@ To supplement HTTP status codes, Supabase Auth returns a string error code which
| `saml_provider_disabled` | Using [Enterprise SSO with SAML 2.0](https://supabase.com/docs/guides/auth/enterprise-sso/auth-sso-saml) is not enabled on the Auth server. |
| `saml_relay_state_expired` | SAML relay state is an object that tracks the progress of a `supabase.auth.signInWithSSO()` request. The SAML identity provider should respond after a fixed amount of time, after which this error is shown. Ask the user to sign in again. |
| `saml_relay_state_not_found` | SAML relay states are progressively cleaned up after they expire, which can cause this error. Ask the user to sign in again. |
| `session_expired` | Session to which the API request relates has expired. This can occur if an inactivity timeout is configured, or the session entry has exceeded the configured timebox value. See the [documentation on sessions](https://supabase.com/docs/guides/auth/sessions) for more information. |
| `session_not_found` | Session to which the API request relates no longer exists. This can occur if the user has signed out, or the session entry in the database was deleted in some other way. |
| `signup_disabled` | Sign ups (new account creation) are disabled on the server. |
| `single_identity_not_deletable` | Every user must have at least one identity attached to it, so deleting (unlinking) an identity is not allowed if it's the only one for the user. |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ import { useBranchResetMutation } from 'data/branches/branch-reset-mutation'
import { useBranchUpdateMutation } from 'data/branches/branch-update-mutation'
import type { Branch } from 'data/branches/branches-query'
import { useCheckPermissions } from 'hooks/misc/useCheckPermissions'
import { useFlag } from 'hooks/ui/useFlag'
import {
Badge,
Button,
Expand Down Expand Up @@ -115,14 +114,6 @@ export const BranchRow = ({
const createPullRequestURL =
generateCreatePullRequestURL?.(branch.git_branch) ?? 'https://github.com'

const branchingWorkflowLogsEnabled = useFlag('branchingWorkflowLogs')

const shouldRenderGitHubLogsButton =
!branchingWorkflowLogsEnabled &&
branch.pr_number !== undefined &&
branch.latest_check_run_id !== undefined
const checkRunLogsURL = `https://github.com/${repo}/pull/${branch.pr_number}/checks?check_run_id=${branch.latest_check_run_id}`

const { ref, inView } = useInView()
const { data } = useBranchQuery(
{ projectRef, id: branch.id },
Expand Down Expand Up @@ -234,7 +225,7 @@ export const BranchRow = ({
View Repository
</Link>
</Button>
{branchingWorkflowLogsEnabled && <WorkflowLogs projectRef={branch.project_ref} />}
<WorkflowLogs projectRef={branch.project_ref} />
<DropdownMenu modal={false}>
<DropdownMenuTrigger asChild>
<Button type="text" icon={<MoreVertical />} className="px-1" />
Expand Down Expand Up @@ -281,17 +272,7 @@ export const BranchRow = ({
</Button>
</div>
)}

{shouldRenderGitHubLogsButton ? (
<Button asChild type="default" iconRight={<ExternalLink size={14} />}>
<Link passHref target="_blank" rel="noreferrer" href={checkRunLogsURL}>
View Logs
</Link>
</Button>
) : (
<WorkflowLogs projectRef={branch.project_ref} />
)}

<WorkflowLogs projectRef={branch.project_ref} />
<DropdownMenu modal={false}>
<DropdownMenuTrigger asChild>
<Button type="text" icon={<MoreVertical />} className="px-1" />
Expand Down
10 changes: 8 additions & 2 deletions apps/studio/components/layouts/ProjectLayout/ProjectLayout.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import Head from 'next/head'
import { useRouter } from 'next/router'
import { forwardRef, Fragment, PropsWithChildren, ReactNode, useEffect } from 'react'
import { forwardRef, Fragment, PropsWithChildren, ReactNode, useEffect, useState } from 'react'

import { useParams } from 'common'
import ProjectAPIDocs from 'components/interfaces/ProjectAPIDocs/ProjectAPIDocs'
Expand Down Expand Up @@ -110,6 +110,12 @@ const ProjectLayout = forwardRef<HTMLDivElement, PropsWithChildren<ProjectLayout
router.pathname === '/project/[ref]' || router.pathname.includes('/project/[ref]/settings')
const showPausedState = isPaused && !ignorePausedState

const [isClient, setIsClient] = useState(false)

useEffect(() => {
setIsClient(true)
}, [])

useEffect(() => {
const handler = (e: KeyboardEvent) => {
if (e.metaKey && e.code === 'KeyI' && !e.altKey && !e.shiftKey) {
Expand Down Expand Up @@ -195,7 +201,7 @@ const ProjectLayout = forwardRef<HTMLDivElement, PropsWithChildren<ProjectLayout
)}
</main>
</ResizablePanel>
{aiAssistantPanel.open && (
{isClient && aiAssistantPanel.open && (
<>
<ResizableHandle />
<ResizablePanel
Expand Down
Loading
Loading