Giter VIP home page Giter VIP logo

codelab's People

Contributors

andredias avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

Forkers

squeeko

codelab's Issues

Insert button to Edit project

Currently, clicking on the project title redirects to the project Dojo. But it might not be very explicit. An edit button for the project will make this clearer.

New Project Button

Insert a button to create a new project related to the current filtered language. Example: button to create a new Python project.

Project Description doesn't show line breaks correctly

Currently, the description is being held by a <p> tag, which does not handle line breaks correctly. One solution might be to change the paragraph to a <textarea>. Another could be using Markdown or RestructuredText in descriptions and then compile it into HTML.

Handle server errors 500

For example, when the client tries to run a program but receives a 500 error, what should they do?

Keep project history

We could maintain project history by adding a new field that points to a previous revision. It is very similar to what version control uses internally.

Remove TailwindCSS dependency

TailwindCSS pollutes HTML a lot and should be removed. However, the current CSS depends on Tailwindcss' base for CSS reset or normalize. This should be kept.

Add project documentation

  • Page about how it works. Maybe it can work also as the project's documentation.
  • Contact form?
  • Privacy Policy

Store playground code in a database

Currently, code snippets are only stored in Redis with a TTL of a few days. A better approach is to store them in a database for persistence. I'm still not sure what kind of database is ideal. MongoDB and Postgres seem to be good candidates.

Prevent redundant transformations in FastAPI entry points

/projects, for example, transform an array of projects in JSON from Redis into an array of Pydantic Objects that will be transformed at the end into a JSON array by FastAPI. There must be some way to return the information closer to the way it comes from Redis.

Create a testing strategy

There is no automated test for Codelab yet. It is necessary to add a GitHub Actions entry and another step in Makefile for that.

Backend should inform available languages

Despite codebox executes Python code only, the frontend must be prepared to work with any registered language. Additionally, the backend should have an API entry just to inform the available languages. Later, this feature should migrate to codebox.

Improve Codebox based on Snekbox

Python Discord has a very similar sandbox container called snekbox which uses some very good ideas that we can also apply in codebox:

  1. It is based on HTTP instead of stdin, stdout, stderr
  2. It uses NsJail to create sandboxed processes. Using it, we might create a unique container to serve all jobs instead of spinning up a container for each project. Or even better, we can drop the additional container at all.

There is another similar project called Piston that is based on LXC containers that might be useful too.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.