pduchesne / ckanext-geoview Goto Github PK
View Code? Open in Web Editor NEWCKAN Geospatial ResourceView
License: MIT License
CKAN Geospatial ResourceView
License: MIT License
I'd like to konw if someone is working in this issue, as on October 31st, the base maps will no longer be visible
Hi all,
My ckan develop instance does not start after upgrading from 2.6.2 to 2.6.6
This is the error:
$ paster serve /etc/ckan/default/development.ini
Traceback (most recent call last):
File "/usr/lib/ckan/default/bin/paster", line 11, in <module>
sys.exit(run())
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 102, in run
invoke(command, command_name, options, args[1:])
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 141, in invoke
exit_code = runner.run(args)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 236, in run
result = self.command()
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/serve.py", line 284, in command
relative_to=base, global_conf=vars)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/serve.py", line 329, in loadapp
**kw)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", line 247, in loadapp
return loadobj(APP, uri, name=name, **kw)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", line 272, in loadobj
return context.create()
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", line 710, in create
return self.object_type.invoke(self)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/deploy/loadwsgi.py", line 146, in invoke
return fix_call(context.object, context.global_conf, **context.local_conf)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/deploy/util.py", line 55, in fix_call
val = callable(*args, **kw)
File "/usr/lib/ckan/default/src/ckan/ckan/config/middleware/__init__.py", line 45, in make_app
load_environment(conf, app_conf)
File "/usr/lib/ckan/default/src/ckan/ckan/config/environment.py", line 97, in load_environment
p.load_all()
File "/usr/lib/ckan/default/src/ckan/ckan/plugins/core.py", line 139, in load_all
load(*plugins)
File "/usr/lib/ckan/default/src/ckan/ckan/plugins/core.py", line 153, in load
service = _get_service(plugin)
File "/usr/lib/ckan/default/src/ckan/ckan/plugins/core.py", line 256, in _get_service
raise PluginNotFoundException(plugin_name)
ckan.plugins.core.PluginNotFoundException: geojson_view
Any help is appreciated. Thanks!
(default)[root@ckanhost1 default]# paster --plugin=ckanext-harvest harvester jobs
Traceback (most recent call last):
File "/usr/lib/ckan/default/lib64/python2.7/site.py", line 890, in <module>
main()
File "/usr/lib/ckan/default/lib64/python2.7/site.py", line 848, in main
virtualenv_search_paths(sys.prefix)
File "/usr/lib/ckan/default/lib64/python2.7/site.py", line 638, in virtualenv_search_paths
addsitedir(sitedir, known_paths)
File "/usr/lib/ckan/default/lib64/python2.7/site.py", line 204, in addsitedir
addpackage(sitedir, name, known_paths)
File "/usr/lib/ckan/default/lib64/python2.7/site.py", line 173, in addpackage
exec(line)
File "<string>", line 1, in <module>
KeyError: 'ckanext'
Another user posted pretty much the same problem in a forked repo here ckan#39 - not sure which repository to post though. I am also not sure whether this is a problem related to ckanext-geoview
or ckan
itself.
Could the problem be related to an update from ckanext-geoview-0.0.7 to ckanext-geoview-0.0.9?
I prefer this repository as it provides the possibility to differ the base map from the spatial widget (ckanext-spatial).
I test the latest branch "Master" and it doesn't add any kml layer. However, it works for wms.
So, I assume the implementation is fine but just doesn't work with kml. I tested different kml files, still no success.
Is this a bug or am I doing something wrong?
inside the basemaps.json I have OpenStreepMap and mapbox (but only it reads the first one which is OSM).
I am using ckan 2.8.0 on my local machine.
@pduchesne I'm setting some time aside to review this and make it ready for CKAN 2.3. I started working on my fork (https://github.com/amercader/ckanext-geoview) with the intention to move it to the ckan github organization once it's ready. Are you happy with this? Of course you and others would be set up as admins for it.
Just a couple of questions.
resource_proxy
functionality locally because the core one will ignore the parameters being sent? eg ?service=WMS&request=GetCapabilities
On import phase, the following gets thrown by geoview:
$ paster --plugin=ckanext-harvest harvester import --config /etc/ckan/default/development.ini
/usr/lib/ckan/default/src/ckan/ckan/new_authz.py:6: FutureWarning: ckan.new_authz has been renamed to ckan.authz. The ckan.new_authz module will be removed in a future release.
FutureWarning)
2015-10-17 09:06:50,410 DEBUG [ckanext.spatial.model.package_extent] Spatial tables defined in memory
2015-10-17 09:06:50,417 DEBUG [ckanext.spatial.model.package_extent] Spatial tables already exist
2015-10-17 09:06:50,431 DEBUG [ckanext.harvest.model] Harvest tables defined in memory
2015-10-17 09:06:50,432 DEBUG [ckanext.harvest.model] Harvest tables already exist
2015-10-17 09:06:50,478 DEBUG [ckanext.harvest.model] Harvest tables already exist
DB tables created
2015-10-17 09:06:50,483 INFO [ckanext.harvest.logic.action.update] Harvest objects import: {'source_id': None, 'package_id': False, 'harvest_object_id': False}
2015-10-17 09:06:50,494 DEBUG [ckanext.dcat.harvesters.rdf] In DCATRDFHarvester import_stage
/usr/lib/ckan/default/local/lib64/python2.7/site-packages/sqlalchemy/orm/unitofwork.py:79: SAWarning: Usage of the 'related attribute set' operation is not currently supported within the execution stage of the flush process. Results may not be consistent. Consider using alternative event listeners or connection-level operations instead.
sess._flush_warning("related attribute set")
2015-10-17 09:06:50,599 DEBUG [ckanext.spatial.plugin] Received: u'{"type": "Polygon", "coordinates": [[[-180.0, -90.0], [180.0, -90.0], [180.0, 90.0], [-180.0, 90.0], [-180.0, -90.0]]]}'
2015-10-17 09:06:50,610 DEBUG [ckanext.spatial.lib] Extent for package 1e85a8ef-efcc-4fa1-a40a-3cc1bec5c8bc unchanged
Traceback (most recent call last):
File "/usr/lib/ckan/default/bin/paster", line 9, in <module>
load_entry_point('PasteScript==1.7.5', 'console_scripts', 'paster')()
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 104, in run
invoke(command, command_name, options, args[1:])
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 143, in invoke
exit_code = runner.run(args)
File "/usr/lib/ckan/default/local/lib/python2.7/site-packages/paste/script/command.py", line 238, in run
result = self.command()
File "/usr/lib/ckan/default/src/ckanext-harvest/ckanext/harvest/commands/harvester.py", line 152, in command
self.import_stage()
File "/usr/lib/ckan/default/src/ckanext-harvest/ckanext/harvest/commands/harvester.py", line 325, in import_stage
'package_id': self.options.package_id,
File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 429, in wrapped
result = _action(context, data_dict, **kw)
File "/usr/lib/ckan/default/src/ckanext-harvest/ckanext/harvest/logic/action/update.py", line 273, in harvest_objects_import
harvester.import_stage(obj)
File "/usr/lib/ckan/default/src/ckanext-dcat/ckanext/dcat/harvesters/rdf.py", line 284, in import_stage
p.toolkit.get_action('package_update')(context, dataset)
File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 429, in wrapped
result = _action(context, data_dict, **kw)
File "/usr/lib/ckan/default/src/ckan/ckan/logic/action/update.py", line 371, in package_update
{'package': data})
File "/usr/lib/ckan/default/src/ckan/ckan/logic/__init__.py", line 429, in wrapped
result = _action(context, data_dict, **kw)
File "/usr/lib/ckan/default/src/ckan/ckan/logic/action/create.py", line 468, in package_create_default_resource_views
create_datastore_views=create_datastore_views)
File "/usr/lib/ckan/default/src/ckan/ckan/lib/datapreview.py", line 303, in add_views_to_dataset_resources
create_datastore_views)
File "/usr/lib/ckan/default/src/ckan/ckan/lib/datapreview.py", line 261, in add_views_to_resource
'package': dataset_dict
File "/usr/lib/ckan/default/src/ckanext-geoview/ckanext/geoview/plugin.py", line 279, in can_view
format_lower = resource['format'].lower()
KeyError: 'format'
And I have no clue how to recover from that, since none of the clear or purge operations seem to work since the DB entries are now in an inconsistent state somehow. When I try to clear jobs I get:
An error occurred: [(IntegrityError) update or delete on table "package" violates foreign key constraint "harvest_object_package_id_fkey" on table "harvest_object" DETAIL: Key (id)=(1e85a8ef-efcc-4fa1-a40a-3cc1bec5c8bc) is still referenced from table "harvest_object". "begin; \n update package set state = 'to_delete' where id in (select package_id from harvest_object where harvest_source_id = 'fd15d7cd-b576-4577-acbb-7246eee9b41e');\n delete from resource_view where resource_id in (select id from resource where package_id in (select id from package where state = 'to_delete' ));\n delete from resource_revision where package_id in (select id from package where state = 'to_delete' );\n delete from resource where package_id in (select id from package where state = 'to_delete' );\n \n delete from harvest_object_error where harvest_object_id in (select id from harvest_object where harvest_source_id = 'fd15d7cd-b576-4577-acbb-7246eee9b41e');\n delete from harvest_object_extra where harvest_object_id in (select id from harvest_object where harvest_source_id = 'fd15d7cd-b576-4577-acbb-7246eee9b41e');\n delete from harvest_object where harvest_source_id = 'fd15d7cd-b576-4577-acbb-7246eee9b41e';\n delete from harvest_gather_error where harvest_job_id in (select id from harvest_job where source_id = 'fd15d7cd-b576-4577-acbb-7246eee9b41e');\n delete from harvest_job where source_id = 'fd15d7cd-b576-4577-acbb-7246eee9b41e';\n delete from package_role where package_id in (select id from package where state = 'to_delete' );\n delete from user_object_role where id not in (select user_object_role_id from package_role) and context = 'Package';\n delete from package_tag_revision where package_id in (select id from package where state = 'to_delete');\n delete from member_revision where table_id in (select id from package where state = 'to_delete');\n delete from package_extra_revision where package_id in (select id from package where state = 'to_delete');\n delete from package_revision where id in (select id from package where state = 'to_delete');\n delete from package_tag where package_id in (select id from package where state = 'to_delete');\n delete from package_extra where package_id in (select id from package where state = 'to_delete');\n delete from package_relationship_revision where subject_package_id in (select id from package where state = 'to_delete');\n delete from package_relationship_revision where object_package_id in (select id from package where state = 'to_delete');\n delete from package_relationship where subject_package_id in (select id from package where state = 'to_delete');\n delete from package_relationship where object_package_id in (select id from package where state = 'to_delete');\n delete from member where table_id in (select id from package where state = 'to_delete');\n delete from related_dataset where dataset_id in (select id from package where state = 'to_delete');\n delete from related where id in ('');\n delete from package where id in (select id from package where state = 'to_delete');\n commit;\n " {}]
CKAN and ckanext-spatial are now using Stamen map tiles as the default map tiles, following MapQuest changing their access terms and requiring an account. It would be great if geoview used the same default.
We use the package ckanext-geoview inside with a old version of CKAN.
We le GIP Terrritoires Numériques Bourgogne Franche Comté wish tu update all thes used packages, for https://ideo.ternum-bfc.fr/
If interessed, could you provide an estimate of the devs.
There will be probablement some technicale exchange with our provider.
Best regards,
jerome boutet
IDéO BFC
Hi Philippe
I have installed the extension as per readme, but I am not able to get the preview. No error is coming either in JS or in CKAN. Are there any dependencies that I need to install for ckanext-geoview to work properly.
The preview is completely blank page. Attaching the screenshot for the same.
Loading... The text is coming and after that, it went blank.
Thanks
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.