cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results for 
Search instead for 
Did you mean: 

Can't import st_constructors module after installing Apache Sedona

jgsp
New Contributor II

Hi there,

I've recently installed Apache Sedona on my cluster, according to the detailed instructions here. My Databricks runtime version is 9.1 LTS (includes Apache Spark 3.1.2, Scala 2.12).

The installation included the apache-sedona library from PyPI, and the following Maven Coordinates:

org.apache.sedona:sedona-python-adapter-3.0_2.12:1.2.1-incubating

org.datasyslab:geotools-wrapper:1.1.0-25.2

The installation was successful. Unfortunately, when I try to import the st_constructors as instructed here, I get the following error:

from sedona.sql import st_constructors as stc
 
# ImportError: cannot import name 'st_constructors' from 'sedona.sql' (/databricks/python/lib/python3.8/site-packages/sedona/sql/__init__.py)

What am I doing wrong here?

Many thanks for your help.

2 REPLIES 2

Debayan
Databricks Employee
Databricks Employee

Hi @Jonathan Gat​ , Can you try to uploading the executable PyPI file to DBFS and try to install it from there? You can refer: https://docs.databricks.com/libraries/index.html

jgsp
New Contributor II

Thank you @Debayan Mukherjee​ for the prompt reply. I've followed the instructions carefully, but now every time I try to run a cell in my notebook I get a "Cancelled" message. It clearly didn't work. Any advice?

Your help is much appreciated.

Connect with Databricks Users in Your Area

Join a Regional User Group to connect with local Databricks users. Events will be happening in your city, and you won’t want to miss the chance to attend and share knowledge.

If there isn’t a group near you, start one and help create a community that brings people together.

Request a New Group