Skip to content

Commit ed709b7

Browse files
sfc-gh-efergusondangotbannedsfc-gh-joshiFBruzzesi
authored
fix(dependencies): update import check for modin.pandas module (#3219)
* update import check for modin.pandas module * Update narwhals/dependencies.py Use more specific variable name Co-authored-by: Dan Redding <[email protected]> * Update narwhals/dependencies.py Co-authored-by: Jonathan Shi <[email protected]> * fix indentation --------- Co-authored-by: Dan Redding <[email protected]> Co-authored-by: Jonathan Shi <[email protected]> Co-authored-by: Francesco Bruzzesi <[email protected]>
1 parent b6c900e commit ed709b7

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

narwhals/dependencies.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,7 @@ def get_pandas() -> Any:
5656

5757
def get_modin() -> Any: # pragma: no cover
5858
"""Get modin.pandas module (if already imported - else return None)."""
59-
if (modin := sys.modules.get("modin", None)) is not None:
60-
return modin.pandas
61-
return None
59+
return sys.modules.get("modin.pandas", None)
6260

6361

6462
def get_cudf() -> Any:

0 commit comments

Comments
 (0)