-
Notifications
You must be signed in to change notification settings - Fork 25
Description
Describe the bug
After upgrading to version surrealdb.net v0.6.0 and v0.7.0 to add compatibility with SurrealDB 2.x, my application works fine when run from Visual Studio without AOT (using runtime). However, when publishing the application with AOT, it throws the following error:
Steps to reproduce
Steps for reproducing are given as follows :
Note:
- You will need a linux-x64 instance to reproduce the issue. Also, the project link provided below is an exact replica of the
- Surrealdb.NET repository's SurrealDb.Examples.Todo.Aot project.
Step 1: Clone the Repository
Clone the repository https://github.com/mandars-icpl/sdb-aot-test.git. This application is an exact copy of the SurrealDB Todo API AOT.
git clone https://github.com/mandars-icpl/sdb-aot-test.gitStep 2: Build the Solution
Run the following command to build the solution:
dotnet build SurrealAotTest.slnStep 3: Publish the AOT Build
Run the following command to publish the AOT build:
dotnet publish SurrealAotTest/SurrealAotTest.csproj -r linux-x64 -c ReleaseStep 4: Run the Binary
Navigate to the SurrealAotTest/bin/Release/net9.0/linux-x64/native directory and run the binary. Make sure the ConnectionString in the appsettings.json file is correctly configured.
Run the following commands:
cd SurrealAotTest/bin/Release/net9.0/linux-x64/native
./SurrealAotTestRight after running the application you will see that the applicatoin couldn't start due to the CBOR error.
Expected behaviour
Expected behavior was that the default should be inserted in to DB.
SurrealDB version
v2.0.4
Package version(s)
The packages used in the above-mentioned project are as follows:
Contact Details
Is there an existing issue for this?
- I have searched the existing issues
Code of Conduct
- I agree to follow this project's Code of Conduct


