[ckan-dev] Problem adding datasets using sh script.

Isabel Ruiz isaruizmellado at gmail.com
Wed Feb 4 12:29:21 UTC 2015


Hi Matt,

Yes I had tried this command, but I still have this problem.

Console show this:

2015-02-04 13:26:59,778 DEBUG [ckanext.spatial.model.package_extent]
Spatial tables defined in memory
2015-02-04 13:26:59,784 DEBUG [ckanext.spatial.model.package_extent]
Spatial tables already exist
2015-02-04 13:26:59,789 INFO  [ckan.lib.search] Rebuilding search index...
2015-02-04 13:26:59,794 INFO  [ckan.lib.search] Rebuilding the whole
index...
2015-02-04 13:27:11,898 INFO  [ckan.lib.search] Finished rebuilding search
index.
2015-02-04 13:27:11,951 INFO  [ckan.lib.search] Commited pending changes on
the search index




On Wed, Feb 4, 2015 at 1:19 PM, Matt Fullerton <matt.fullerton at okfn.de>
wrote:

> Hi Isabel,
> Have you tried
>
> paster --plugin=ckan search-index rebuild -c path/to/production.ini
>
> ?
>
> --
> Matt Fullerton
> Softwareentwickler
> matt.fullerton at okfn.de
> +49 89 74560495
> Open Knowledge Foundation Deutschland e.V.
> Singerstr. 109
> 10179 Berlin
> http://www.okfn.de
>
> On 3 February 2015 at 10:06, Isabel Ruiz <isaruizmellado at gmail.com> wrote:
>
>> Hi,
>>
>> We are running CKAN 2.2. in Ubuntu..
>> We have datastore and datapusher.
>> Actually we have more than 300 datasets on CKAN and it works fine!
>>
>> We want to add more than 100 new datasets, so we want to create a sh
>> batch file for it.
>>
>> We have executed sh file (I attached it) adding one dataset, and this
>> process does not return errors.
>>
>>
>> We have these problems:
>>
>> 1- If we go to "datasets list": we notice that this text: "XXX datasets
>> found" doesn't count new dataset.
>> 2- "datasets list" does not include our new dataset, I mean: it seems our
>> dataset doesn't exists.
>> 3- If we looking for our new dataset using "Search datasets": It does not
>> find these new dataset.
>>
>> If we....
>> 1- If we go to organizations and we select it organization: CKAN shows me
>> my new dataset.
>> 2- If we go to groups and we select it group: CKAN shows me my new
>> dataset, too.
>> 3- If we select my new dataset I can see that each field has been created
>> correctly.
>> 4- We have used curl command too, and we have same problem.
>> 5- We have executed this command (I dont know if it is necessary), but we
>> have same problems we have told you: reindex paster command: paster
>> --plugin=ckan search-index rebuild --config=/etc/ckan/default/inifile.ini
>>
>>
>> What can be wrong with this process?
>>
>> Thanks !
>>
>>
>> malaga = ckanapi.RemoteCKAN('URL',
>>   apikey='ourapikey',
>>   user_agent='useragent')
>>
>>     package=malaga.action.package_create(
>>       name="name",
>>       title="title",
>>       author="Author",
>>       author_email="email at malaga.eu",
>>       license_id="cc-by-sa",
>>       notes="Notes",
>>       state="active",
>>       type="package",
>>       tags=[{"display_name": "tagdisplay1", "name": "tagname1", "state":
>> "active"}, {"display_name": "tagdisplay2", "name": "tagname2", "state":
>> "active"}],
>>       extras=[{"key": "key1", "value": "key2"}],
>>       owner_org="organization name")
>>
>>     group=malaga.action.member_create(
>>       id="id",
>>       object=package['id'],
>>       object_type="package",
>>       capacity="admin")
>>
>>     resource = malaga.action.resource_create(
>>       package_id=package['id'],
>>       url="validURL",
>>       description="description",
>>       format='csv',
>>       name="CSV",
>>       resource_type='file',
>>       mimetype='text/csv',
>>       size=os.path.getsize(sys.argv[1]),
>>       webstore_url='active')
>>
>>
>>
>>
>> --
>> Isabel M. Ruiz Mellado
>> http://about.me/isabelruiz
>>
>> _______________________________________________
>> ckan-dev mailing list
>> ckan-dev at lists.okfn.org
>> https://lists.okfn.org/mailman/listinfo/ckan-dev
>> Unsubscribe: https://lists.okfn.org/mailman/options/ckan-dev
>>
>>
>
> _______________________________________________
> ckan-dev mailing list
> ckan-dev at lists.okfn.org
> https://lists.okfn.org/mailman/listinfo/ckan-dev
> Unsubscribe: https://lists.okfn.org/mailman/options/ckan-dev
>
>


-- 
Isabel M. Ruiz Mellado
http://about.me/isabelruiz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-dev/attachments/20150204/547f921a/attachment-0003.html>


More information about the ckan-dev mailing list