data-api-builder
data-api-builder copied to clipboard
🥕[Bug]: Incorrect (or at least useful for debugging) message
Output
C:\Temp\demo>dab start
Information: Microsoft.DataApiBuilder 1.3.19
Information: Config not provided. Trying to get default config based on DAB_ENVIRONMENT...
Information: Environment variable DAB_ENVIRONMENT is (null)
Loading config file from C:\Temp\demo\dab-config.json.
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
at Azure.DataApiBuilder.Config.ObjectModel.RuntimeConfig..ctor(String Schema, DataSource DataSource, RuntimeEntities Entities, RuntimeOptions Runtime, DataSourceFiles DataSourceFiles) in /_/src/Config/ObjectModel/RuntimeConfig.cs:line 201
at .ctor(Object[])
at System.Text.Json.Serialization.Converters.LargeObjectWithParameterizedConstructorConverter`1.CreateObject(ReadStackFrame& frame)
at System.Text.Json.Serialization.Converters.ObjectWithParameterizedConstructorConverter`1.OnTryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value)
at System.Text.Json.Serialization.JsonConverter`1.TryRead(Utf8JsonReader& reader, Type typeToConvert, JsonSerializerOptions options, ReadStack& state, T& value, Boolean& isPopulatedValue)
Problem
Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
This error is because there one extra comma in the JSON file making it invalid. This error gives no guidance to the developer to help them understand where to start fixing the problem.
what does dab validate outputs in this scenario?