Code Monkey home page Code Monkey logo

bayfordbury_project's Introduction

Bayfordbury_project

NOTE : THIS IS WORK IN PROGRESS AND ONLY MEANT FOR DEVELOPMENT FOR NOW

Github repository for the Bayfordbury project code.

If you want to contribute, please read the guidelines below to make development easier for everybody, including you.

Notes for contributors

Useful links:

101 (explains the basics) : Creating packages in python

102 (basics and some more details): Structuring your project

Please read the above first.

Tests

Writing tests for the modules helps minimising bugs in the package. Look over the existing files in the tests folder to see how to write a test and look at the documentation

To access the Bayfordbury archive (and test the queries) you need an API key and your Observer ID, you can get those in your account. credentials_example.py is an example of a credentials file. Make one in tests/ or scripts/ directories and import them to the scripts/tests (see tests/test_api.py for an example). Everyone has their own set of credentials and should create their own credentials.py, it is added to .gitignore and should not appear in the repository, only locally.

To run all tests in the directory, run

python -m unittest discover tests

in the root directory.

To execute a specific test, cd to the tests directory and run

python -m unittest -v <test_name>

where <test_name> is a name of a test file, e.g. test_api.

It is generally a good practice to make sure the code passes all the tests before pushing it to the repository (except if you raise NotImplementedError, but that's also not great). When you implement a feature, write a test for it. It should be a simple function that tests basic functionality of a function/class and MUST work at all times.

You can also make your IDE/editor (PyCharm, VSCode, a bit harder in Sublime Text) run and debug all the tests with a click of a button.

Requirements

  • Python 2.7 or higher
  • astropy

Installation

via cloning the repository

git clone https://github.com/herts-astrostudents/Bayfordbury_project.git
cd Bayfordbury_project
python setup.py install

via pip

pip install git+https://github.com/herts-astrostudents/Bayfordbury_project.git -U

Uninstall

pip uninstall bayfordbury

Files and Folders

bayfordbury - folder with modules and all the publishable/installable code.

tests - folder with tests.

docs - documentation for this package, to be created!.

scripts - folder with relevant scripts. Not used as a part of the package, just the scripts to run directly for any purpose.

setup.py - package installation file. Read how to use it: Creating packages in python.

LICENCE - GNU General Public License v3.0.

.gitignore - list of files to not add to this repository, like the compiled files (*.pyc).

README.md - this file.

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.