Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/cli/EigenAI.CLI/EigenAI.CLI.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@
<None Include="README.md" Pack="true" PackagePath="\" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="MinVer" Version="8.0.0">
<PackageReference Include="MinVer" Version="7.0.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="System.CommandLine" Version="2.0.14" />
<PackageReference Include="System.CommandLine" Version="2.0.7" />
<ProjectReference Include="../../libs/EigenAI/EigenAI.csproj" />
</ItemGroup>
</Project>
26 changes: 26 additions & 0 deletions src/libs/EigenAI/Generated/EigenAI.Exceptions.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,32 @@ public partial class ApiException : global::System.Exception
/// </summary>
public string? ResponseBody { get; set; }

/// <summary>
/// Successful HTTP responses that fail during processing put the cause before a bounded body preview.
/// Inspect ResponseBody for the full response; HTTP service-error messages retain their existing format.
/// </summary>
public override string Message
{
get
{
if ((int)StatusCode < 200 || (int)StatusCode >= 300 || InnerException == null)
{
return base.Message;
}

string? path = (InnerException as global::System.Text.Json.JsonException)?.Path;
return "Response processing failed after successful HTTP " +
((int)StatusCode).ToString(global::System.Globalization.CultureInfo.InvariantCulture) + ": " +
InnerException.GetType().FullName + ": " + BoundDiagnosticText(InnerException.Message) +
(string.IsNullOrEmpty(path) ? string.Empty : " Path: " + BoundDiagnosticText(path, 256)) +
"\nResponse preview: " + BoundDiagnosticText(base.Message);
}
}

private static string BoundDiagnosticText(string? value, int maximumLength = 512) =>
value == null ? string.Empty :
value.Length <= maximumLength ? value : value.Substring(0, maximumLength) + "... [truncated]";

/// <summary>
/// The response headers.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ namespace EigenAI
#pragma warning restore CS3016
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::EigenAI.JsonSerializerContextTypes))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::System.Collections.Generic.List<object>), TypeInfoPropertyName = "SystemCollectionsGeneric_ObjectList")]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(string[]))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(global::EigenAI.ImageGenerationRequest))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(string))]
[global::System.Text.Json.Serialization.JsonSerializable(typeof(int))]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,11 @@ public sealed partial class JsonSerializerContextTypes
/// </summary>
public global::System.Collections.Generic.List<object>? ObjectList { get; set; }

/// <summary>
/// String arrays used by dynamic JSON option values.
/// </summary>
public string[]? StringArray { get; set; }

/// <summary>
///
/// </summary>
Expand Down
Loading