Skip to main content

Django app that import and correlating data from external sources.

Project description

innovativeproject-django-sourcerer

Links

Install

pip install django-sourcerer

Usage

Add django_sourcerer and rest_framework texts to settings.py under INSTALLED_APPS list.

INSTALLED_APPS=[
    ... 
    'django_sourcerer',
    'rest_framework'
]

Add also to settings.py information that where the config file is located.

SOURCERER_CONFIG_FILES = [
    "project_path/example.yaml"
]

Then run following commands:

./manage.py makemigrations django_sourcerer
./manage.py migrate

For update objects from source type following command:

./manage.py update_objects

For view in API Framework add following lines of code to your urls.py :

from django.urls import path, include
from django_sourcerer.urls import django_sourcerer_urls

urlpatterns = [
    path('', include(django_sourcerer_urls().urls))
]

Then just start the API ./manage.py runserver .

Library works with csv datas now. It will be updated for json&xls formats.

Example .yaml File

name: <name of data source>
source: <endpoint of data source>
format: csv
columns:
  - external_name: <column name>
    type: <column type e.g : int>
  - external_name: <column name>
    type: <column type e.g : str>

Requires

  • Python 3

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

django_sourcerer-2.0.tar.gz (7.5 kB view details)

Uploaded Source

Built Distribution

django_sourcerer-2.0-py3-none-any.whl (11.1 kB view details)

Uploaded Python 3

File details

Details for the file django_sourcerer-2.0.tar.gz.

File metadata

  • Download URL: django_sourcerer-2.0.tar.gz
  • Upload date:
  • Size: 7.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.2

File hashes

Hashes for django_sourcerer-2.0.tar.gz
Algorithm Hash digest
SHA256 6c858fbc3f5845b09f61711cdfce46fc46d8b8411dc8cdce5e4ad3ee607658cc
MD5 ac862453f5d06465694539b80025a621
BLAKE2b-256 06d41b695b54d6218989f785e5323ef43638d9bfb0524c6c62ddc5c19ac06b5d

See more details on using hashes here.

File details

Details for the file django_sourcerer-2.0-py3-none-any.whl.

File metadata

  • Download URL: django_sourcerer-2.0-py3-none-any.whl
  • Upload date:
  • Size: 11.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.45.0 CPython/3.8.2

File hashes

Hashes for django_sourcerer-2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 f4e15e40318da8883afd15b18de47a481e6dd495d66ef7775d23fd5919961b23
MD5 d9f5ad20b955645ce4fe0428bae2925c
BLAKE2b-256 3b1812df9a6aebddce116b6bd395f7c119b308e1c5f444847b780ee471da0709

See more details on using hashes here.

Supported by

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