-
-
Notifications
You must be signed in to change notification settings - Fork 18.4k
TST: correct constructor in extension array tests #20746
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
TST: correct constructor in extension array tests #20746
Conversation
Codecov Report
@@ Coverage Diff @@
## master #20746 +/- ##
==========================================
- Coverage 91.85% 91.84% -0.01%
==========================================
Files 153 153
Lines 49308 49303 -5
==========================================
- Hits 45290 45284 -6
- Misses 4018 4019 +1
Continue to review full report at Codecov.
|
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.
Thanks.
I've grown to dislike the name _constructor_from_sequence
even more in the interim. It sounds like the method is returning constructor, which would then be used to construct the array. Instead it's creating a new array from a sequence of scalars (so _from_scalars
...)
Is it worth changing before it's too late?
why dont we rename to |
I think we can certainly leave out the |
Either of those are fine. Slight preference for `_from_scalars`, for the
reasons Joris outlined. But from the context, I think it's clear enough
what `_from_sequence` is doing.
…On Fri, Apr 20, 2018 at 2:13 AM, Joris Van den Bossche < ***@***.***> wrote:
I think we can certainly leave out the constructor part. For _from_scalars
or _from_sequence, the doesn't indicate it is from a list/array of
scalars, and the second does not indicate that it is from the dtype's
scalar objects.
I personally have a preference for _from_scalars because I find the
'scalar' the more important information of the two, but _from_sequence is
certainly already an improvement compared to the current name.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#20746 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABQHIs7TwlIFipdK_GOKnyUkwkcxIWCrks5tqYqpgaJpZM4Tb6xW>
.
|
let's do the rename to |
The Appveyor failure was an HTTP issue. @jorisvandenbossche you can merge whenever. |
Replace
type(data)(..)
withdata._constructor_from_sequence
.A bit annoying the name is that long :-), but this is the correct usage.
cc @TomAugspurger