-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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-13554: [C++] Remove deprecated Scanner::Scan #11991
ARROW-13554: [C++] Remove deprecated Scanner::Scan #11991
Conversation
@@ -2239,10 +2233,6 @@ cdef class Scanner(_Weakrefable): | |||
use_threads : bool, default True | |||
If enabled, then maximum parallelism will be used determined by | |||
the number of available CPU cores. | |||
use_async : bool, default False |
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.
It seems that in Python, this keyword was not actually deprecated (in docs or deprecation warning)?
Therefore, we could maybe still temporary just keep this keyword in the signature (without that it does anything, except from raising a warning if specified by the user, or something like that)
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.
I added the parameters back in. PTAL. One thing I wasn't sure of...
All of the places the parameter was declared it was a bint
which means I couldn't change the default to None
which means there was no good way to tell if the user specified it or not.
So I just made the default True and emit the warning if the user specifies False
. However, if a user has:
dataset.to_table(use_async=True)
they will not get the warning.
Alternatively, I could change the cython type from bint to object. Then I should be able to warn on both use_async=True
and use_async=False
. Would this possible have any backwards compatibility ramifications?
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.
This was bugging me so I went ahead and played around with it. I don't see any consequences if I change bint use_async=True
to object use_async = None
and that allows me to emit the deprecation warning on both use_async=True
and use_async=False
(i.e. emit a warning if the user uses the flag in any way).
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.
I also can't think of any concern for changing bint
to object
(the other way around would limit what you can pass, but for here it just broadens what you can pass, so that should not be a compatibility issue)
582ae32
to
189dce2
Compare
0b3397d
to
4fd7b1e
Compare
The only failure remaining is a Java failure. Unfortunately, the test failure is missing line numbers so I'm not sure exactly what assert is failing (it expects 2 but I can't find any assert expecting 2 in the test case) so I'll try and reproduce it locally. This is ready for review in the meantime. |
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.
Did we file a JIRA for removing the deprecated flags in 8.0.0?
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.
LGTM. I left a couple of final minor comments.
|
||
for (size_t i = 0; i < exprs.size(); ++i) { | ||
if (auto ref = exprs[i].field_ref()) { | ||
if (!ref->name()) return NestedFieldRefsNotImplemented(); |
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.
I'll rebase #11704 when this lands.
I just created ARROW-15283 |
… arrays. Putting in an expensive fix to see if it fixes the test. Ideally we can do something better but I may have to push that to a future PR
…test, reverted unintended style changes from cglib, moved projectiondescr factory methods into the struct
…e concatenate if there is an offset. Added a comment explaining the situation and referencing a follow-up PR
…n the cglib files
…ectionDescr::FromXyz for consistency with other parts of the code
… removing the field outright...yet
…give a deprecation warning on use_async=True AND use_async=False
da58e06
to
3629ed1
Compare
Benchmark runs are scheduled for baseline = 43bc33b and contender = 2e8b836. 2e8b836 is a master commit associated with this PR. Results will be available as each benchmark for each run completes. |
This might break test-skyhook-integration (cc: @JayjeetAtGithub): https://github.com/ursacomputing/crossbow/runs/4771425719?check_suite_focus=true
|
Oh, sorry. I haven't seen it yet. |
No description provided.