Skip to content
This repository has been archived by the owner on Oct 1, 2024. It is now read-only.
/ evaluation Public archive

Fetch runs from server, calculate standings, create csv and json, make publicly available

Notifications You must be signed in to change notification settings

rcjberlin/evaluation

Repository files navigation

rcjberlin - evaluation

  1. Fetch runs from API (see https://github.com/rcjberlin/rcj-server)
  2. Calculate standings
  3. Export to CSV and JSON

This repository includes the code to create the standings but it will also include the live-results. The results will be pushed during competition to make them available for further use via GitHub Pages on https://rcjberlin.github.io/evaluation/results.

setup

Since the API is restricted to authorized users, you need to specify your credentials in config.js. Additionally, some constants are configured there.

const secret = require("./config.secret.ignore");

module.exports = {
    username: "username",
    //password: secret.password,
    password: "mypassword",
    rcj_server_hostname: "http://localhost:5000",
    competition: "2022-berlin",

    // server
    port: 5001,
    //accepted_auth_tokens: [secret.rcjserver_token],
    accepted_auth_tokens: ["token-authorizing-rcjserver-123456"],
    calc_interval: 60,
}

Install all required packages with npm install. Run the calculation with node calc.js or start the server with node server.js.

About

Fetch runs from server, calculate standings, create csv and json, make publicly available

Resources

Stars

Watchers

Forks