Skip to content

Lobby & Script Execution Revamp: Speed, Security & UI - #15

Open
DenisIndenbom wants to merge 33 commits into
roctbb:masterfrom
DenisIndenbom:master
Open

Lobby & Script Execution Revamp: Speed, Security & UI#15
DenisIndenbom wants to merge 33 commits into
roctbb:masterfrom
DenisIndenbom:master

Conversation

@DenisIndenbom

@DenisIndenbom DenisIndenbom commented Feb 23, 2025

Copy link
Copy Markdown
Contributor

Summary

This PR delivers critical stability improvements, security enhancements, and technical debt cleanup for lobby management and script execution systems. Key highlights include:

  • Security hardening: Isolated player scripts from global state and replaced unsafe execution mechanisms.
  • Critical bug fixes: Resolved race conditions causing double session execution and improved session persistence after restarts.
  • Performance optimizations: Scripts are now pre-compiled, improving execution time by 2x.
  • Frontend remake: Redesigned the entire frontend for better usability, responsiveness, and accessibility.
  • Infrastructure updates: Modernized Docker configuration for smoother deployments.
  • Codebase modernization: Refactored imports, cleaned up deprecated code, and enforced consistent code style.

Changes Breakdown

Security Enhancements

  • Lobby session integrity

    • Fixed crashes caused by missing lobby existence.
    • Improved session validation and automatic cleanup to prevent orphaned sessions.
  • User script sandboxing

    • Isolated player scripts from global state to prevent unauthorized access.
    • Replaced unsafe execution mechanisms with a multiprocessing approach for better security.
    • Added robust exception handling to gracefully manage script execution errors.
  • Closing data leaks

    • Prohibited access to files not from game frontend folder

Performance Improvements

  • Script execution optimizations

    • Pre-compiled user scripts for faster execution (2x performance improvement).
  • Lobby UX upgrades

    • Enhanced frontend interactions for team management.
    • Fixed UI bugs affecting team deletion and session handling.
    • Added a ready-check system for players to streamline session launches.
  • Stats UX/UI Upgrades

    • Updated stats webpage with improved UI/UX.
    • Enhanced table generation script for better readability and performance.

Frontend Remake

  • Redesigned the entire frontend for better usability, responsiveness, and accessibility.
  • Improved navigation, visual design, and consistency across all user-facing components.

Critical Bug Fixes

  • Session management
    • Fixed race conditions causing double session execution.
    • Resolved issues with session persistence after restarts.

Technical Debt Cleanup

  • Codebase refactoring

    • Restructured blueprint imports for improved maintainability.
    • Cleaned up deprecated code in ge_sdk.py.
  • Code style enforcement

    • Standardized quotation marks across multiple files.
    • Removed redundant and unused code snippets.
    • Added type annotations to all functions in the methods module for better code clarity.

Please review the changes, with special attention to:

  • Security enhancements in script sandboxing and session validation.
  • Performance improvements in script execution.
  • Frontend responsiveness and accessibility.

Let me know if you find any issues or have suggestions for further improvements.

DenisIndenbom and others added 30 commits February 18, 2025 13:57
…plemented closing lobby after session staring
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant