dj-hubspot - Django + HubSpot Made Easy
HubSpot Models for Django.
Introduction
dj-hubspot implements all of the HubSpot models, for Django. Set up your webhook endpoint and start receiving model updates. You will then have a copy of all the HubSpot models available in Django models, as soon as they are updated!
Features
- TODO
Requirements
- Django >=3.2
- Python >=3.8
- PostgreSQL engine (recommended) >=9.6
- MySQL engine: MariaDB >=10.2 or MySQL >=5.7
- SQLite: Not recommended in production. Version >=3.26 required.
Contribute
Django app template, using poetry-python as dependency manager.
This project is a template that can be cloned and re-used for redistributable apps.
It includes the following:
poetryfor dependency managementisort,black,pyupgradeandflake8lintingpre-committo run lintingmypyfor type checkingtoxand Github Actions for builds and CI
There are default config files for the linting and mypy.
Principles
The motivation for this project is to provide a consistent set of standards across all YunoJuno public Python/Django projects. The principles we want to encourage are:
- Simple for developers to get up-and-running
- Consistent style (
black,isort,flake8) - Future-proof (
pyupgrade) - Full type hinting (
mypy)
Versioning
We currently support Python 3.7+, and Django 3.2+. We will aggressively upgrade Django versions, and we won't introduce hacks to support breaking changes - if Django 4 introduces something that 2.2 doesn't support we'll drop it.
Coding style
We use pre-commit to run code quality tools.
Install pre-commit however you like (e.g. pip install pre-commit with your system python) then set up pre-commit to run every time you commit with:
> pre-commit install
You can then run all tools:
> pre-commit run --all-files
For more info, see the docs, or the code quality chapters in Boost Your Django DX.
Tests
Tests package
The package tests themselves are outside of the main library code, in
a package that is itself a Django app (it contains models, settings,
and any other artifacts required to run the tests (e.g. urls).) Where
appropriate, this test app may be runnable as a Django project - so that
developers can spin up the test app and see what admin screens look
like, test migrations, etc.
Running tests
The tests themselves use pytest as the test runner. If you have
installed the poetry evironment, you can run them thus:
$ poetry run pytest
or
$ poetry shell
(djhubspot) $ pytest
The full suite is controlled by tox, which contains a set of
environments that will format, lint, and test against all
support Python + Django version combinations.
$ tox
...
______________________ summary __________________________
fmt: commands succeeded
lint: commands succeeded
mypy: commands succeeded
py37-django22: commands succeeded
py37-django32: commands succeeded
py37-djangomain: commands succeeded
py38-django22: commands succeeded
py38-django32: commands succeeded
py38-djangomain: commands succeeded
py39-django22: commands succeeded
py39-django32: commands succeeded
py39-djangomain: commands succeeded
CI
There is a .github/workflows/tox.yml file that can be used as a
baseline to run all of the tests on Github. This file runs the oldest
(2.2), newest (3.2), and head of the main Django branch.
Metadata
Release files for dj-hubspot 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| dj-hubspot-0.1.1.tar.gz | 4.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| dj_hubspot-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 9.6 kB
Release files / dj-hubspot-0.1.1.tar.gz
| Download URL | dj-hubspot-0.1.1.tar.gz |
|---|---|
| Size | 4.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5dc48950d58d4557daf4cdbb66e63dc246c608bc1c0b1d6e9446220bba08b457
|
|
BLAKE2b-256 checksum How to use checksums |
cb0641ae0dd95ed5a465c10235fd76f1599ed99e0e7ff4ffa4f4f6fcb26ef46b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.2.1 CPython/3.10.5 Darwin/21.6.0
|
Release files / dj_hubspot-0.1.1-py3-none-any.whl
| Download URL | dj_hubspot-0.1.1-py3-none-any.whl |
|---|---|
| Size | 4.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
9923bb44b18ee38c56bf5895d3a256484b025461685f72f6c0f04694042e8294
|
|
BLAKE2b-256 checksum How to use checksums |
12b4a96f5d29aa569034498b1046672c9062e2062df3ef307d7000a6434b7f84
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.2.1 CPython/3.10.5 Darwin/21.6.0
|