Invalid character after parsing property name error after publish website on ionos

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
3 年 前
hi,
i'm working for publish my website on ionos but I have this error (see after) and I don't understant where is the problem.
I'm setting publish from vs2019 with x86, release mode, self contained in deployment mode,
in App_Data I have add dataSettings.json (with the connection string modified) and plugins.json,
In webproj I have insert
<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<PublishWithAspNetCoreTargetManifest>false</PublishWithAspNetCoreTargetManifest>
</PropertyGroup>
how tell me the hosting assistance but I have always error. Do you have any ideas?
thanks
website www.desinet.it

error:
An error occurred while starting the application.
JsonReaderException: Invalid character after parsing property name. Expected ':' but got: D. Path '', line 2, position 4.
Newtonsoft.Json.JsonTextReader.ParseProperty()

JsonReaderException: Invalid character after parsing property name. Expected ':' but got: D. Path '', line 2, position 4.
Newtonsoft.Json.JsonTextReader.ParseProperty()
Newtonsoft.Json.JsonTextReader.ParseObject()
Newtonsoft.Json.JsonTextReader.Read()
Newtonsoft.Json.JsonReader.ReadAndAssert()
Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateObject(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, object existingValue)
Newtonsoft.Json.Serialization.JsonSerializerInternalReader.CreateValueInternal(JsonReader reader, Type objectType, JsonContract contract, JsonProperty member, JsonContainerContract containerContract, JsonProperty containerMember, object existingValue)
Newtonsoft.Json.Serialization.JsonSerializerInternalReader.Deserialize(JsonReader reader, Type objectType, bool checkAdditionalContent)
Newtonsoft.Json.JsonSerializer.DeserializeInternal(JsonReader reader, Type objectType)
Newtonsoft.Json.JsonSerializer.Deserialize(JsonReader reader, Type objectType)
Newtonsoft.Json.JsonConvert.DeserializeObject(string value, Type type, JsonSerializerSettings settings)
Newtonsoft.Json.JsonConvert.DeserializeObject<T>(string value, JsonSerializerSettings settings)
Nop.Data.DataSettingsManager.LoadSettings(string filePath, bool reloadSettings, INopFileProvider fileProvider) in DataSettingsManager.cs
Nop.Data.DataSettingsManager.get_DatabaseIsInstalled() in DataSettingsManager.cs
Nop.Web.Framework.Infrastructure.Extensions.ServiceCollectionExtensions.AddThemes(IServiceCollection services) in ServiceCollectionExtensions.cs
Nop.Web.Framework.Infrastructure.NopCommonStartup.ConfigureServices(IServiceCollection services, IConfiguration configuration) in NopCommonStartup.cs
Nop.Core.Infrastructure.NopEngine.ConfigureServices(IServiceCollection services, IConfiguration configuration, NopConfig nopConfig) in NopEngine.cs
Nop.Web.Framework.Infrastructure.Extensions.ServiceCollectionExtensions.ConfigureApplicationServices(IServiceCollection services, IConfiguration configuration, IWebHostEnvironment webHostEnvironment) in ServiceCollectionExtensions.cs
Nop.Web.Startup.ConfigureServices(IServiceCollection services) in Startup.cs
System.RuntimeMethodHandle.InvokeMethod(object target, object[] arguments, Signature sig, bool constructor, bool wrapExceptions)
System.Reflection.RuntimeMethodInfo.Invoke(object obj, BindingFlags invokeAttr, Binder binder, object[] parameters, CultureInfo culture)
Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.InvokeCore(object instance, IServiceCollection services)
Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder+<>c__DisplayClass9_0.<Invoke>g__Startup|0(IServiceCollection serviceCollection)
Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder.Invoke(object instance, IServiceCollection services)
Microsoft.AspNetCore.Hosting.ConfigureServicesBuilder+<>c__DisplayClass8_0.<Build>b__0(IServiceCollection services)
Microsoft.AspNetCore.Hosting.GenericWebHostBuilder.UseStartup(Type startupType, HostBuilderContext context, IServiceCollection services)
Microsoft.AspNetCore.Hosting.GenericWebHostBuilder+<>c__DisplayClass12_0.<UseStartup>b__0(HostBuilderContext context, IServiceCollection services)
Microsoft.Extensions.Hosting.HostBuilder.CreateServiceProvider()
Microsoft.Extensions.Hosting.HostBuilder.Build()
Nop.Web.Program.Main(string[] args) in Program.cs
3 年 前
RE: "...dataSettings.json (with the connection string modified)"
       "Expected ':' but got: D. Path '', line 2, position 4

Check your modification.  The error message seems to indicate JSON syntax error.  (Did you leave out a quote " char?)

Line 2 should look like this
  "DataProvider": "sqlserver",
3 年 前
Write the proper connection string.
3 年 前
thank you very much fro the answer: it was the "
:-(
I had entered two " in dataSettings.json , now try.
have a nice day
nello
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.