Geospatial View does not work with NULL values

Hi,

my Geospatial View node does not work "ERROR Geospatial View 3:4 Execute failed: 'NoneType' object is not subscriptable" when there are Null values in LAT/LON columns.
Is this works as designed?

Thanks and cheers

Hello @Awiener ,
do you use the latest version (1.1.1) of the Geospatial Extension? We had problems with null values in earlier versions which should have been fixed in the latest version. I just tried the latest version with KNIME 4.7.5 and the node executed successfully:

image

However I’m not sure if it is a good idea to have NaN in the WKT if the coordinate is missing. We will look into this to see what we can do about it.
Bye
Tobias

P.s. I moved your post to the geospatial section to make it more visible to other user which might have the same problem. I hope this is ok :slight_smile:

1 Like

Hi @tobias.koetter ,

unfortunately still there:
Knime 4.7.5
image

I guess it has something to do with my workflow:
image

WARN  Geospatial View      3:146      Preset column to: geometry
WARN  Excel Reader         3:1        The node configuration changed and the table spec will be recalculated during execution.
ERROR Excel Reader         3:1        Problems during initialization of extension with id 'com.knime.server.nodes.filehandling.connector.ServerFSDescriptorProvider'.
ERROR Excel Reader         3:1        Extension null ignored.
WARN  Geospatial View      3:4        Traceback (most recent call last):
  File "C:\Program Files\KNIME\plugins\org.knime.python3.nodes_4.7.3.v202305081333\src\main\python\_node_backend_launcher.py", line 457, in execute
    outputs = self._node.execute(exec_context, *inputs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial_1.1.1.202306211527\src\main\python\src\nodes\visualize.py", line 542, in execute
    html = map.get_root().render()
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\branca\element.py", line 338, in render
    child.render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\folium.py", line 401, in render
    super().render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\elements.py", line 22, in render
    super().render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\branca\element.py", line 645, in render
    element.render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\features.py", line 782, in render
    super().render()
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\branca\element.py", line 645, in render
    element.render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\features.py", line 1116, in render
    self.warn_for_geometry_collections()
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\features.py", line 1096, in warn_for_geometry_collections
    geom_collections = [
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\features.py", line 1099, in <listcomp>
    if feature["geometry"]["type"] == "GeometryCollection"
TypeError: 'NoneType' object is not subscriptable

ERROR Geospatial View      3:4        Execute failed: 'NoneType' object is not subscriptable
WARN  Geospatial View      3:4        Traceback (most recent call last):
  File "C:\Program Files\KNIME\plugins\org.knime.python3.nodes_4.7.3.v202305081333\src\main\python\_node_backend_launcher.py", line 457, in execute
    outputs = self._node.execute(exec_context, *inputs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial_1.1.1.202306211527\src\main\python\src\nodes\visualize.py", line 542, in execute
    html = map.get_root().render()
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\branca\element.py", line 338, in render
    child.render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\folium.py", line 401, in render
    super().render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\elements.py", line 22, in render
    super().render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\branca\element.py", line 645, in render
    element.render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\features.py", line 782, in render
    super().render()
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\branca\element.py", line 645, in render
    element.render(**kwargs)
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\features.py", line 1116, in render
    self.warn_for_geometry_collections()
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\features.py", line 1096, in warn_for_geometry_collections
    geom_collections = [
  File "C:\Program Files\KNIME\plugins\sdl.harvard.geospatial.channel.bin.win32.x86_64_1.1.1.202306211527\env\lib\site-packages\folium\features.py", line 1099, in <listcomp>
    if feature["geometry"]["type"] == "GeometryCollection"
TypeError: 'NoneType' object is not subscriptable

ERROR Geospatial View      3:4        Execute failed: 'NoneType' object is not subscriptable

And thanks for changing the section, however I could not find or use “geospatial” when creating this issue.

Hi @Awiener -

Just quickly checking in, is this issue still present for you in 5.1?

Hi @ScottF

I am not able to install the Extension at 5.1 due to the ShellExec command exited non-zero exit value issue.

I will wait for a more robust version.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.