Clerk wrongly redirects to `/factor-one` route
oferitz opened this issue · 1 comments
oferitz commented
Preliminary Checks
- I have reviewed the documentation: https://clerk.com/docs
- I have searched for existing issues: https://github.com/clerk/javascript/issues
- I have not already reached out to Clerk support via email or Discord (if you have, no need to open an issue here)
- This issue is not a question, general help request, or anything other than a bug report directly related to Clerk. Please ask questions in our Discord community: https://clerk.com/discord.
Reproduction
Publishable key
pk_test_Z3JhdGVmdWwtYmxvd2Zpc2gtMjQuY2xlcmsuYWNjb3VudHMuZGV2JA
Description
My Clerk account configured as follows
Reproduction:
- User invited to organization
- User signed up with email and password
- User assigned to organization and successfully signed in with email and password
- User Logged out.
Now this is where things starting to get messy:
- After logout user is again in the sign in page and no password input (is that intentional?)
- User entering his email again and clicking "CONTINUE"
- User is being redirected to
/factor-one
route which from my understanding is related to MFA which is turned off in the settings as you can see above.
What is going on here?
Environment
System:
OS: macOS 14.4.1
CPU: (11) arm64 Apple M3 Pro
Memory: 1.64 GB / 36.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.11.1 - /usr/local/bin/node
npm: 10.2.4 - /usr/local/bin/npm
pnpm: 8.15.5 - /opt/homebrew/bin/pnpm
Browsers:
Chrome: 123.0.6312.122
Safari: 17.4.1
npmPackages:
@biomejs/biome: 1.6.3 => 1.6.3
@clerk/clerk-sdk-node: 4.13.14 => 4.13.14
@clerk/nextjs: 4.29.12 => 4.29.12
@clerk/themes: 1.7.10 => 1.7.10
@clerk/types: 3.63.0 => 3.63.0
@datadog/browser-rum: 5.14.0 => 5.14.0
@hookform/resolvers: 3.3.4 => 3.3.4
@nextui-org/react: 2.2.10 => 2.2.10
@playwright/test: 1.42.1 => 1.42.1
@splitsoftware/splitio-react: 1.11.1 => 1.11.1
@tanstack/react-query: 5.28.14 => 5.28.14
@tanstack/react-table: 8.15.3 => 8.15.3
@testing-library/react: 14.2.2 => 14.2.2
@types/node: 20 => 20.11.30
@types/react: 18 => 18.2.73
@types/react-dom: 18 => 18.2.24
@vitejs/plugin-react: 4.2.1 => 4.2.1
autoprefixer: 10.4.18 => 10.4.18
axios: 1.6.8 => 1.6.8
clsx: 2.1.0 => 2.1.0
dayjs: 1.11.10 => 1.11.10
fast-deep-equal: 3.1.3 => 3.1.3
framer-motion: 11.0.24 => 11.0.24
jotai: 2.8.0 => 2.8.0
jsdom: 24.0.0 => 24.0.0
lucide-react: 0.364.0 => 0.364.0
next: 14.1.4 => 14.1.4
next-themes: 0.2.1 => 0.2.1
nextjs-toploader: 1.6.11 => 1.6.11
orval: 6.26.0 => 6.26.0
postcss: 8 => 8.4.38
prettier: 3.2.5 => 3.2.5
react: 18 => 18.2.0
react-confetti: 6.1.0 => 6.1.0
react-dom: 18 => 18.2.0
react-hook-form: 7.51.2 => 7.51.2
reactflow: 11.11.0 => 11.11.0
recharts: 2.12.3 => 2.12.3
sonner: 1.4.41 => 1.4.41
tailwind-merge: 2.2.2 => 2.2.2
tailwindcss: 3.4.3 => 3.4.3
typescript: 5 => 5.4.2
vite-tsconfig-paths: 4.3.2 => 4.3.2
vitest: 1.4.0 => 1.4.0
zod: 3.22.4 => 3.22.4
oferitz commented
OK, so apparently, this is not an issue per se but rather a lack of documentation. This is just with Next, where you need to use their optional catch-all for sign-up and sign-in, e.g., app/sign-in/[[...sign]]/page.tsx. The [[...sign-in]]
captures the /factor-one
or other routes for the component.
My sign-in page was the root page and therefore didn't catch the factor-one
route.
You can close the issue, but I'm leaving it open as a reminder that you might want to consider better documentation around this.