Skip to content

[Repo Assist] Fix FS1182 compiler warning in JsonSchema.parseSchemaFromTextReader#1763

Open
github-actions[bot] wants to merge 3 commits intomainfrom
repo-assist/fix-jsonschema-unused-resolution-folder-2026-04-26-bafa3f440e2e03d1
Open

[Repo Assist] Fix FS1182 compiler warning in JsonSchema.parseSchemaFromTextReader#1763
github-actions[bot] wants to merge 3 commits intomainfrom
repo-assist/fix-jsonschema-unused-resolution-folder-2026-04-26-bafa3f440e2e03d1

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

🤖 This PR was created by Repo Assist, an automated AI assistant.

Summary

Fixes a pre-existing FS1182 compiler warning in src/FSharp.Data.Json.Core/JsonSchema.fs:

JsonSchema.fs(235,36): warning FS1182: The value 'resolutionFolder' is unused

Root Cause

JsonSchema.parseSchemaFromTextReader accepts a resolutionFolder: string parameter as a placeholder for future JSON Schema $ref resolution support — analogous to how the XML provider uses this parameter for XSD $ref resolution. Since JSON Schema $ref resolution is not yet implemented, the parameter is currently unused, which triggers a FS1182 warning.

Fix

Renamed the parameter from resolutionFolder to _resolutionFolder to signal it is intentionally unused (the conventional F# idiom), and expanded the doc comment to explain the placeholder intent.

/// Parse a JSON Schema from a TextReader.
/// The <c>resolutionFolder</c> parameter is reserved for future <c>$ref</c> resolution support
/// and is not currently used; JSON Schema <c>$ref</c> resolution is not yet implemented.
let parseSchemaFromTextReader (_resolutionFolder: string) (reader: System.IO.TextReader) =

No behaviour change — the call site in src/FSharp.Data/Runtime.fs passes "" and continues to work correctly.

Test Status

  • dotnet build src/FSharp.Data.Json.Core/ — Build succeeded, no FS1182 warning
  • ⚠️ Full test suite blocked by a pre-existing NU1902 vulnerability error (OpenTelemetry.Api 1.15.0) on this branch — addressed separately in the OpenTelemetry fix PR

Generated by 🌈 Repo Assist, see workflow run. Learn more.

To install this agentic workflow, run

gh aw add githubnext/agentics/workflows/repo-assist.md@96b9d4c39aa22359c0b38265927eadb31dcf4e2a

…nused

The resolutionFolder parameter in JsonSchema.parseSchemaFromTextReader is
a placeholder for future JSON Schema $ref resolution support (analogous to
the XML provider which uses this parameter for XSD $ref resolution).
Since $ref resolution is not yet implemented for JSON Schema, the parameter
is currently unused, generating a FS1182 compiler warning.

Prefix it with _ to indicate it is intentionally unused and suppress the
warning, while preserving the future-use intent via the doc comment.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@dsyme dsyme marked this pull request as ready for review May 1, 2026 11:43
@github-actions
Copy link
Copy Markdown
Contributor Author

github-actions Bot commented May 3, 2026

🤖 This is an automated response from Repo Assist.

Checking in on the Windows CI failure: I've reviewed the build logs for the failing build-windows job (run 25213074095) and the build actually passed — all test suites report 0 failures and FAKE's build report shows Status: Ok. The job was recorded as failure due to what appears to be a post-job infrastructure issue (orphan process cleanup returning a non-zero code) rather than any code problem.

The build-ubuntu and check-format jobs both passed cleanly, and the change itself (renaming resolutionFolder_resolutionFolder) is trivially correct and non-breaking.

A maintainer can safely re-run the failed Windows job to get a green checkmark, or simply approve and merge given the Ubuntu build is passing and the change is minimal.

Generated by 🌈 Repo Assist, see workflow run. Learn more.

To install this agentic workflow, run

gh aw add githubnext/agentics/workflows/repo-assist.md@96b9d4c39aa22359c0b38265927eadb31dcf4e2a

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant