Conversation
Co-authored-by: kzu <169707+kzu@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Make implementation types internal to hide from consumers
Reduce JQSharp public API surface by hiding implementation types
Mar 6, 2026
Member
🧪 Details on Ubuntu 24.04.3 LTSfrom retest v1.1.0 on .NET 10.0.3 with 💜 by @devlooped |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change narrows the exposed API to consumer-facing entry points and hides parser/runtime internals that were unintentionally public. The goal is to keep
Jqas the façade while making AST/parser/control-flow implementation types non-public.API surface hardening
Jq.Parse(string)changed from public to internal.JqFilterchanged frompublic abstract classto non-publicabstract class.JqFilterstatic helpers restricted to internal:CreateNullElementStaticStructurallyEqualGetTypeNameStaticGetValueTextStaticParser/runtime internals made non-public
JqParser→ non-public sealed classJqHaltException→ non-public sealed classJqBreakException→ non-public sealed classJqEnvironment→ non-public sealed classJqPattern,VariablePattern,ArrayPattern,ObjectPattern→ non-publicFilterClosure→ non-public sealed recordBinaryOp→ non-public enumUserFunctionDef→ non-public sealed classFilter implementations hidden
src/JQSharp/Filters/were changed frompublic sealed classto non-publicsealed class(implicit internal by omission), matching.editorconfigguidance on redundant visibility modifiers.Design doc alignment
.github/design.mdto reflectJqas public façade with internal parse entry.Example of the intended visibility pattern:
Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
kzu.blob.core.windows.net/usr/bin/dotnet dotnet restore(dns block)/usr/bin/dotnet dotnet restore --no-dependencies /home/REDACTED/work/JQSharp/JQSharp/JQSharp.slnx --packages /tmp/codeql-scratch-58a1ab1f0b60fde2/dbs/csharp/working/packages /p:DisableImplicitNuGetFallbackFolder=true --verbosity normal /p:TargetFrameworkRootPath=/tmp/codeql-scratch-58a1ab1f0b60fde2/dbs/csharp/working/emptyFakeDotnetRoot /p:NetCoreTargetingPackRoot=/tmp/codeql-scratch-58a1ab1f0b60fde2/dbs/csharp/working/emptyFakeDotnetRoot /p:AllowMissingPrunePackageData=true conf�� rateFilter.cs --global it pull.rebase(dns block)If you need me to access, download, or install something from one of these locations, you can either:
Original prompt
🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.