vercel

ModuleNotFoundError no module named 'data', Vercel python

ModuleNotFoundError no module named 'data', Vercel python Question: I have data (data.py) which is file that contins constants. When I try to import the file which is in the same folder ‘/api’ it says that no module named ‘data’ I have it the same casing, and i dont understand what could be the reason why …

Total answers: 2

Unable to connect to sshuttle

Unable to connect to sshuttle Question: I am getting the following error when I try running sshuttle using sshuttle -r hopper 10.0.0.0/8. I am on [email protected] and [email protected] Tried reinstalling sshuttle, python, switching network, but no luck. arjun@arjun ~ % sshuttle -r hopper 10.10.0.0/16 -v Starting sshuttle proxy (version 1.1.1). c : Starting firewall manager …

Total answers: 1

How to properly use Regex in CORS Middleware for FastAPI?

How to properly use Regex in CORS Middleware for FastAPI? Question: I have an app that uses a FastAPI backend and a Next.js frontend. In development and on production with stable origins, I am able to use the CORSMiddleware with no issues. However, I have deployed the Next.js frontend with Vercel, and want to take …

Total answers: 3

Python Serverless Function Vercel – Next.js

Python Serverless Function Vercel – Next.js Question: I found out that I could use Python to create a serverless function inside a Next.js project. Once deployed to Vercel, it will get converted into a serverless function. I went through the docs and found a simple example that outputs the date: from http.server import BaseHTTPRequestHandler from …

Total answers: 1

Combine multiple routes into one serverless function in Vercel using Python?

Combine multiple routes into one serverless function in Vercel using Python? Question: I currently have a Nextjs app with python api backend. The problem I am running into is that Vercel has a limit of 24 Serverless functions and they seem to recommend that one should combine your serverless functions to "optimize" your functions and …

Total answers: 1