GithubHelp home page GithubHelp logo

tonghao / ok Goto Github PK

View Code? Open in Web Editor NEW

This project forked from okpy/ok

0.0 1.0 0.0 26.01 MB

ok.py supports programming projects by running tests, tracking progress, and assisting in debugging.

License: Apache License 2.0

Python 50.21% Makefile 0.07% HTML 24.08% CSS 2.74% JavaScript 20.46% Mako 0.03% Shell 1.21% Perl 0.69% Jupyter Notebook 0.43% Dockerfile 0.09%

ok's Introduction

Logo

The ok.py server collects submissions and displays analysis of student progress based on logging sent from client scripts.

Courses can sign up for our free hosted service on okpy.org

The ok.py software was developed for CS 61A at UC Berkeley.

Build Status Coverage Status Docker Repository on Quay

View Documentation at OK Documentation

Installation

To install:

  • Clone this repo
  • Install virtualenv. You can do brew install virtualenv on a mac or pip install virtualenv or apt-get install python-virtualenv
    • If brew cannot find virtualenv, use brew install pyenv-virtualenv.
  • Create a virtualenv with virtualenv -p python3 env
  • Activate the virtualenv with source env/bin/activate
  • (Optional, but recommended) Install redis-server. You can do brew install redis on a mac or apt-get install redis-server

Local Server

To run the server locally:

$ source env/bin/activate # for virtualenv
$ pip install -r requirements.txt  # to install libraries
$ ./manage.py createdb
$ ./manage.py seed
$ ./manage.py server

The server will listen on http://localhost:5000.

If you are running into issues - see documentation/SETUP.md or file an issue

Running Workers

To run workers locally:

$ ./manage.py worker

To be able to run the workers you should have a redis server installed and running.

If redis is not installed you can install it using your distribution's package manager or follow Redis Quick Start.

Command Line Manager

  • To view available commands run ./manage.py once the virtualenv is activated.

Customizing seed content

server/generate.py initializes the local server with sample content (Users, Assignments, a Course etc). You can customize it by changing the file and running ./manage.py resetdb.

Server Development

The server is developed in Python 3.5+ using Flask.

Core Features

Backup Maintenance

  • Best-effort maintenance of student backups that occur when ok is run.

Composition Grading

  • Allow staff to comment on student composition of projects and assign grades.

Autograding

  • Automatic grading of student submissions

Projects using ok.py

  • CS61A uses ok.py for all assignments.
  • Many other UC Berkeley CS courses use ok.py

Developer Guidelines

See documentation/CONTRIBUTING.md

Recent activity:

Throughput Graph

Deploying

Docker + Kubernetes on Google Container Engine. See kubernetes/kubernetes.md for more info.

The ok-server also supports deployments to Heroku or servers on any major hosting service.

There also exists a one-click setup for ok-server on Azure.

Python Style Guide

Refer to The Elements of Python Style

Some useful things for developers to know:

  1. Testing with ok-client
    • To test with ok-client, please follow the instructions for the ok-client repo here.
    • Once you are inside the virtual environment for ok-client, you can make a new binary by using the command ok-publish.
    • Start the local ok server.
    • When running the ok binary, add the flags --insecure --server localhost:<port> to point it to the running ok-server
    • To find demo assignments that you can use the binary with, look in ok-client/demo

ok's People

Contributors

sumukh avatar alvinwan avatar moowiz avatar sharadmv avatar knrafto avatar soumyabasu avatar albert12132 avatar papajohn avatar colinschoen avatar luise avatar kevinlin1 avatar c-w avatar raychan3 avatar epai avatar jathak avatar doppins-bot avatar ja5087 avatar timmy-g avatar pbitutsky avatar khalilsarwari avatar pyup-bot avatar kyletliang avatar j-wing avatar rohit-l avatar brianhou avatar tanaythan avatar martinpeck avatar navjotk avatar michellehwang avatar liliankasem avatar

Watchers

James Cloos avatar

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.