C# conflict between Godot.Collection and System.Collection

Hello everybody.
I encounter a real problem :frowning:

I want to have a link on my MangoDB Database on MongoDB Atlas.

I followed a lot of different tutorial and i finaly found how to connect a c# programm to MongoDB :

But the problem is when i want to do it with Godot.

The line 161 crash.
After few test, the conclusion is the next :

Godot.Collection is in conflict with System.Collection

So, maybe do anybody know a solution to acces my database without using System.Collection ?

It is 2 days that i work on this problem and i don’t found a solution… i hope that a person have a solution ! :slight_smile:

Hi @Xemnai_Sekai, and welcome to the forum,

Could you try to explicitly define the type of collection variable is, for example:

IMongoCollection<BsonDocument> collection = database.GetCollection<BsonDocument>("user");

Also, would you be able to provide the full error stack strace? Trying to figure out whether this issue is related to MongoDB.Driver namespace or just Godot with System namespace issues.

Regards,
Wan.

1 Like