fix: resolve code review issues across all 10 packages#40
Merged
Conversation
- utils(splitGroups): guard groupSize <= 0 (C2) - utils(getRandomRangeValue): guard min > max (C3) - utils(ms2ticks): guard negative/zero params (I28) - bedrock-url: strip query/hash before baseDir for relative URLs (C4) - bedrock-url(URLSearchParams): add Symbol.iterator + generator methods (C5) - root: add .gitattributes with LF normalization (C1) - root: set core.ignorecase false for case-sensitive git (C1) - bedrock-url(test): add tests for C4/C5 fixes - utils: rename Experience.ts -> experience.ts for case-sensitive git
- ipc(ipc): change #sentIds from Set to Map with timestamp guard (I8) - ipc(chunk): guard chunkSize <= 0 with RangeError (I16) - ipc(types): update chunkSize doc to UTF-16 code units (I15) - discover: time-based #sentIds Map with stale cleanup (I17) - discover: carry serviceType in query param for heartbeat (I18) - discover: input validation for register/query (I19) - log(log): add level label to output format (I20) - log(log): constructor name validation (I21) - log(log): try-catch debug thunk exceptions (I22) - log(test): update assertions for new level label format
- rpc(rpc): fix invoke() ordering - pending.set before post (C9) - rpc(rpc): method name validation in invoke/handle (I25) - ci: remove double build, test scripts now just vitest (C10) - ci: replace @antfu/ni with native pnpm commands (C11) - release: remove hashFiles always-true condition (C13) - root+packages: add engines field (I31) - protocol(setup): align ScriptEventSource mock with real API (I23) - runtime(test): expand test coverage to 23 exports (I29)
- crypto(cipher): replace Math.random() with rngChacha20 CSPRNG (C6) - crypto(cipher): document HKDF vs PBKDF2 limitation (C7) - compress: fix description, add @throws, byte-length tests (M2-M5) - discover: TTL >=, error object, dispose events, export (M1-M4,M7-M8) - ipc: guards for namespace, channel, compressor, disposed (M1-M4) - ipc: README fix, benchmark sink, new tests (M5-M9) - log: level validation, declare global, new tests (M1,M3-M5) - log: README child example fix (M6) - protocol: once() try-catch, sourceType check, JSDoc (M1-M5) - rpc: simplify types, error guard, comments, ms2ticks ceil (M1-M6) - utils: base64 regex, addXP guard, splitGroups guard, unique guard (M2-M3,M5,M7) - root: typecheck, workspace, CI, gitignore, npmrc, eslint, README (M1-M5,M7,M9-M13,M17) - lint: fix style/sort/brace issues across packages
- ipc: catalog: -> workspace:^ for @mcbe-mods/compress - workspace: remove unused default catalog entry - ci: restore lts/* node-version, remove timeout-minutes
- package.json: restore tsc --noEmit, remove npx prefix - release.yml: lts/* instead of 22.x - .gitignore: remove unused entries (.env, *.tsbuildinfo, .pnpm-debug.log) - .npmrc: delete (auto-install-peers is pnpm default)
- normalizeServiceType: strip \d+. prefix instead of -N suffix - hostname format: n.type.discover (e.g. 2.\_svc.\_tcp.discover) - remove t param (no longer needed, hostname encodes type precisely)
- ipc/discover/rpc: add maxInflightIds option with default 1000 - ipc: replace throw on overflow with oldest-entry eviction - rpc: Set<string> -> Map<string,number> with timestamp + eviction - discover: use options.maxInflightIds instead of hardcoded constant
…ultRandomBytes rngChacha20 confirmed working, no longer need fallback path. Replace IIFE with plain function + lazy-initialized module-level rng.
- Experience.addXP: add console.warn on negative value - Log: validate options.level before fallback, add child() name guard - ms2ticks: clarify error message (non-negative vs positive) - runtime: re-export normalizeServiceType - tests: add validation guard tests for addXP, getRandomRangeValue, splitGroups
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.
Crypto
IPC / Discover / RPC
Log
Utils
Protocol
Bedrock-URL
Compress
Runtime
Root
Test improvements