Caution
Affected Pages: C++ and Python.
(Note: The C compiler is currently unaffected.)
Issue: On PCs and Tablets, extremely long lines of code push the terminal section completely off-screen to the right. This does not affect mobile users, as the terminal is positioned below the editor.
Planned Fixes:
- Auto-Wrap: Implementing
overflow-wraporwhite-space: pre-wrapto keep code within bounds. - Resizable Divider: Adding a draggable slider to manually restore the layout.
Status: Investigating layout constraints for the C++ and Python environments.
TO DEVELOPERS: If you'd like to fix this, please fork the repository, apply your changes (e.g., CSS wrapping or a divider script), and submit a Pull Request. I appreciate the help!
A real-time, low-latency code execution platform. > Built with raw WebSockets, Python
aiohttp, and a custom C/C++ runner.
-
Real-time I/O: Uses WebSockets to stream output character-by-character, allowing for interactive programs (e.g.,
input()in Python orstd::cinin C++). -
Multi-Language Support:
-
π Python 3: With Auto-Pip technology (detects imports and installs packages on the fly).
-
βοΈ C / C++: Full GCC/G++ compilation with standard stream handling.
-
-
Cyberpunk UI: A retro-futuristic, responsive interface built with Tailwind CSS and Xterm.js.
-
Low Latency: Persistent connections avoid the overhead of repeated HTTP requests.
| Component | Technology |
|---|---|
| Frontend | HTML5, Tailwind CSS, Xterm.js (WebSockets) |
| Backend | Python 3.10, aiohttp, asyncio |
| Compilers | GCC 11, G++, CPython |
| Deployment | Docker (Planned), Linux Host |
The core is an asynchronous Python server using aiohttp. It upgrades HTTP requests to WebSocket connections.
-
Session Handling: Each tab gets a unique session.
-
Execution: Spawns
subprocessthreads to run user code safely on the host. -
Stream Redirection: Captures
stdoutandstderrpipes and pushes them to the frontend in real-time.
-
Editor: A custom
textareaoverlay for code input. -
Terminal:
xterm.jsrenders ANSI escape codes (colors) and handles user input during execution.
-
Python 3.10+
-
GCC / G++ Compiler
-
Linux/MacOS (Recommended) or Windows (WSL)
git clone [https://github.com/notamitgamer/cloud-compiler.git](https://github.com/notamitgamer/cloud-compiler.git)
cd cloud-compilerpip install -r requirements.txtpython backend.pyThe server will start on port 8080 (or the port defined in backend.py).
This compiler is a demonstration project created by a Computer Science undergraduate.
-
Security: Code is currently executed on the host machine without sandboxing. Do not run malicious code.
-
Liability: Amit Dutta assumes no responsibility for any data loss, security breaches, or damages resulting from the use of this code. Use at your own risk.
-
Rights: The author reserves the right to modify or take down the service at any time.
Amit Dutta
-
π CS Undergraduate (19 y/o)
-
π amit.is-a.dev
-
π GitHub
Built with β€οΈ and β in Kolkata, India.