FG

All Issues

24,993 verified issues

🌐 Web & Full-StackVercel
Fresh11 months ago

[NEXT-1143] Dev mode slow compilation

⚠️ this original post has been edited by @timneutkens to reflect this comment ⚠️ Changes in the past week I've been investigating this over the past week. Made a bunch of changes, some make a small impact, some make a large impact. Here's a list: Affects all applications https://github.com/vercel/next.js/pull/50745 https://github.com/vercel/next.js/pull/50795 -- If you don't have a favicon.ico https://github.com/vercel/next.js/pull/50379 -- If you have both `pages` and `app` and you're only working on `app` it will no longer compile the runtime for `pages`. Note: this shifts the compilation of the runtime to when you first open a page Might not affect your app https://github.com/vercel/next.js/pull/50792 -- This one I've only been able to reproduce on the Vercel website in development, it might make your compilation a lot faster (i.e. 50% faster for Vercel's website) but in most cases it likely won't affect your application. You can try them using `npm install next@canary`. Help Investigate In order to help me investigate this I'll ideally need an application that can be run, if you can't provide that (I understand if you can't) please provide the `.next/trace` file. If possible follow these steps which would give me the best picture to investigate: `npm install next@canary` (use the package manager you're using) -- We want to make sure you're using the very latest version of Next.js which includes the fixes mentioned earlier. `rm -rf .next` start dev

Confidence77%
77%
Verified Fix Available
1 fix9 verified
🌐 Web & Full-Stack
Freshabout 1 year ago

Upgrade tool can't resolve paths on Windows

What version of Tailwind CSS are you using? For example: v3.4.15 What build tool (or framework if it abstracts the build tool) are you using? For example: postcss-cli 8.4.41, Vite 5.4.8, autoprefixer 10.4.20 What version of Node.js are you using? For example: v20.15.0 What browser are you using? For example: ARC What operating system are you using? For example: Windows Reproduction URL Execute the `npx @tailwindcss/upgrade@next` command Describe your issue After im trying to execute the command, i get this error: [code block]

Confidence77%
77%
Verified Fix Available
1 fix4 verified
🤖 AI & LLMs
Freshabout 2 years ago

Parallel index builds for HNSW

Hi all, support for in-memory, parallel index builds is now available in the hnsw-fast-build branch :tada: A few benchmarks from my local machine with the SIFT 1M dataset (128 dimensions): code version | processes | build time --- | --- | --- 0.5.1 | 1 | 415 sec master | 1 | 309 sec branch | 2 | 184 sec branch | 4 | 107 sec branch | 8 | 83 sec A few useful settings are: [code block] For a high number of workers, you may also need to increase `max_parallel_workers` (default is 8). Please test it out (in a non-production environment) and share any feedback. Aiming for a release (0.5.2) at the end of January if all goes well.

Confidence77%
77%
Verified Fix Available
1 fix4 verified
🌐 Web & Full-StackVercel
Freshover 2 years ago

Error 'Failed to fetch `Noto Sans JP` from Google Fonts.'

Verify canary release - [X] I verified that the issue exists in the latest Next.js canary release Provide environment information Operating System: Platform: linux Arch: x64 Version: Ubuntu 20.04.0 LTS Fri Jan 20 2023 09:56:57 GMT+0000 (Greenwich Mean Time) Binaries: Node: 16.14.2 npm: 7.17.0 Yarn: 1.22.19 pnpm: 7.13.6 Relevant packages: next: 13.1.3 eslint-config-next: N/A react: 18.2.0 react-dom: 18.2.0 Which area(s) of Next.js are affected? (leave empty if unsure) Font optimization (@next/font) Link to the code that reproduces this issue https://stackblitz.com/edit/nextjs-qcjltu?file=app%2Fpage.js,package.json To Reproduce To reproduce, run `npm run build`. Describe the Bug Font input is [code block] results in [code block] Possibly related to https://github.com/vercel/next.js/pull/44594 and https://github.com/vercel/next.js/commit/5f2c9d0b301588cec60c3bfb6b36cb7ece787659 Expected Behavior Compiles successfully.

Confidence77%
77%
Verified Fix Available
1 fix6 verified
🗄️ DatabasesVercel
Fresh7 days ago

"FATAL: sorry, too many clients already" postgres error in develop mode on

