Skip to main content
Join the official 2019 Python Developers SurveyStart the survey!

Collecion of helper modules for the Dakara Project

Project description

Dakara Base

Travis CI Build Status Appveyor Build status Codecov coverage analysis Code style: black PyPI version PyPI Python versions

This project is a collection of tools and helper modules for the Dakara Project.

Modules available

  • config: a configuration helper that can load an YAML file and manage loggers;
  • exceptions: a base class for exceptions;
  • http_client: an HTTP client dedicated to be used with an API;
  • progress_bar: a collection of progress bars;
  • resources_manager: a helper for retreiving static files with module-like naming;
  • safe_workers: a library to facilitate the manipulation of threads;
  • utils: other various helpers;
  • websocket_client: a Websocket client.

Install

Install the package with:

pip install dakarabase

If you have downloaded the repo, you can install the package directly with:

python setup.py install

Developpment

Install dependencies

Please ensure you have a recent enough version of setuptools:

pip install --upgrade "setuptools>=40.0"

Install the dependencies with:

pip install -e ".[tests]"

This installs the normal dependencies of the package plus the dependencies for tests.

Run tests

Run tests simply with:

python setup.py test

To check coverage, use the coverage command:

coverage run setup.py test
coverage report -m

Hooks

Git hooks are included in the hooks directory.

Use the following command to use this hook folder for the project:

git config core.hooksPath hooks

If you're using git < 2.9 you can make a symlink instead:

ln -s -f ../../hooks/pre-commit .git/hooks/pre-commit

Code style

The code follows the PEP8 style guide (88 chars per line). Quality of code is checked with Flake8. Style is enforced using Black. You need to call Black before committing changes. You may want to configure your editor to call it automatically. Additionnal checking can be manually performed with Pylint.

MIT License

Copyright (c) 2019 Dakara Project

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for dakarabase, version 1.2.0
Filename, size File type Python version Upload date Hashes
Filename, size dakarabase-1.2.0-py3-none-any.whl (23.1 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size dakarabase-1.2.0.tar.gz (33.2 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page