Skip to main content

Taska is a web console for running python code

Project description

taska

Code runner with typing-hint. Less is more, simple is the best.

Folder structure:

WORK_DIR > Python > Venv > Workspace > Job

Usage:

python -m taska ./demo --host=127.0.0.1 --port=8021

Demo files:

  • /root_dir

    root_dir=$WORK_DIR/$CWD

    • /runner.py
    • /pids/
    • /default_python
      • python_path(sys.executable)
      • /venv1
        • requirements.md5
        • requirements.txt
          • morebuiltins
        • /workspaces/workspace1 (code1.py, code2.py, package1/module.py)
          • sys.path.insert(0, workspace1)

          • /jobs
            • /job1
              • /meta.json

                cwd=/workspace1(const)
                python_path=/work_dir/default_python/venv1/bin/python.exe
                entrypoint=package1.module:function1
                params={"arg1": 1, "arg2": "str"}
                enable=1
                crontab=0 0 * * *
                mem_limit="1g"
                result_limit="15m"
                stdout_limit="10m"
                timeout=60

              • /pid.txt(int)

                29238

              • /stdout.log
              • /result.log

                {"start": "2024-07-14 23:30:57", "end": "2024-07-14 23:33:57", "result": 321}

            • /job2
              • /meta.json

                cwd=/workspace1(const)
                python_path=/work_dir/default_python/venv1/bin/python.exe
                entrypoint=code1:function2
                params={}
                crontab=0 */5 * * *
                mem_limit="100m"
                result_limit="10m"
                stdout_limit="10m"
                timeout=10

              • /pid.txt(int)

                32162

              • /stdout.log
              • /result.log

                ({"start": "2024-07-14 23:30:57", "end": "2024-07-14 23:33:57", "result": 321}\n)

        • /workspaces/workspace2 (code3.py)
    • /default_python2
      • python_path(executable=/usr/bin/python3.11)
      • /venv2
        • requirements.md5
        • requirements.txt
          • requests
          • selectolax

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

taska-0.1.1.tar.gz (20.6 kB view hashes)

Uploaded Source

Built Distribution

taska-0.1.1-py3-none-any.whl (21.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page