Skip to content

Refactor Extension Modules #53346

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

Merged
merged 6 commits into from
May 31, 2023
Merged

Conversation

WillAyd
Copy link
Member

@WillAyd WillAyd commented May 22, 2023

This puts all source files in pandas/_libs/src and all header files in pandas/_libs/include This simplifies our includes, letting us do them in an "absolute" way, while also making it clear which headers/sources were vendored

'include_dirs': inc_datetime}
'np_datetime': {'sources': ['np_datetime.pyx']},
'offsets': {'sources': ['offsets.pyx']},
'parsing': {'sources': ['parsing.pyx', '../src/parser/tokenizer.c']},
Copy link
Member Author

@WillAyd WillAyd May 22, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure why this still needs tokenizer.c as a source - should be replaced via the capsule import but likely missed

@mroeschke mroeschke added the Build Library building on various platforms label May 23, 2023
@mroeschke mroeschke added this to the 2.1 milestone May 24, 2023
Copy link
Member

@mroeschke mroeschke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! I like the /vendored/ distinction

@mroeschke mroeschke merged commit 43f1bc8 into pandas-dev:main May 31, 2023
@mroeschke
Copy link
Member

Thanks @WillAyd

@WillAyd WillAyd deleted the refactor-extensions branch May 31, 2023 17:22
@jbrockmendel
Copy link
Member

Just merged main and now im getting build errors

  pandas/_libs/hashtable.cpython-311-darwin.so.p/pandas/_libs/hashtable.pyx.c:754:10: fatal error: 'khash_python.h' file not found
  #include "khash_python.h"
           ^~~~~~~~~~~~~~~~
  1 error generated.

(my builds in general have gotten a lot more troublesome since the meson change, dont know if this is related)

@WillAyd
Copy link
Member Author

WillAyd commented May 31, 2023

Try to wipe your build folder and start from scratch with meson. I don't know that meson handles changes in the file system that gracefully compared to our old methodology

topper-123 pushed a commit to topper-123/pandas that referenced this pull request Jun 5, 2023
* Working refactor with setuptools

* Meson updates

* fixed missing source files

* Missing graft
Daquisu pushed a commit to Daquisu/pandas that referenced this pull request Jul 8, 2023
* Working refactor with setuptools

* Meson updates

* fixed missing source files

* Missing graft
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Build Library building on various platforms
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants