Cleanup, bug fixes, new features, and security improvements#3
Open
Chocapikk wants to merge 44 commits into
Open
Cleanup, bug fixes, new features, and security improvements#3Chocapikk wants to merge 44 commits into
Chocapikk wants to merge 44 commits into
Conversation
Owner
|
That's a great piece of work you've done, thank you so much for your contribution. I'll be doing the code review soon and integrating it into the main branch. I also think a large part of it will fit into the version we use when we play live. Hope to see you around sometime someday. |
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.
Hey! I stumbled on your project while looking for live coding tools from Strasbourg (allez Strasbourg 😄). I really dig what you guys do with CrashServer, the whole livecoding scene you've built there is sick.
I forked the repo and went through the codebase. Started with a quick lint pass and kept finding things to fix and improve. Here's what this PR covers:
Bug fixes
innerHTMLwith WebSocket data replaced with safe DOM methods (textContent+createElement)findIndexfalsy bug informatErrorMessage(index 0 was treated as false, now uses!== -1)markerUtilsundefined - was referenced but never imported (dead code that crashed on Alt+1/2/3), now implementedcatchblocks - errors were swallowed without logging, now logged to console==instead of===in multiple places (foxdotAutocomplete, main, configPanel)window.onclickoverride in configPanel replaced withaddEventListenerto avoid clobberingorangein getDurationColor,playersListimport, unusedeparam, etc.)New features
synth_definitions.pyfile)python3vspythonviashutil.whichinresolve_python())Security
Refactoring
startup.pyandstartup-renardo.pyinto a single file that auto-detects FoxDot vs Renardo at runtime.startup-renardo.pyis deleted.sendScale,sendRoot,sendBeat,sendChronoreplaced with a single_send_loopmethod + getter functionsisRunning->is_running,playerCounter->player_counter,wsPanel->ws_panel, etc.)main.jsthrough a singlesendToServer()function withreadyStateguard. RemovedstopClock,soloPlayer,unSoloPlayers,resetChronofromfunctionUtils.js(they all just wrappedwsServer.send)server.py- extractedHOST/WS_PORTconstants, flattened nestedhandle_foxdot_outputinto top-level_read_stream, captures both stdout and stderr viaasyncio.gatherwsServerparam fromsaveEditorContentTooling
ruff.tomlconfig, all Python files passruff checkandruff formatwith 0 errors. Runtime globals from FoxDot/Renardo are ignored via per-file configeslint.config.jswith recommended rules +eqeqeq,no-var,prefer-const. All JS files pass with 0 errors. Added eslint to devDependencies.gitignoreupdated with.ruff_cache/Docs
resolve_python()usagesynth_definitions.pyto installation instructions (Python, Node.js, and Renardo sections)Breaking changes / migration notes
startup-renardo.pyis deleted. If you were using it, switch tostartup.pywhich now handles both FoxDot and Renardo automaticallysynth_definitions.pymust be placed alongsidestartup.pyin your FoxDot/Renardo Custom directory for autocomplete descriptions to workwsPanel->ws_panel,timeInit->time_init, etc.) - if you have custom scripts referencing the old names, update them