-
Notifications
You must be signed in to change notification settings - Fork 113
Add server-side logging #404
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
WalkthroughA new optional query string parameter, Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant App
participant Bot
participant Net
User->>App: Loads app with query params (may include proxyLogging)
App->>App: Checks appQueryParams.proxyLogging
alt proxyLogging enabled
App->>Bot: Assigns _client.logProxy = Net.logProxy
else proxyLogging not enabled
App->>Bot: Assigns _client.logProxy = noop
end
App->>Bot: Initiates connection
Bot->>Bot: On connection events (error, connect, kick, disconnect, chunks loaded)
Bot->>Bot: Calls _client.logProxy with event info
Bot->>Console: Optionally logs to console
Estimated code review effort🎯 2 (Simple) | ⏱️ ~7 minutes Poem
Note ⚡️ Unit Test Generation is now available in beta!Learn more here, or try it out under "Finishing Touches" below. 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (3)
🧰 Additional context used📓 Path-based instructions (1)src/**/*.ts📄 CodeRabbit Inference Engine (.cursor/rules/vars-usage.mdc)
Files:
🧠 Learnings (5)📚 Learning: applies to src/**/*.ts : you may use the global variable `bot` directly in any file under the `src/`...
Applied to files:
📚 Learning: applies to renderer/**/*.ts : in renderer code, all bot/player state and events must be accessed via...
Applied to files:
📚 Learning: applies to renderer/**/*.ts : do not use the global variable `bot` directly in any file under the `r...
Applied to files:
📚 Learning: applies to src/**/*.ts : in `src/` code, you may use the global variable `appviewer` from `src/appvi...
Applied to files:
📚 Learning: in the minecraft-web-client project, files under renderer/ directory must not access the global `bot...
Applied to files:
🔇 Additional comments (8)
✨ Finishing Touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Enable proxy logging by passing
?proxyLogging=true
as url query parameter.Any important message will be send to the proxy for logging.1
Currently implemented "important messages" include:
Summary by CodeRabbit
New Features
Bug Fixes
Footnotes
Logging needs to be enabled on the proxy too. Also https://github.com/zardoy/prismarinejs-net-browserify/pull/1 is required. ↩