Giter Site home page Giter Site logo

Study Buffalo

Codecov code coverage_ License_

The website and applications of the Study Buffalo.

What You Will Find

Hello, we are the Study Buffalo! We are excited to see you taking an interest in our project. This area is specifically the web hosting side of our projects. This website is currently created with the Django framework.

Licensing

We strive to keep our projects accessible to all. Everything here is open source under the GNU Public License version 3. We are always open to discussing other licensing options, so please contact us if this is an issue for you.

Contact Us

You can always get a hold of us at [email protected], [email protected], or through GitHub itself.

Setting Up Development Environment

  1. Install Python 3.8:
  2. Install PostgreSQL (version 9.4 or higher is required). You will need to create an admin account to create the required databases. You may use whatever interface you wish to run SQL commands; the following instructions assume you are using a commandline interace tool, such as psql.
  3. Once PostgreSQL is installed you will need to create a database and user for Django. The following provides a minimal setup with some sane defaults (you may update the database_name, user, and password sections to whatever you prefer):

    CREATE DATABASE database_name;
    CREATE USER user WITH PASSWORD 'password';
    ALTER ROLE user SET client_encoding TO 'utf8';
    ALTER ROLE user SET default_transaction_isolation TO 'read committed';
    ALTER ROLE user SET timezone TO 'UTC';
    GRANT ALL PRIVILEGES ON DATABASE database_name TO user;
    ALTER USER user CREATEDB;
    ALTER DATABASE database_name OWNER TO user;
  4. Install pipenv via command line:

    $ pip install pipenv
  5. Clone the github repository (https://github.com/studybuffalo/studybuffalo.git)
  6. In the /config/settings directory of the repo copy the .study_buffalo.env file and rename it study_buffalo.env
  7. If needed, update the variables in the study_buffalo.env file to use your database credentials and any secret keys/API details.
  8. In the root directory of the repository, run the Makefile install command to setup Django.

    You may setup the environment with no database content with the following command:

    $ make --file=Makefile install-development-fresh

    You may setup the environment with fixture content with the following command:

    $ make --file=Makefile install-development-fixtures
  9. You should now be able to run the Django development server. You can test this with the following command, which will generate output similar to below:

    $ pipenv run python manage.py runserver 127.0.0.1:8000
    
    > Performing system checks...
    > System check identified no issues (0 silenced).
    > Django version #.#.#, using settings 'config.settings.development'
    > Starting development server at http://127.0.0.1:8000/
    > Quit the server with CTRL-BREAK.
  10. If fixture data was loaded, the following user accounts will be available:

    DO NOT use these accounts in a production environment.

Running development server

To start the development server:

$ pipenv run python manage.py runserver 127.0.0.1:8000

Running Tests

To run tests:

$ pipenv run pytest

To generate coverage report:

# XML Report
$ pipenv run pytest --cov study_buffalo --cov-report xml

# HTML Report
$ pipenv run pytest --cov study_buffalo --cov-report html

Running Linters

To run linting:

# Run Pylint
$ pipenv run pylint study_buffalo/ config/

# Run Pycodestyle
$ pipenv run pycodestyle study_buffalo/ config/

Documentation Style

Docstrings are documented using the reStructuredText format. Details of this style can be found here: https://www.sphinx-doc.org/en/master/usage/restructuredtext/domains.html

Study Buffalo's Projects

data_validation_tool icon data_validation_tool

A GUI tool to review data extraction exceptions generated by other SB projects and verify them for production use

datafreedomtool icon datafreedomtool

Demo python project to explore automatic Turn-Around-Time (TAT) capture and presentation

django-newsletter icon django-newsletter

An email newsletter application for the Django web application framework, including an extended admin interface, web (un)subscription, dynamic e-mail templates, an archive and HTML email support.

dpd_data_extraction icon dpd_data_extraction

Takes the Health Canada Drug Product Database data extracts, parses them, and uploads them to a mysql database.

epid icon epid

Outlines and distributes the Equivalent Pharmaceutical ID database

jspdf-tb icon jspdf-tb

A repository to hold various tools to extend functionality of jsPDF, including table design and string measurement

meowth icon meowth

A Discord helper bot for Pokemon Go communities.

rx_list icon rx_list

Program that extracts all pharmacists and pharmacies from the ACP website

sb_dictionary_tool icon sb_dictionary_tool

A tool to take various Study Buffalo applications' data and upload words to be included in the Dictionary application

sb_log_manager icon sb_log_manager

Application that automates collection of Study Buffalo application log files for import into a Django database.

treasurer_tools icon treasurer_tools

A Django-based system to assist Non-Profit Organization treasurers in managing/tracking finances

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.