Proof Portal

Projects

jsonparser

ProbeLabs36 findings · 123 requirements
SYS-REQ-010SystemApproved

When Delete is called without a path, the parser shall return an empty document.

PriorityshallTypeguaranteeCategoryfunctionalComponentparserAssuranceEFindingsnone open

Specification

The requirement exactly as authored — its complete prose text and, where present, the formal FRETish sentence it compiles to.

Description

When Delete is called without a path, the parser shall return an empty document. DeleteFound is the explicit-found variant of Delete: DeleteFound(data, keys...) returns (result, found) where result is the post-deletion document (or the original input when the path is missing) and found is true iff the addressed value was located and removed.

FRETish formula
the parser shall always satisfy delete_path_is_provided | delete_returns_empty_document_without_path

Rationale & tags

Why this requirement exists, and how it is categorised.

Delete without a path is a distinct API outcome and should not be bundled with successful deletion, missing-target handling, or malformed-input robustness.

decompositiondeleteedge-case

Verification & provenance

How this requirement was checked: the review trail, edit history, and the machine-analysis status terms (each ⓘ explains what it means).

Assurance levelE
Formalizationvalid
Realizabilityrealizable
Vacuitychecked_ok
Strategyfretish

Review

Status
approved
Reviewer
human:buger · lead_engineer
Reviewed
Jul 26, 2026, 20:26 UTC
Re-approved after parser.go Delete whitespace-cleanup fix (DEFECT-260726-3PSJ). malformed_input obligation attached (high); nominal+negative witnesses in TestDeleteMalformedJSONRegression_SYS_REQ_010. FuzzPathMutation 60s + FuzzJSONStructureAware 30s crash-free post-fix.

History

Created
Apr 13, 2026, 17:15 UTC · human:cli
Modified
Jul 26, 2026, 20:26 UTC · human:buger

Obligations

What this requirement must witness to be considered satisfied — the required evidence, and the tests that discharge each one.

3 obligations · 3 discharged

Browse the catalogue
Discharged

Behavior when inputs are absent, nil, zero-length, or blank.

Worst case if violatedLow

Delete with no path returns a non-empty document instead of an empty one, leaking data the caller explicitly asked to erase.

Discharging evidence1/1 required witnessed
  • nominalrequiredpresent
    Covered by 1 test
Discharged

Behavior when inputs are syntactically or structurally invalid.

Worst case if violatedHigh

Delete on a well-formed array/object with whitespace between the deleted element and the trailing comma (or the close bracket) leaves a dangling comma or close-bracket sequence in the output, producing malformed JSON the caller cannot re-parse (DEFECT-260726-3PSJ, found by FuzzPathMutation).

Discharging evidence2/2 required witnessed
  • negativerequiredpresent
    Covered by 1 test
  • nominalrequiredpresent
    Covered by 1 test
Discharged

Behavior specified when inputs are nil, null, or zero-value.

Worst case if violatedHigh

Delete on nil data panics in nextToken at data[0] instead of returning the empty document, crashing the caller on a nil trust-boundary input.

Discharging evidence2/2 required witnessed
  • negativerequiredpresent
    Covered by 1 test
  • nominalrequiredpresent
    Covered by 1 test

Formula evidence

The formal formula behind this requirement, the variables it is written over, and the tests that exercise it (each term is explained inline).

FRETish formula

the parser shall always satisfy delete_path_is_provided | delete_returns_empty_document_without_path

Variables

NameTypeDirectionDescription
delete_path_is_providedTrue when Delete is called with at least one path segment.
delete_returns_empty_document_without_pathTrue when Delete returns an empty byte slice because no path segment was provided.

Witnesses· 3 scenarios total

  • TestMCDC_SYS_REQ_010_Row1_NoPathNoEmpty
    coverage_closure_test.go:103exercises 1 condition scenario
  • TestFuzzDeleteHarnessCoverage
    coverage_closure_test.go:49exercises 1 condition scenario
  • TestStress_Delete_TokenEndBoundary
    dead_code_audit_test.go:641
  • TestObligation_SYS_REQ_010
    obligation_evidence_test.go:168
  • TestDelete
    parser_test.go:1350exercises 1 condition scenario
  • TestDeleteMalformedJSONRegression_SYS_REQ_010
    set_spec_test.go:155
  • TestDeleteDoesNotAliasInputBackingArray
    v131_regression_test.go:73

Its place

This requirement shown inside its trace neighbourhood — the parents it satisfies, the code and tests attached to it, and its findings.

Loading graph…

Trace evidence

The concrete artifacts linked to this requirement — implementing code, verifying tests, documents, and the findings raised against it.

Impact

Blast radius — if you change this requirement, what else may need re-checking, and what it in turn depends on.

If you change this

Requirements
0
Files
2
Tests
7
At-risk contracts
0

Files to re-check (2)

  • fuzz.gofuzz.go
  • parser.goparser.go

Tests to re-run (7)

  • coverage_closure_test.gocoverage_closure_test.go
  • dead_code_audit_test.godead_code_audit_test.go
  • issues_56_107_229_test.goissues_56_107_229_test.go
  • obligation_evidence_test.goobligation_evidence_test.go
  • parser_test.goparser_test.go
  • set_spec_test.goset_spec_test.go
  • v131_regression_test.gov131_regression_test.go

What this rests on

Discussions

Discuss this with the proof team. Nothing changes in your audit automatically — you open a request and a staff member records any outcome inside the thread.

Sign in to discuss this with the proof team.Sign in