Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hooks: pandas: update for compatibility with pandas 1.2.0 and later #5630

Merged
merged 1 commit into from Mar 12, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 7 additions & 1 deletion PyInstaller/hooks/hook-pandas.py
Expand Up @@ -9,7 +9,13 @@
# SPDX-License-Identifier: (GPL-2.0-or-later WITH Bootloader-exception)
#-----------------------------------------------------------------------------

from PyInstaller.utils.hooks import collect_submodules
from PyInstaller.utils.hooks import collect_submodules, is_module_satisfies

# Pandas keeps Python extensions loaded with dynamic imports here.
hiddenimports = collect_submodules('pandas._libs')

# Pandas 1.2.0 and later require cmath hidden import on linux and macOS.
# On Windows, this is not strictly required, but we add it anyway to keep
# things simple (and future-proof).
if is_module_satisfies('pandas >= 1.2.0'):
hiddenimports += ['cmath']
1 change: 1 addition & 0 deletions news/5630.hooks.rst
@@ -0,0 +1 @@
Update ``pandas`` hook for compatibility with version 1.2.0 and later.