{ "info": { "author": "Open Knowledge International", "author_email": "info@okfn.org", "bugtrack_url": null, "classifiers": [ "Development Status :: 4 - Beta", "Environment :: Web Environment", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 3.6", "Topic :: Internet :: WWW/HTTP :: Dynamic Content", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "datapackage-pipelines-ckan\n==========================\n\n| |Travis|\n| |Coveralls|\n| |PyPi|\n| |SemVer|\n| |Gitter|\n\n`Data Package\nPipelines `__\nprocessors for `CKAN `__.\n\nInstall\n-------\n\n::\n\n # clone the repo and install it with pip\n\n git clone https://github.com/frictionlessdata/datapackage-pipelines-ckan.git\n pip install -e .\n\nUsage\n-----\n\ndatapackage-pipelines-ckan contains several pipeline processors for\nworking with CKAN.\n\n``ckan.add_ckan_resource``\n~~~~~~~~~~~~~~~~~~~~~~~~~~\n\nA processor to retrieve metadata about a CKAN resource from a CKAN\ninstance and add it as a datapackage resource.\n\n.. code:: yaml\n\n run: ckan.add_ckan_resource\n parameters:\n ckan-host: http://demo.ckan.org\n resource-id: d51c9bd4-8256-4289-bdd7-962f8572efb0\n ckan-api-key: env:CKAN_API_KEY # an env var defining a ckan user api key\n\n- ``ckan-host``: The base url (and scheme) for the CKAN instance (e.g.\n http://demo.ckan.org).\n- ``resource-id``: The id of CKAN resource\n- ``ckan-api-key``: Either a CKAN user api key or, if in the format\n ``env:CKAN_API_KEY_NAME``, an env var that defines an api key.\n Optional, but necessary for private datasets.\n\n``ckan.dump.to_ckan``\n~~~~~~~~~~~~~~~~~~~~~\n\nA processor to save a datapackage and resources to a specified CKAN\ninstance.\n\n.. code:: yaml\n\n run: ckan.dump.to_ckan\n parameters:\n ckan-host: http://demo.ckan.org\n ckan-api-key: env:CKAN_API_KEY\n overwrite_existing: true\n push_resources_to_datastore: true\n dataset-properties:\n name: test-dataset-010203\n state: draft\n private: true\n owner_org: my-test-org\n\n- ``ckan-host``: The base url (and scheme) for the CKAN instance (e.g.\n http://demo.ckan.org).\n- ``ckan-api-key``: Either a CKAN user api key or, if in the format\n ``env:CKAN_API_KEY_NAME``, an env var that defines an api key.\n- ``overwrite_existing``: If ``true``, if the CKAN dataset already\n exists, it will be overwritten by the datapackage. Optional, and\n default is ``false``.\n- ``push_resources_to_datastore``: If ``true``, newly created resources\n will be pushed the CKAN DataStore. Optional, and default is\n ``false``.\n- ``push_resources_to_datastore_method``: Value is a string, one of\n 'upsert', 'insert' or 'update'. This will be the method used to add\n data to the DataStore (see\n https://ckan.readthedocs.io/en/latest/maintaining/datastore.html#ckanext.datastore.logic.action.datastore_upsert).\n Optional, the default is 'insert'.\n- ``dataset-properties``: An optional object, the properties of which\n will be used to set properties of the CKAN dataset.\n\nCKAN dataset from datapackage\n'''''''''''''''''''''''''''''\n\nThe processor first creates a CKAN dataset from the datapackage\nspecification, using the CKAN api\n```package_create`` `__.\nIf the dataset already exists, and parameter ``overwrite_existing`` is\n``True``, the processor will attempt to update the CKAN dataset using\n```package_update`` `__.\nAll existing resources and dataset properties will be overwritten.\n\nCKAN resources from datapackage resources\n'''''''''''''''''''''''''''''''''''''''''\n\nIf the CKAN dataset was successfully created or updated, the dataset\nresources will be created for each resource in the datapackage, using\n```resource_create`` `__.\nIf datapackage resource are marked for streaming (they have the\n``dpp:streamed=True`` property), resource files will be uploaded to the\nCKAN filestore. For example, remote resources may be marked for\nstreaming by the inclusion of the ``stream_remote_resources`` processor\nearlier in the pipeline.\n\nAdditionally, if ``push_resources_to_datastore`` is ``True``, the\nprocessor will push resources marked for streaming to the CKAN DataStore\nusing\n```datastore_create`` `__\nand\n```datastore_upsert`` `__.\n\n.. |Travis| image:: https://img.shields.io/travis/frictionlessdata/datapackage-pipelines-ckan/master.svg\n :target: https://travis-ci.org/frictionlessdata/datapackage-pipelines-ckan\n.. |Coveralls| image:: http://img.shields.io/coveralls/frictionlessdata/datapackage-pipelines-ckan/master.svg\n :target: https://coveralls.io/r/frictionlessdata/datapackage-pipelines-ckan?branch=master\n.. |PyPi| image:: https://img.shields.io/pypi/v/datapackage-pipelines-ckan.svg\n :target: https://pypi.python.org/pypi/datapackage-pipelines-ckan\n.. |SemVer| image:: https://img.shields.io/badge/versions-SemVer-brightgreen.svg\n :target: http://semver.org/\n.. |Gitter| image:: https://img.shields.io/gitter/room/frictionlessdata/chat.svg\n :target: https://gitter.im/frictionlessdata/chat\n\n", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/frictionlessdata/datapackage-pipelines-ckan", "keywords": "data,ckan", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "datapackage-pipelines-ckan", "package_url": "https://pypi.org/project/datapackage-pipelines-ckan/", "platform": "", "project_url": "https://pypi.org/project/datapackage-pipelines-ckan/", "project_urls": { "Homepage": "https://github.com/frictionlessdata/datapackage-pipelines-ckan" }, "release_url": "https://pypi.org/project/datapackage-pipelines-ckan/0.0.2b0/", "requires_dist": [ "datapackage-pipelines (<2.0,>=1.0)", "ckan-datapackage-tools", "tableschema-ckan-datastore", "pylama; extra == 'develop'", "tox; extra == 'develop'", "mock; extra == 'develop'", "requests-mock; extra == 'develop'" ], "requires_python": "", "summary": "{{ DESCRIPTION }}", "version": "0.0.2b0" }, "last_serial": 3754625, "releases": { "0.0.2b0": [ { "comment_text": "", "digests": { "md5": "c15249c9cde33748d2a322eb1be92ef7", "sha256": "df9946173a2de95ccf67e1f277b9409e5fa032b1128d2ed7bcf3146e92e5c264" }, "downloads": -1, "filename": "datapackage_pipelines_ckan-0.0.2b0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c15249c9cde33748d2a322eb1be92ef7", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 10817, "upload_time": "2017-10-31T16:58:19", "url": "https://files.pythonhosted.org/packages/85/11/0eca89aad50d429d05e48e637e734636e05931a027617dd55f2d870d222a/datapackage_pipelines_ckan-0.0.2b0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "0493dfc42b26dca585ee3ae127ecb069", "sha256": "1c08f59ac0aa8d04e8610354d37da30f4eaff446ad0d04bff9ff99a209f2a9b9" }, "downloads": -1, "filename": "datapackage-pipelines-ckan-0.0.2b0.tar.gz", "has_sig": false, "md5_digest": "0493dfc42b26dca585ee3ae127ecb069", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 93595, "upload_time": "2017-10-31T16:58:21", "url": "https://files.pythonhosted.org/packages/0c/fd/05f410abde277e6cd95ae258de4f56b0c89f8a41148e3cbd318b6e829141/datapackage-pipelines-ckan-0.0.2b0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "c15249c9cde33748d2a322eb1be92ef7", "sha256": "df9946173a2de95ccf67e1f277b9409e5fa032b1128d2ed7bcf3146e92e5c264" }, "downloads": -1, "filename": "datapackage_pipelines_ckan-0.0.2b0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "c15249c9cde33748d2a322eb1be92ef7", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 10817, "upload_time": "2017-10-31T16:58:19", "url": "https://files.pythonhosted.org/packages/85/11/0eca89aad50d429d05e48e637e734636e05931a027617dd55f2d870d222a/datapackage_pipelines_ckan-0.0.2b0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "0493dfc42b26dca585ee3ae127ecb069", "sha256": "1c08f59ac0aa8d04e8610354d37da30f4eaff446ad0d04bff9ff99a209f2a9b9" }, "downloads": -1, "filename": "datapackage-pipelines-ckan-0.0.2b0.tar.gz", "has_sig": false, "md5_digest": "0493dfc42b26dca585ee3ae127ecb069", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 93595, "upload_time": "2017-10-31T16:58:21", "url": "https://files.pythonhosted.org/packages/0c/fd/05f410abde277e6cd95ae258de4f56b0c89f8a41148e3cbd318b6e829141/datapackage-pipelines-ckan-0.0.2b0.tar.gz" } ] }