thread 'tokio-runtime-worker' panicked at 'called `Option::unwrap()`
See original GitHub issueBug description
When adding many to many relationships, I get this error when running Prisma client. This happens even when running prisma studio
thread 'tokio-runtime-worker' panicked at 'called `Option::unwrap()` on a `None` value', query-engine/connectors/mongodb-query-connector/src/root_queries/read.rs:106:74
How to reproduce
- Create a many to many models
- Run
prisma studio
- Go to model
- See error
Expected behavior
No response
Prisma information
generator client {
provider = "prisma-client-js"
previewFeatures = ["mongodb"]
binaryTargets = ["native", "rhel-openssl-1.0.x"]
}
model Organisation {
id String @id @default(dbgenerated()) @map("_id") @db.ObjectId
name String
activityGroups ActivityGroup[]
}
model ActivityGroup {
id String @id @default(dbgenerated()) @map("_id") @db.ObjectId
name String
organisations Organisation[]
}
prisma.organisation.findMany({
take: 100,
skip: 0,
select: {
id: true,
name: true,
activityGroups: true,
}
})
Environment & setup
- OS: Mac OS
- Database: MongoDB
- Node.js version: 14.17.6
Prisma Version
3.2.1
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (4 by maintainers)
Top Results From Across the Web
Thread 'tokio-runtime-worker' panicked at 'thread 'called ...
Hello, I made a tool with Rust and I use tokio::spawn to use multiple worker in my tool. The issue I have is...
Read more >thread 'tokio-runtime-worker' panicked at 'called `Result ...
authenticator 4.1.4 from flathub is crashing on startup. It crashes in the same way even if all I do is run --version or...
Read more >Panicked at 'called `Option::unwrap()` on a `None` value ...
Hi! I'm currently porting the Lox language from Crafting Interpreters , but I've been stuck for a while in an annoying bug.
Read more >libpnet error: thread 'main' panicked at 'called `Option::unwrap ...
It seems that adding tcp_header.set_options() results in a panic. thread 'main' panicked at 'called `Option::unwrap()` on a `None` value', ...
Read more >Builder in tokio::runtime - Rust - Docs.rs
... Runtime 's thread pool. The default name fn is || "tokio-runtime-worker".into() . ... ("thread unparking"); }) .build(); runtime.unwrap().block_on(async ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I encountered the same error at
query-engine/core/src/query_document/parser.rs:250:87
In my case I was trying to create a record with a 22 decimal integer for a column with type
Int
. Changing that column and the value to a string fixed the issue for me.3.7.0
16.11.1
Oh my bad. I actually encountered this on the latest version but then tried previous versions back to 3.2 to see if it was a recent thing.