Skip to main content

An Attempt At Robot Challenge

Project description

RobotChallenge

made-with-python codecov License CI test PyPI version

Robot Challenge


Summary

An attempt at Robot Challenge.


How to Install

# download and install python >=3.7 fromhttps://www.python.org/downloads/
# download source code using git
git clone https://github.com/sheecegardezi/RobotChallenge.git
cd RobotChallenge

# install create a virtual environment
python -m venv venv

# activate the virtual environment on Linux
source venv/bin/activate
# activate the virtual environment on windows
# source venv\Scripts\activate

# install the requirements
pip install -r requirements.txt

# install the software
pip install -e .

# run the tests
pytest --cov=robotchallenge -rx -s tests

Running Software Locally

robotchallenge --help
robotchallenge -f "`pwd`/tests/test_data/sample_problems.txt"

Usage of the Software

# Create a file with a new commond is each line eg. input_file.txt:

    PLACE 1,2,EAST
    MOVE
    MOVE
    LEFT
    MOVE
    REPORT
    Output: 3,3,NORTH

# Run the software with the above file

    robotchallenge -f "`pwd`/input_file.txt"    

Running Software in Docker

# clone repo
git clone https://github.com/sheecegardezi/RobotChallenge.git
cd RobotChallenge

# building image locally
docker build -t robotchallenge .

# printing help
docker run -it --rm robotchallenge -h

# using existing test file 
docker run -it --rm robotchallenge -f "/app/tests/test_data/sample_problems.txt"

# using new test file 
docker run -it --rm -v "`pwd`/tests/test_data/sample_problems.txt":"/app/tests/test_data/sample_problems.txt" robotchallenge -f "/app/tests/test_data/sample_problems.txt"

Running Software using prebaked Docker Image

# pulling image from repo
docker image pull sheecegardezi/robotchallenge:latest

# printing help
docker run -it --rm sheecegardezi/robotchallenge:latest -h

# using existing test file 
docker run -it --rm sheecegardezi/robotchallenge:latest -f "/app/tests/test_data/sample_problems.txt"

# using new test file 
docker run -it --rm -v "`pwd`/tests/test_data/sample_problems.txt":"/app/tests/test_data/sample_problems.txt" sheecegardezi/robotchallenge:latest -f "/app/tests/test_data/sample_problems.txt"

Running Testing

pytest --cov=robotchallenge -rx -s tests

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

robotchallenge-1.0.1.tar.gz (9.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

robotchallenge-1.0.1-py3-none-any.whl (10.7 kB view details)

Uploaded Python 3

File details

Details for the file robotchallenge-1.0.1.tar.gz.

File metadata

  • Download URL: robotchallenge-1.0.1.tar.gz
  • Upload date:
  • Size: 9.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.10

File hashes

Hashes for robotchallenge-1.0.1.tar.gz
Algorithm Hash digest
SHA256 fa51d0eac925593d4ad44e5c9ff24d4f0a13cd0c9ae962f46dd42040c2cc1fbb
MD5 965a1f8f6d6480f6067f32029fbc2558
BLAKE2b-256 a8aeff6da9519e9ec4224b1614defe759e138d3f32b4ad36fc964650473b1d95

See more details on using hashes here.

File details

Details for the file robotchallenge-1.0.1-py3-none-any.whl.

File metadata

  • Download URL: robotchallenge-1.0.1-py3-none-any.whl
  • Upload date:
  • Size: 10.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.63.0 importlib-metadata/4.11.2 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.10

File hashes

Hashes for robotchallenge-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 9d937667c7278b1c6a170668f11bad200129fb7bbc32cdb85ec648376683c3f6
MD5 d526c10fd9e6e087b348583b192b74e3
BLAKE2b-256 c405b9c40a70edb1e94fb0b53be093b7eb04f8bdaa29a1e5b197f951a4f50078

See more details on using hashes here.

Supported by

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