kieferk / dfply

dplyr-style piping operations for pandas dataframes
GNU General Public License v3.0
889 stars 103 forks source link

Throw error when grouping by an unknown column (closes #81) #82

Open crew102 opened 5 years ago

crew102 commented 5 years ago

One quick note: I put assert_known_cols() inside group_by() instead of within group_delegation.__call__() b/c I wanted the error to be thrown even if no grouped function is called on the data. In other words, I wanted there to be an error when running code like this:

x = diamonds >> group_by('bad_col')
crew102 commented 5 years ago

FYI, this is failing on Travis b/c Python 3.7 can't be installed