[ckan-dev] A new ckan client library: ckanapi

Heinrich Widmann widmann at dkrz.de
Wed Apr 24 15:40:31 UTC 2013


echam5_mpi-om_dmi_eh5_run4_a1b_sf


Am 24.04.2013 13:28, schrieb John Mrziglod:
> Hello Ian Ward,
> I have used your ckanapi client to update an existing package 'extratest'.
> My code looks this:
> response = ckan_object.call_action(action,object);
> It works fine by using 'action=package_update' with default fields, e.g.:
> object = {"name":"extratest","title":"Test with Extras"}
> But what I need is an update with an extras data field, i.e.:
> object = {"name":"extratest","title":"Test with Extras","extras": 
> [{"key": "config",  "value": "xxx"}]}
> But I got no response from the shell and no errors occured.
> Did I use the right syntax for the extras field dictionary?
> Thanks for any help.
> John Mrziglod
> *Gesendet:* Dienstag, 16. April 2013 um 16:11 Uhr
> *Von:* "Heinrich Widmann" <widmann at dkrz.de>
> *An:* "John Mrziglod" <mrzo at gmx.de>
> *Betreff:* Fwd: [ckan-dev] A new ckan client library: ckanapi
>
>
> -------- Original-Nachricht --------
> Betreff: 	[ckan-dev] A new ckan client library: ckanapi
> Datum: 	Fri, 12 Apr 2013 11:11:25 -0400
> Von: 	Ian Ward <ian at excess.org>
> Antwort an: 	CKAN Development Discussions <ckan-dev at lists.okfn.org>
> An: 	CKAN Development Discussions <ckan-dev at lists.okfn.org>
>
> I've separated out my CKAN Action API wrapper into a separate project.
> To try it out:
>
>    pip install ckanapi
>
> Then in a Python shell/script:
>
>    import ckanapi
>    import pprint
>
>    demo = ckanapi.RemoteCKAN('http://demo.ckan.org')
>    groups = demo.action.group_list(id='data-explorer')
>    pprint.pprint(groups)
>
> More details here:https://github.com/open-data/ckanapi
>
> Contributions welcome! (especially for filestore, unit tests and other
> things I'm missing)
>
> Ian
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> http://lists.okfn.org/mailman/listinfo/ckan-dev
> Unsubscribe:http://lists.okfn.org/mailman/options/ckan-dev
>
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> http://lists.okfn.org/mailman/listinfo/ckan-dev
> Unsubscribe: http://lists.okfn.org/mailman/options/ckan-dev

-- 
-----------------------------\\---------------------------------------
Heinrich Widmann              \\ Deutsches Klimarechenzentrum GmbH
Phone: +49 40 460094 282       \\   Abteilung Datenmanagement
FAX:   +49 40 460094 270        \\    Bundesstr. 45a
Email: widmann at dkrz.de           \\   D-20146 Hamburg
http://www.dkrz.de                \\  Germany
-----------------------------------\\---------------------------------

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20130424/1e19245e/attachment-0001.html>


More information about the ckan-dev mailing list