pandas-dev / pandas

Flexible and powerful data analysis / manipulation library for Python, providing labeled data structures similar to R data.frame objects, statistical functions, and much more
https://pandas.pydata.org
BSD 3-Clause "New" or "Revised" License
43.64k stars 17.92k forks source link

REF/CLN: ops boilerplate #23853

Open jbrockmendel opened 5 years ago

jbrockmendel commented 5 years ago

A ton of comparison and arithmetic operations do something combination of:

But we don't always do all of these, and we definitely don't use+test error messages as consistent as @gfyoung would like.

This behavior could all be collected+standardized in a decorator

gfyoung commented 5 years ago

+1 for consistency. A decorator would be great, though that would be a little trickier to execute.

Also, for future reference, the reason for checking error messages in our tests is because those are important for end users when debugging code. Making sure that they're accurate is important, just as the type of error that is raised.

jreback commented 5 years ago

@jbrockmendel can you convert these to check boxes in the top (e.g. 4 would be checked by #23896 )