ERR_TOO_MANY_REDIRECTS
francisc0arauj0
TRIALOP

2 years ago

I have no errors in the log, my code has no errors and neither do the variables

46 Replies

2 years ago

Are you using cloudflare?


francisc0arauj0
TRIALOP

2 years ago

b51594de-0245-4106-b7d1-e8d8412a6c2d


francisc0arauj0
TRIALOP

2 years ago

no


coderjoshdk
TRIAL

2 years ago

Or django? And doing some type of http redirect stuff for "security"


francisc0arauj0
TRIALOP

2 years ago

yes


francisc0arauj0
TRIALOP

2 years ago

django + prisma


coderjoshdk
TRIAL

2 years ago

Ah yea, check if you have a line like SECURE_SSL_REDIRECT = True. If so, get rid of it


coderjoshdk
TRIAL

2 years ago

And if it isn't the django app but the prisma stuff, it is likely a similar reason. At least, that is what got me once


francisc0arauj0
TRIALOP

2 years ago

no


francisc0arauj0
TRIALOP

2 years ago

I don't have anything like that


francisc0arauj0
TRIALOP

2 years ago

I'm also using socket


coderjoshdk
TRIAL

2 years ago

Well, obligatory; does it work properly locally?


francisc0arauj0
TRIALOP

2 years ago

yes


francisc0arauj0
TRIALOP

2 years ago

0 errors

1257747808606224400


coderjoshdk
TRIAL

2 years ago

Well 100% something is trying to do some level of redirect. Railway handles https for you. So if you have some redirect into https type stuff, it causes errors. So, I would start by looking for that type of logic and disabling


francisc0arauj0
TRIALOP

2 years ago

and the http://localhost:5756/ have ERRCONNECTIONREFUSED


francisc0arauj0
TRIALOP

2 years ago

hmm


francisc0arauj0
TRIALOP

2 years ago

I do not have anything


2 years ago

next frontend with a django backend?


francisc0arauj0
TRIALOP

2 years ago

yes


2 years ago

are you getting the redirects from the frontend or backend domain?


coderjoshdk
TRIAL

2 years ago

?? Well, this isn't a real site. This is localhost. Not something for you to interact with (unless deployed locally). So what do you mean?


francisc0arauj0
TRIALOP

2 years ago

back-end


2 years ago

send your settings.py please


francisc0arauj0
TRIALOP

2 years ago

no bro is not djando 🤣 sry


francisc0arauj0
TRIALOP

2 years ago

is mongodb


francisc0arauj0
TRIALOP

2 years ago

mongodb + prisma


2 years ago

so you arent using django anywhere??


francisc0arauj0
TRIALOP

2 years ago

no no


2 years ago

how do you mistakenly think you are using django?


francisc0arauj0
TRIALOP

2 years ago

I got confused sorry, I have a project in django but it's not this one


francisc0arauj0
TRIALOP

2 years ago

I don't know what it could be


2 years ago

please take joshie's advice


francisc0arauj0
TRIALOP

2 years ago

I'll spend the day on this, I did this almost the whole day before coming here


2 years ago

something in your code is sending a redirect


2 years ago

try having it trust the proxy headers


francisc0arauj0
TRIALOP

2 years ago

like api?


francisc0arauj0
TRIALOP

2 years ago

I think I already know what it is


coderjoshdk
TRIAL

2 years ago

NextJS does have middleware builtin. It is likely doing something for you that is causing the redirects. It is mostly DX streamlined for Vercel. But it can be used on other platforms. Just not the typical happy path


francisc0arauj0
TRIALOP

2 years ago

I'm not using theirs middleware


francisc0arauj0
TRIALOP

2 years ago

I found the problem


2 years ago

do tell


francisc0arauj0
TRIALOP

2 years ago

If the error is there, I'm using a function that is deprecated


francisc0arauj0
TRIALOP

2 years ago

I'm using clerk middleware


2 years ago

joshie was right then, it was middleware doing something undesirable, in the future please don't be so dismissive when community members try to help you


francisc0arauj0
TRIALOP

2 years ago

Sorry bro, I've been trying to resolve this for hours


Loading...