[ECODP-dev] curl package_show

David Raznick david.raznick at okfn.org
Wed Dec 18 11:14:48 UTC 2013


Hello

I am not sure of the correct behaviour here, these issues, I think are
due to customized schema for ecodp.   We have changed this behaviour
in recent versions of CKAN

This should be the fields it effects.

            'alternative_title'
            'release_date'
            'modified_date'
            'accrual_periodicity'
            'temporal_coverage_from'
            'temporal_coverage_to'
            'metadata_language'
            'version_description'
            'contact_name'
            'contact_email'
            'contact_address'
            'contact_telephone'
            'contact_webpage'

These fields are actually contain json data on package_show.   So when
you post it back you may need to un json them to convert them to
strings.  For your case you can probably just not supply them back as
you need only to modify the resource fields.

David


On 18 December 2013 10:39, Bert Van Nuffelen
<bert.van.nuffelen at tenforce.com> wrote:
> Hi David,
>
> I do a curl package_show to get the content of a dataset,
> but it returns me a strange result.
>
> Namely some fields are encapsulated in explicit quoted syle like this
> "\"....\""
>
> Is that standard CKAN behaviour (1.8) ?
>
> because if I take that json and use it as is to submit back using
> package_update
> I get validation error.
>
> here is the command used:
>
> curl -X POST "http://localhost/data/api/3/action/$2" -d @$3 -H
> "Authorization: $1" -H "Content-Type: application/json"
>
> kind regards,
>
> Bert
>
>
>
>
> --
> Bert Van Nuffelen
>
> Semantic Technologies Software Architect at TenForce
> www.tenforce.be
>
> Bert.Van.Nuffelen at tenforce.com
> Office: +32 (0)16 31 48 60
> Mobile:+32 479 06 24 26
> skype: bert.van.nuffelen
>
> _______________________________________________
> ecodp-dev mailing list
> ecodp-dev at lists.okfn.org
> https://lists.okfn.org/mailman/listinfo/ecodp-dev
>



More information about the ecodp-dev mailing list