Bug description I use prisma inside an api-route of https://nextjs.org/ (this is by the way an awesome setup) for a graphql-api. After some time you will get this error: [code block] I guess the hot-reloading or refreshing of nextjs might mess with the connection-pool of prisma. I verified that the prisma-client that is used in the route is a singleton: [code block] How to reproduce Steps to reproduce the behavior: 1. create a file pages/api/graphql.ts inside that, use prisma client 2. it probably needs some code changes that result in a rebuilding of this file /api/graphql.ts or its imports 3. at some point you should get the error Expected behavior should not throw this error i guess? Prisma information Environment & setup - OS: macOS - Database: [PostgreSQL - Prisma version: prisma2@2.0.0-preview024, binary version: 377df4fe30aa992f13f1ba152cf83d5770bdbc85 - Node.js version: v12.13.1 EDIT: Solution as many still comment on this thead, I though it would be good to pin the solution here. This issue happens because many platforms as nextjs (and probably nestjs as well) do hot reload of parts of your code. Usually you initialize the PrismaClient once in your application (as a singleton). But hot reload results in multiple initializations of this PrismaClient so the solution is to kindof "cache" the client in a global variable. See this comment: https://github.com/prisma/prisma/issues/1983#issuecomment-620621213

Confidence77%
77%
Candidate Fix
1 fix
🗄️ Databases
Fresh7 days ago

[BUG]: TypeError: Cannot read properties of undefined (reading 'compositePrimaryKeys')

