Fix PR #10 review comments: null safety, interface visibility, cookie parsing, WebSocket headers, typos#11
Merged
ReneSchwarzer merged 2 commits intodevelopfrom Apr 2, 2026
Conversation
…interface visibility, WebSocket headers Agent-Logs-Url: https://github.com/webexpress-framework/WebExpress.WebCore/sessions/21fd93fa-c2a8-4f06-a85f-237eec4ad043 Co-authored-by: ReneSchwarzer <31061438+ReneSchwarzer@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Update README documentation for clarity
Fix PR #10 review comments: null safety, interface visibility, cookie parsing, WebSocket headers, typos
Apr 2, 2026
ReneSchwarzer
approved these changes
Apr 2, 2026
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Addresses 14 Copilot review comments on PR #10 (0.0.10-alpha). Fixes span correctness bugs, API design issues, and naming inconsistencies introduced by that PR.
Bug Fixes
TaskManager:CreateTask/CreateTask<TTask>were calling_dictionary.TryGetValue(id, ...)instead of_dictionary.TryGetValue(key, ...)after lowercasing — allowing duplicate entries with different casing.RemoveTaskwould throwNullReferenceException/ArgumentNullExceptionwhentaskortask.Idis null; added early return guard.RequestHeaderFields— cookie parsing:c.Split('=')[1]throws on malformed cookies and misparses values containing=(e.g. base64). Now splits on;first, then on the first=only:UnitTestRandomId.HexCharacters:Substring(4)skips one extra character past theid_prefix (length 3), leaving one hex char unvalidated. Changed toSubstring("id_".Length).API / Design Fixes
IUriPathSegment:internalmembers (Id,IsHiddensetter,Urisetter) on apublicinterface make it unimplementable from external assemblies. Removedinternalmodifiers.ResponseHeaderFields.ToString():Sec-WebSocket-Acceptwas never emitted, breaking WebSocket handshake responses. Added emission whenSecWebSocketAcceptis set.ISocketContext.MaxMessageSize: Type wasulongbut docs statednullmeans "no limit". Changed toulong?throughout (ISocketContext,SocketContext,SocketItem,SocketManager);nullnow correctly represents unlimited.Naming / Clarity
SegmentRegexAttribute,SegmentStringAttribute,SegmentUIntAttribute: Parameter nameddisplaywas passed directly astagto path segment constructors — misleading. Renamed totag.UriQuery<TParamerer>: Typo in generic type parameter name. Renamed toTParameter.ISockt.cs: Renamed toISocket.cs; updated misleading doc comment referencing non-existent cancellation token andconnectMessageparameters.Test Fix
UnitTestStatusPageManager: Expected content length of 78 was stale after the PR's HTML rendering changes produced 72. Updated inline data.