Skip to content

Frends.JSON.Handlebars: compliance fixes — net8, static class, Options param, Error result - #42

Open
MichalFrends1 with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-compliance-findings-in-frends-json-handlers
Open

Frends.JSON.Handlebars: compliance fixes — net8, static class, Options param, Error result#42
MichalFrends1 with Copilot wants to merge 2 commits into
mainfrom
copilot/fix-compliance-findings-in-frends-json-handlers

Conversation

Copilot AI commented Aug 5, 2026

Copy link
Copy Markdown
Contributor

Resolves task analyzer findings (FT0004, FT0007, FT0011), upgrades target framework to net8.0, and adds standard error-handling support.

Changes

  • net8.0 — Both main and test projects retargeted from net6.0
  • Static class (FT0004) — JSON class is now static
  • Options parameter (FT0007) — New Options class added; Handlebars() now accepts it as a [PropertyTab] parameter with ThrowErrorOnFailure (default true) and ErrorMessageOnFailure
  • Error property on Result (FT0011) — New Error class (Message, AdditionalInfo); Result gains an Error property populated on failure
  • ErrorHandler helperHelpers/ErrorHandler.cs with standard ex.Handle(options) extension; main method body wrapped in try/catch
  • Version bumped to 1.3.0

Updated call signature

// Before
JSON.Handlebars(input, cancellationToken)

// After
JSON.Handlebars(input, options, cancellationToken)

Error handling behavior

var options = new Options { ThrowErrorOnFailure = false };
var result = JSON.Handlebars(input, options, ct);
// result.Success == false, result.Error.Message contains the reason

Co-authored-by: MichalFrends1 <167774394+MichalFrends1@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix compliance findings in Frends.JSON.Handlebars Frends.JSON.Handlebars: compliance fixes — net8, static class, Options param, Error result Aug 5, 2026
Copilot AI requested a review from MichalFrends1 August 5, 2026 06:29
@MichalFrends1
MichalFrends1 marked this pull request as ready for review August 5, 2026 06:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants