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
ARROW-3890: [Python] Handle NumPy binary arrays with UTF-8 validation when converting to StringArray #3063
Conversation
On windows:
Static members across DLLs in Windows is a bit zany, taking a look... |
Hm, so I'm surprised we haven't hit this issue yet, but it seems unfortunately that we need to use different visibility macros for It seems this is a well known problem; I think other C++ projects address this by just not having a lot of DLL artifacts, see https://blog.kitware.com/create-dlls-on-windows-without-declspec-using-new-cmake-export-all-feature/. Using
Darn. Well, it is what it is. |
…pyarrow.array with type=pyarrow.string() Change-Id: Ie3e047eda3bf8c7619944bf9cac8d67084df420c
Change-Id: Ic60726716a34827126dc22914402238e1c7b860a
…mbers from arrow.dll can be accessed correctly in arrow_python.dll Change-Id: Ib5748ce1cf9aebd60f8cec20ee4ee03617bec983
…f the new export flags
Codecov Report
@@ Coverage Diff @@
## master #3063 +/- ##
=========================================
+ Coverage 87.15% 88.2% +1.05%
=========================================
Files 489 431 -58
Lines 69161 65470 -3691
=========================================
- Hits 60275 57748 -2527
+ Misses 8787 7722 -1065
+ Partials 99 0 -99
Continue to review full report at Codecov.
|
#ifdef ARROW_STATIC | ||
#define ARROW_PYTHON_EXPORT | ||
#elif defined(ARROW_PYTHON_EXPORTING) | ||
#define ARROW_PYTHON_EXPORT __declspec(dllexport) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there an explanation why we need those separate macros?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I wrote in the comments. So the issue is that we need ARROW_EXPORT to mean dllimport when we are compiling arrow_python.dll, or global data members from arrow.dll cannot be imported. So we need a separate dllexport macro for this separate DLL
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Whether or not there are global data members in arrow.dll, it is the more correct thing to have different export macros for each distinct DLL.
I'm not sure if all compilers will be smart enough to do loop unswitching here. If it ends up being a bottleneck I suggest rewriting in a follow up patch.
The BinaryArray overflow issue (ChunkedArray is not being produced) is still present here. We will need to address that in ARROW-2970
This patch also includes symbol export macros particular to the arrow_python shared library. These are needed so that global data members in arrow.dll can be accessed in arrow_python.dll