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

Pandas v2.2.3 raising DeprecationWarning: The 'fastpath' keyword in pd.Series is deprecated and will be removed in a future version. for ASAMMDF v8.0.1 #1100

Open
BdSCunha opened this issue Nov 19, 2024 · 1 comment

Comments

@BdSCunha
Copy link

BdSCunha commented Nov 19, 2024

Python version

('python=3.11.9 (tags/v3.11.9:de54cf5, Apr 2 2024, 10:12:12) [MSC v.1938 64 bit (AMD64)]')
'os=Windows-10-10.0.19045-SP0'
'numpy=1.23.5'
ldf is not supported
xls is not supported
yaml is not supported
'asammdf=8.0.1'

Code

MDF version

3.00

Code snippet

The warning is raised by just running pytest on Windows PowerShell or Command Prompt

Traceback

(.venv) C:\Users\Public\Desktop\project>pytest
==================================================================================== test session starts ====================================================================================
platform win32 -- Python 3.11.9, pytest-8.3.3, pluggy-1.5.0
rootdir: C:\Users\Public\Desktop\project      
configfile:
testpaths: tests
collected 79 items

tests\test_module_1.py ...                                                [  3%]
tests\test_module_2.py .....                                              [ 10%]
tests\test_module_3.py .....                                              [ 16%]
tests\test_module_4.py .............................................      [ 73%]
tests\test_module_5.py ......                                             [ 81%]
tests\test_module_6.py ..                                                 [ 83%]
tests\test_module_7.py ...........                                        [ 97%]
tests\test_module_8.py .                                                  [ 98%]
tests\test_module_9.py .                                                  [100%]

===================================================================================== warnings summary ====================================================================================== 
.venv\Lib\site-packages\asammdf\mdf.py:4634: 71 warnings
tests/test_module_1.py: 18 warnings
tests/test_module_2.py: 5 warnings
tests/test_module_3.py: 7 warnings
tests/test_module_5.py: 30 warnings
tests/test_module_8.py: 6 warnings
  c:\Users\Public\Desktop\project\.venv\Lib\site-packages\asammdf\mdf.py:4634: DeprecationWarning: The 'fastpath' keyword in pd.Series is deprecated and will be removed in a future version.
    df[channel_name] = pd.Series(sig.samples, index=sig_index, fastpath=True)

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
============================================================================= 79 passed, 137 warnings in 5.86s ==============================================================================

Description

I updated ASAMMDF from v7.3.12 to the lastest v8.0.1, and by just running pytest in my project's root folder, Pandas raised the warning:

C:\Users\Public\Desktop\project.venv\Lib\site-packages\asammdf\mdf.py:4634: DeprecationWarning: The 'fastpath' keyword in pd.Series is deprecated and will be removed in a future version.
df[channel_name] = pd.Series(sig.samples, index=sig_index, fastpath=True)

asammdf/requirements.txt file does not specify a Pandas version to be used:

canmatrix[arxml,dbc]>=1.0
lz4
numexpr
numpy>=1.23.0, <2.0.0
pandas
typing_extensions
python-dateutil
isal; platform_machine == "x86_64" or platform_machine == "AMD64"
lxml>=4.9.3

And the release notes of Pandas v2.2.0 - Other Deprecations specify the item:

@BdSCunha
Copy link
Author

I just saw that commit 2937a21 by @JulienGrv fixes this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant