9,805 questions
Score of -1
1 answer
108 views
Next.js NEXT_PUBLIC env vars not loading in browser — Supabase getting 403
I'm building a Next.js app with Supabase. My .env.local has:
NEXT_PUBLIC_SUPABASE_URL=https://rgfqebiuevnwfetdfaoh.supabase.co
NEXT_PUBLIC_SUPABASE_ANON_KEY=eyJ...
lib/supabase.ts:
import { ...
Score of 0
3 answers
261 views
Fetch function await for an answer but before PHP produces a different output [closed]
JavaScript calls the PHP routine:
async function genPdf() {
try {
const response = await fetch('genPdf.php', {
method: 'POST',
headers: {
'Content-...
Score of 0
0 answers
103 views
Fetching another container from nextjs middleware in docker
I have a docker structure which contains backend (binded on localhost:3001) and frontend (binded on localhost:3002). In my frontend which uses NextJS framework, I have a middleware that check if the ...
Advice
0
votes
1
replies
37
views
fetch data from grafana using tempo / loki
I want to use the logs and traces stored in Grafana for another use case. Can we easily fetch all this data using Tempo or Loki? . if there any solution , please tell me . i think to use a python ...
Score of 0
0 answers
63 views
How to implement polling in React without overlapping async fetch requests?
I am trying to implement a custom React hook that fetches data initially and then refetches it at a fixed interval (polling).
My problem is that using `setInterval` causes overlapping `fetch` requests ...
Score of 0
1 answer
201 views
Git .lock file not found
I am trying to do a git fetch (or any other Git command) and I get the following error:
fatal: Unable to create '/path/to/repo/.git/refs/remotes/origin/main.lock': File exists.
There are no .lock ...
Best practices
3
votes
4
replies
233
views
Fastest way to read 10M DB rows in Python?
I’m trying to efficiently read about 10 million rows (single column) from a database table in Python and I’m not sure if my current approach is reasonable or if I’m missing some optimizations.
...
Score of 0
1 answer
354 views
Next.js (App Router) – SSR with Axios & Cookies, CSR vs SSR API calls, and State Management Confusion
’m building a flight booking system in Next.js (App Router) and I want to use Server-Side Rendering (SSR). However, I’m running into some issues with API calls, cookies, and state management.
What I’...
Score of 4
1 answer
98 views
A wait-free consensus algorithm for three processes, with a swap object and the fetch-and-increment object together in one atomic step
We know that a swap object consists of a shared register and supports a swap operation between the shared register and any local register, which atomically exchanges the values of the two registers.
A ...
Score of 1
1 answer
140 views
fetching a mjpeg video stream on iOS throws "TypeError: Load failed" error
I have a webserver which delivers a small React SPA, in which a mjpeg video stream (streamed by the same webserver) is embedded.
Since the stream can only be viewed with authorization, the stream is ...
Score of 0
1 answer
149 views
React native ImageBackground unknown image format
I'm trying to use a remote image in a React Native ImageBackground component, but I'm getting an error saying Unknown image format.
I'm not sure why it's not loading properly.
What causes this error ...
Score of 0
2 answers
783 views
Why no CORS error when curl rest API request [duplicate]
I have to call a rest api. When the call is made with frontend javascript fetch request from within a web page then I get back a CORS error form the browser. But when the same request is made from ...
Score of 0
1 answer
77 views
route handler only recieve POST requests
I have table component that provides functionality to add, edit and delete materials, but only add material works, deleting or editing material doesn't work, the method in the route handler doesn't ...
Score of 1
1 answer
83 views
Tryed to fetch and get error with CORS or empty response
The problem is that when requesting from the frontend to the server, it returns either an error or an empty string (just empty) to the console if you disable Cors in fetch(mode: "no-cors"). ...
Score of 0
1 answer
564 views
How to redirect to a URL from the Location header in a 302 response using Axios?
the request returns a 302 with a URL in the Location header. The browser automatically makes a GET request to that URL, but I need to redirect the user to the page with that URL.
const res = axios.get(...