@@ -394,7 +394,7 @@ cloneColumn original new df
394394 | null df = throw (EmptyDataSetException " cloneColumn" )
395395 | otherwise = fromMaybe
396396 ( throw $
397- ColumnNotFoundException original " cloneColumn" (M. keys $ columnIndices df)
397+ ColumnsNotFoundException [ original] " cloneColumn" (M. keys $ columnIndices df)
398398 )
399399 $ do
400400 column <- getColumn original df
@@ -485,7 +485,7 @@ renameSafe ::
485485renameSafe orig new df
486486 | null df = throw (EmptyDataSetException " rename" )
487487 | otherwise = fromMaybe
488- (Left $ ColumnNotFoundException orig " rename" (M. keys $ columnIndices df))
488+ (Left $ ColumnsNotFoundException [ orig] " rename" (M. keys $ columnIndices df))
489489 $ do
490490 columnIndex <- M. lookup orig (columnIndices df)
491491 let origRemoved = M. delete orig (columnIndices df)
@@ -859,7 +859,8 @@ columnAsVector expr df
859859 (Col name) -> case getColumn name df of
860860 Just col -> toVector col
861861 Nothing ->
862- Left $ ColumnNotFoundException name " columnAsVector" (M. keys $ columnIndices df)
862+ Left $
863+ ColumnsNotFoundException [name] " columnAsVector" (M. keys $ columnIndices df)
863864 _ -> case interpret df expr of
864865 Left e -> throw e
865866 Right (TColumn col) -> toVector col
@@ -876,7 +877,7 @@ columnAsIntVector (Col name) df = case getColumn name df of
876877 Just col -> toIntVector col
877878 Nothing ->
878879 Left $
879- ColumnNotFoundException name " columnAsIntVector" (M. keys $ columnIndices df)
880+ ColumnsNotFoundException [ name] " columnAsIntVector" (M. keys $ columnIndices df)
880881columnAsIntVector expr df = case interpret df expr of
881882 Left e -> throw e
882883 Right (TColumn col) -> toIntVector col
@@ -893,7 +894,10 @@ columnAsDoubleVector (Col name) df = case getColumn name df of
893894 Just col -> toDoubleVector col
894895 Nothing ->
895896 Left $
896- ColumnNotFoundException name " columnAsDoubleVector" (M. keys $ columnIndices df)
897+ ColumnsNotFoundException
898+ [name]
899+ " columnAsDoubleVector"
900+ (M. keys $ columnIndices df)
897901columnAsDoubleVector expr df = case interpret df expr of
898902 Left e -> throw e
899903 Right (TColumn col) -> toDoubleVector col
@@ -910,7 +914,10 @@ columnAsFloatVector (Col name) df = case getColumn name df of
910914 Just col -> toFloatVector col
911915 Nothing ->
912916 Left $
913- ColumnNotFoundException name " columnAsFloatVector" (M. keys $ columnIndices df)
917+ ColumnsNotFoundException
918+ [name]
919+ " columnAsFloatVector"
920+ (M. keys $ columnIndices df)
914921columnAsFloatVector expr df = case interpret df expr of
915922 Left e -> throw e
916923 Right (TColumn col) -> toFloatVector col
@@ -923,7 +930,10 @@ columnAsUnboxedVector (Col name) df = case getColumn name df of
923930 Just col -> toUnboxedVector col
924931 Nothing ->
925932 Left $
926- ColumnNotFoundException name " columnAsFloatVector" (M. keys $ columnIndices df)
933+ ColumnsNotFoundException
934+ [name]
935+ " columnAsFloatVector"
936+ (M. keys $ columnIndices df)
927937columnAsUnboxedVector expr df = case interpret df expr of
928938 Left e -> throw e
929939 Right (TColumn col) -> toUnboxedVector col
0 commit comments