Skip to content

No deserialization found for type RuntimeSettings #432

Closed

Description

@Shubhamdsingh

Shubhams-MacBook-Air:serverpod_demo_server shubhamsingh$ dart bin/main.dart
SERVERPOD version: 0.9.20 mode: development time: 2022-12-06 05:25:55.398510Z
2022-12-06 05:25:56.127243Z Failed to connect to database.
FormatException: No deserialization found for type RuntimeSettings
#0 SerializationManager.deserialize (package:serverpod_serialization/src/serialization.dart:73:5)
#1 Protocol.deserialize (package:serverpod_demo_server/src/generated/protocol.dart:80:18)
#2 DatabaseConnection._formatTableRow (package:serverpod/src/database/database_connection.dart:239:45)
#3 DatabaseConnection.find (package:serverpod/src/database/database_connection.dart:178:18)

#4 DatabaseConnection.findSingleRow (package:serverpod/src/database/database_connection.dart:199:18)

#5 Database.findSingleRow (package:serverpod/src/database/database.dart:86:12)

#6 Serverpod.start. (package:serverpod/src/server/serverpod.dart:310:13)

#7 Serverpod.start (package:serverpod/src/server/serverpod.dart:299:5)

#8 run (package:serverpod_demo_server/server.dart:30:3)

@yahu1031 @filonov @aldychris @tp @II11II @vlidholt

Activity

  1. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    Similar issue to #426

  2. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    Can you explain to us what function/method you called?

  3. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    @Shubhamdsingh Please edit the title as
    No deserialization found for type `RuntimeSettings`

  4. changed the title [-]getting this error when running dart bin/main.dart [/-] [+]No deserialization found for type `RuntimeSettings`[/+] on Dec 6, 2022
  5. Shubhamdsingh commented on Dec 6, 2022

    @Shubhamdsingh
    Author

    I am running my server project and its showing the above error
    COMMAND
    dart bin/main.dart

    @yahu1031

  6. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    @Shubhamdsingh What is in here serverpod_demo_server/server.dart line 30

  7. Shubhamdsingh commented on Dec 6, 2022

    @Shubhamdsingh
    Author

    import 'package:serverpod/serverpod.dart';

    import 'package:serverpod_demo_server/src/web/routes/root.dart';

    import 'src/generated/protocol.dart';
    import 'src/generated/endpoints.dart';

    // This is the starting point of your Serverpod server. In most cases, you will
    // only need to make additions to this file if you add future calls, are
    // configuring Relic (Serverpod's web-server), or need custom setup work.

    void run(List args) async {
    // Initialize Serverpod and connect it with your generated code.
    final pod = Serverpod(
    args,
    Protocol(),
    Endpoints(),
    );

    // If you are using any future calls, they need to be registered here.
    // pod.registerFutureCall(ExampleFutureCall(), 'exampleFutureCall');

    // Setup a default page at the web root.
    pod.webServer.addRoute(RouteRoot(), '/');
    // Serve all files in the /static directory.
    pod.webServer
    .addRoute(RouteStaticDirectory(serverDirectory: 'static'), '/static/*');

    // Start the server.
    await pod.start();
    }

    @yahu1031 @yahu1031 @II11II this the code of 'serverpod_demo_server/server.dart' file

  8. Shubhamdsingh commented on Dec 6, 2022

    @Shubhamdsingh
    Author

    @yahu1031 can u help me in this its urgent

  9. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    Yes, I can. Can you please ping me on twitter

  10. Shubhamdsingh commented on Dec 6, 2022

    @Shubhamdsingh
    Author

    @yahu1031 can you tell me solution here only ?

  11. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    Yes I can, tell us all how you have started the server. @Shubhamdsingh

  12. Shubhamdsingh commented on Dec 6, 2022

    @Shubhamdsingh
    Author
    1. I had created a project
    2. Started docker in background
    3. In Server project i created protocols file and created endpoints with 'serverpod generate --watch ' running in terminal
    4. Then i started postgres and redis with command 'docker-compose up --build --detach'
    5. After that i runned my server project with command 'dart bin/main.dart'

    @yahu1031

  13. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    okie... sounds smooth. can you please check if the DB has all the tables?

  14. Shubhamdsingh commented on Dec 6, 2022

    @Shubhamdsingh
    Author

    @yahu1031 yes DB has all tables

  15. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    Okie can you restart the system and try again?

  16. Shubhamdsingh commented on Dec 6, 2022

    @Shubhamdsingh
    Author

    @yahu1031 getting same error

  17. suhaelfarouk commented on Dec 6, 2022

    @suhaelfarouk

    just clear the serverpod_runtime_settings table and restart the server and you are good to go.

  18. yahu1031 commented on Dec 6, 2022

    @yahu1031
    Contributor

    this may work. Try it.

  19. Shubhamdsingh commented on Dec 7, 2022

    @Shubhamdsingh
    Author

    Thanks it works @yahu1031 @suhaelfarouk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions