Skip to content

Commit

Permalink
switching version check to spark session (capitalone#321)
Browse files Browse the repository at this point in the history
* switching version check to spark session

* bumping version
  • Loading branch information
fdosani authored Jul 10, 2024
1 parent d783b37 commit aefeec3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion datacompy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

__version__ = "0.13.1"
__version__ = "0.13.2"

import platform
from warnings import warn
Expand Down
4 changes: 1 addition & 3 deletions datacompy/spark/sql.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,6 @@
upper,
when,
)
from pyspark.version import __version__

except ImportError:
pass # Let non-Spark people at least enjoy the loveliness of the spark sql datacompy functionality

Expand Down Expand Up @@ -210,7 +208,7 @@ def _validate_dataframe(
"""
dataframe = getattr(self, index)

if __version__ >= "3.4.0":
if self.spark_session.version >= "3.4.0":
import pyspark.sql.connect.dataframe

instances = (pyspark.sql.DataFrame, pyspark.sql.connect.dataframe.DataFrame)
Expand Down

0 comments on commit aefeec3

Please sign in to comment.