R
Railway•17mo ago
Pythonic Shit

I can't even describe the error

i am hosting an api on my website hcn1.net and using a reverse proxy system the api start acting so strange with the reverse proxy when i access https://hcn1.net/api/v1/shortner it redirects me to my project website just try to access the link when i use python to request this link it raise ConnectionAborted Error i redeployed both the reverse proxy (caddy) and my api somehow it doesn't work and i don't want to access through the project link and also another error on the API when i try to reach api/v1/user; it doesn't output the same as api/v1/user/ lmfao
23 Replies
Percy
Percy•17mo ago
Project ID: 7fefcee9-cd96-4f28-a13f-bb39de672eb4
Pythonic Shit
Pythonic ShitOP•17mo ago
7fefcee9-cd96-4f28-a13f-bb39de672eb4
Pythonic Shit
Pythonic ShitOP•17mo ago
Pythonic Shit
Pythonic ShitOP•17mo ago
caddy config tho Brody my brother
Brody
Brody•17mo ago
when i access https://hcn1.net/api/v1/shortner it redirects me to my project website
that would be your app sending a redirect
error on the API when i try to reach api/v1/user; it doesn't output the same as api/v1/user/
/api/v1/user and /api/v1/user/ are not the same paths, youll want to setup some type of redirect trailing slash middleware
Pythonic Shit
Pythonic ShitOP•17mo ago
what app would redirect me there ? i don't understand ur answer
Brody
Brody•17mo ago
what app would redirect me there ?
your python app
Pythonic Shit
Pythonic ShitOP•17mo ago
yes I am using revese proxy brody
Brody
Brody•17mo ago
i can see that, and this looks like issues with your app not caddy
Pythonic Shit
Pythonic ShitOP•17mo ago
Idk man i couldnt figure it out I can show you my get request handler For /shortner Even tho I use same syntax with my whole api How is this any diffrent
Brody
Brody•17mo ago
this has nothing to do with how you're making the request, you need to figure out where that redirect is coming from
Pythonic Shit
Pythonic ShitOP•17mo ago
Theorically. I cam use burp suite to figure that out I will try
Brody
Brody•17mo ago
good luck
Pythonic Shit
Pythonic ShitOP•17mo ago
Tnx brody i found the issue brody
Pythonic Shit
Pythonic ShitOP•17mo ago
Pythonic Shit
Pythonic ShitOP•17mo ago
look it used to be like this
Pythonic Shit
Pythonic ShitOP•17mo ago
and now like this
Pythonic Shit
Pythonic ShitOP•17mo ago
🧢
Brody
Brody•17mo ago
glad youve solved it
Pythonic Shit
Pythonic ShitOP•17mo ago
7 am here 🥹
Brody
Brody•17mo ago
bed time
Pythonic Shit
Pythonic ShitOP•17mo ago
true goodnight broody
Brody
Brody•17mo ago
night night
Want results from more Discord servers?
Add your server