What version of `drizzle-orm` are you using? 0.30.10 What version of `drizzle-kit` are you using? 0.21.2 Describe the Bug if I have tables with no composite primary keys(table => pk: primaryKey(....) , then i can change my column names and do whatever i want with no issue in push. issues arises when: changing column names, adding new columns, tables to schema that any table has composite primary key. if schema already exists in database and i want to add composite primary key. everytime before pushing new version of the schema, i have to drop all my tables in db. otherwise `drizzle-kit push` command keeps failing with this error. Expected behavior _No response_ Environment & setup next.js 14 app router application

Confidence77%
77%
Candidate Fix
1 fix
🌐 Web & Full-Stack
Fresh7 days ago

Import does not work like documented

I'm trying to include a component. In the comments of the "bootstrap file" [code block] is used. This is not a funcionality provided by tailwind or is it? I expect that I have to add [code block] to my workflow. Am I wrong or are the docs wrong here? If i import a file like dokumented i get an error. [code block] And here the error: [code block] What am I doing wrong?

Confidence77%
77%
Candidate Fix
1 fix
📱 Mobile & Cross-Platform
Fresh7 days ago

Command PhaseScriptExecution failed with a nonzero exit code - Error when Archive on Xcode 14.3

Description Hi Guys, I'm trying to perform an archive using 0.71.5 but I'm getting an error. The error occurs in Build phase "[CP] Embed Pods Frameworks", when he runs the script with: "${PODS_ROOT}/Target Support Files/Pods-MyApp/Pods-MyApp-frameworks.sh" React Native Version 0.71.5 Output of `npx react-native info` System: OS: macOS 13.3 CPU: (8) arm64 Apple M1 Memory: 79.22 MB / 16.00 GB Shell: 5.9 - /bin/zsh Binaries: Node: 16.13.1 - ~/.nvm/versions/node/v16.13.1/bin/node Yarn: 1.22.17 - ~/.nvm/versions/node/v16.13.1/bin/yarn npm: 8.1.2 - ~/.nvm/versions/node/v16.13.1/bin/npm Watchman: 2022.11.14.00 - /opt/homebrew/bin/watchman Managers: CocoaPods: 1.11.3 - /Users/leonardo.felipe/.rbenv/shims/pod SDKs: iOS SDK: Platforms: DriverKit 22.4, iOS 16.4, macOS 13.3, tvOS 16.4, watchOS 9.4 Android SDK: API Levels: 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33 Build Tools: 29.0.2, 30.0.2, 30.0.3, 31.0.0, 32.0.0, 32.1.0, 33.0.0 System Images: android-32 | Google APIs ARM 64 v8a, android-33 | Google APIs ARM 64 v8a Android NDK: 22.1.7171670 IDEs: Android Studio: 2021.2 AI-212.5712.43.2112.8609683 Xcode: 14.3/14E222b - /usr/bin/xcodebuild Languages: Java: 11.0.14.1 - /usr/bin/javac npmPackages: @react-native-community/cli: Not Found react: 18.2.0 => 18.2.0 react-native: 0.71.5 => 0.71.5 react-native-macos: Not Found npmGlobalPackages: react-native: Not Fou

Confidence77%
77%
Candidate Fix
1 fix
🗄️ Databases
Fresh7 days ago

[BUG]: pgEnum -> type "xxx" already exists during migration

What version of `drizzle-orm` are you using? "^0.35.3" What version of `drizzle-kit` are you using? "^0.26.2" Describe the Bug Hi In a nextjs app with "drizzle-orm/pg-core" i have this enum [code block] And when I migrate my schemas first time all is ok, but after a new migration i got the error ❌ Migration failed PostgresError: type "xxx" already exists at ErrorResponse (D:\Work\webapps\damhub\node_modules\postgres\cjs\src\connection.js:788:26) at handle (D:\Work\webapps\damhub\node_modules\postgres\cjs\src\connection.js:474:6) at Socket.data (D:\Work\webapps\damhub\node_modules\postgres\cjs\src\connection.js:315:9) at Socket.emit (node:events:519:28) at addChunk (node:internal/streams/readable:559:12) at readableAddChunkPushByteMode (node:internal/streams/readable:510:3) at Readable.push (node:internal/streams/readable:390:5) If I do a db: push all works fine. regards Expected behavior I expected a success migration after new migration. Not only the first time Environment & setup This is my package { "name": "xxx", "version": "0.1.0", "private": true, "scripts": { "dev": "next dev --turbo", "build": "next build", "start": "next start", "lint": "next lint", "db:generate": "drizzle-kit generate", "db:migrate": "tsx lib/db/migrate.ts", "db:drop": "drizzle-kit drop", "db:pull": "drizzle-kit introspect", "db:push": "drizzle-kit push", "db:studio": "drizzle-kit studio", "db:check": "d

Confidence77%
77%
Candidate Fix
1 fix
🛠️ Developer ToolsMicrosoft
Fresh7 days ago

[BUG] Getting constant `FetchError...reason: Socket timeout` when installing packages

Current Behavior: When trying to install packages, without a previous cache, we get constant timeouts when trying to fetch packages, both locally and in a CI environment. The package that fails is always different, so there isn't a specific package causing the issue. Stack trace: [code block] Tried using the fetch-retries, fetch-retry-mintimeout, and fetch-retry-maxtimeout options, but didn't seem to have any effect. Expected Behavior: Install packages without timing out. Steps To Reproduce: Using a project with workspaces (~6425 packages) No cache available Run `npm ci` Environment: OS: Mac OS 11.2.3 or Windows 10 Node: 14.15.4 npm: 7.9.0

Confidence77%
77%
Candidate Fix
1 fix
🌐 Web & Full-Stack
Fresh7 days ago

npx tailwindcss init not working

Describe the problem: Using tailwind in post-css compatibility mode I've got tailwind 2.0 installed and the build process runs, however now I want to set up a config file so I can add custom colors etcetera. I run the `npx tailwindcss init` command and it fails with this output. [code block] I can see autoprefix in both package.json `"autoprefixer": "^9.8.6",` and the autoprefixer folder in the node_modules folder. Not sure how to resolve this, please advise.

Confidence77%
77%
Candidate Fix
1 fix
☁️ Cloud & DevOpsDocker
Fresh7 days ago

It should allow extended services to define links

Hi! I'm in a use-case where I have a basic docker-compose.yml file that defines a php service talking to a db service. Now I added a second file named "dev.yml" where I extend all the services from docker-compose.yml and I add a `volumes` key to the php service. This scenario does not work (`services with 'links' cannot be extended`) and I don't think the docs are quite clear on this behavor. (EDIT: it's clear but stay with me :)) Docs says that `links` won't be copied: [code block] What I'd like is to not being forced to create a prod.yml file, just to add a `links` section. I'm perfectly OK with the idea of always defining links locally (and not merging the array like it's done with `expose` f.e). But I think the base file can also be considered a perfectly valid leaf. I'd like my docker-compose.yml file to be the standard, and dev.yml to add some volumes (and define links locally in it). I hope I'm clear :) I think there is no reasion why I can't define links in the base file. It would be great if I just had to redefine them if needed in any other file that extends it.

Confidence77%
77%
Candidate Fix
1 fix
☁️ Cloud & DevOpsAmazon
Freshover 3 years ago

Launch Config copy funtion

Would like to have the ability to copy launch configs from the CLI like we now can in the console. It would make it nice to script against when all you need to do is swap the AMI.

Confidence77%
77%
Unresolved
0 fixes
🔌 APIs & SDKs
Freshalmost 10 years ago

Can't get a .post with 'Content-Type': 'multipart/form-data' to work

I've spent a few hours today trying to get a post request to work with a few parameters and a file that I need to upload. I was able to make it work with pure javascript and XMLHttpRequest but it doesn't work with Axios. What am I doing wrong? Here's the code that works using XMLHttpRequest: [code block] What would be the 'Axios' version of that? Here's one of my tries (the simple one): [code block] Thank you! And thanks for your great work with Axios!

Confidence77%
77%
Verified Fix Available
1 fix3 verified
🌐 Web & Full-Stack
Freshover 1 year ago

List All Routes in express app

Hi! I've been fighting this for a bit, but I'm trying to gather a list of all of the endpoints in our express applications. I've tried 'express-list-router' and the code below, but none give the full paths of the endpoint and the allowed methods to use them. I've read the documentation, but can't seem to find the properties/methods to access this information. Thank you in advance for your time and assistance!

Confidence77%
77%
Verified Fix Available
1 fix10 verified
🛠️ Developer Tools
Freshalmost 9 years ago

Space after function keyword - MOVED to #3847!

I apologize in advance if this has been discussed before (I did a quick search and didn't find it). One of the things that popped out when running prettier over our codebase was spacing on anonymous functions. For example, prettier converts this: [code block] into this: [code block] While this pattern is becoming less common for us (we'd probably use an arrow function here now), we still have several cases of this. The lack of space after the function keyword just doesn't read right for me. It probably has to do with one or more of the following: 1. It looks more like a function invocation than a declaration. 2. The lack of space after a keyword is odd. For prior art: - https://github.com/airbnb/javascript#functions--signature-spacing - http://eslint.org/docs/rules/space-before-function-paren - http://eslint.org/docs/rules/space-after-keywords Are there strong feelings on this one?

Confidence77%
77%
Verified Fix Available
1 fix7 verified
🌐 Web & Full-StackVercel
Freshabout 2 years ago

Fast Refresh had to perform a full reload

Verify canary release - [X] I verified that the issue exists in the latest Next.js canary release Provide environment information What browser are you using? (if relevant) Google Chrome 102.0.5005.115 How are you deploying your application? (if relevant) next run dev Describe the Bug When data is sent to the service and a context that handles the entire application is updated, the system does not change the page but reloads itself, deleting everything in the provider (react) Expected Behavior I hope you go to the next screen which is indicated by the router.push(urlRelative, url) Link to reproduction /None To Reproduce Is project in development <sub>NEXT-1355</sub>

Confidence77%
77%
Verified Fix Available
1 fix7 verified
☁️ Cloud & DevOpsMicrosoft
Freshover 4 years ago

[Self-hosted] job abandoned

Describe the bug Since yesterday, CI jobs keep failing. I tried to re-run the previously passed changes and still failed. Also tried the latest runner (actions-runner-linux-x64-2.285.1.tar.gz) but still the same. The CI job runs a script (customized action script). It takes about 15 mins to finish. The job actually finished correctly as I can see from my host log but CI reports error like: The self-hosted runner: xxx lost communication with the server. Verify the machine is running and has a healthy network connection. Anything in your workflow that terminates the runner process, starves it for CPU/Memory, or blocks its network access can cause this error. journalctl shows: Job build_ubuntu completed with result: Abandoned The "raw log" in web UI shows: 2021-12-10T04:55:30.4780954Z ##[error]The operation was canceled. 2021-12-10T04:55:30.4933658Z Post job cleanup. Please advise how should I diagnose the issue? OS: Ubuntu 18.04 Runner: actions-runner-linux-x64-2.285.1.tar.gz

Confidence77%
77%
Verified Fix Available
1 fix4 verified
📡 Networking
Freshover 11 years ago

No way to grab POST body before sending request?

Hi all, I need to generate a signature based on the POST body. If I put the proxy.web on the request end method it simply does not work. Has anyone accomplished reading the POST body?

Confidence77%
77%
Verified Fix Available
1 fix4 verified
🔌 APIs & SDKsGoogle
Freshover 5 years ago

auth: Failed to execute 'transaction' on 'IDBDatabase'

[REQUIRED] Describe your environment Operating System version: Android/Windows Browser version: Chrome Firebase SDK version: 6.2.2 Firebase Product: auth [REQUIRED] Describe the problem Migrating this issue on behalf of @alexplumb from #1533. We've seen this indexdb issue in Firestore on Safari 12.2 (both in #1533 and the canonical one for that issue, #1670). However, Alex doesn't seem to have persistence enabled, so firestore shouldn't even be looking at indexdb. The name of the indexdb in question is "firebaseLocalStorageDb" which looks like it's the auth db (https://github.com/firebase/firebase-js-sdk/blob/master/packages/auth/src/storage/indexeddb.js#L191) Steps to reproduce: Happens inconsistently; unable to reproduce. :(

Confidence77%
77%
Verified Fix Available
1 fix6 verified
← PrevPage 59 of 1250Next →