@@ -307,7 +307,7 @@ impl FromNapiValue for Wrap<ClosedWindow> {
307
307
"right" => ClosedWindow :: Right ,
308
308
_ => {
309
309
return Err ( napi:: Error :: from_reason (
310
- "closed should be any of {'none', 'left', 'right'}" . to_owned ( ) ,
310
+ "closed should be any of {'none', 'left', 'right', 'both' }" . to_owned ( ) ,
311
311
) )
312
312
}
313
313
} ;
@@ -327,7 +327,7 @@ impl FromNapiValue for Wrap<RankMethod> {
327
327
"random" => RankMethod :: Random ,
328
328
_ => {
329
329
return Err ( napi:: Error :: from_reason (
330
- "use one of 'avg, min, max, dense, ordinal'" . to_owned ( ) ,
330
+ "use one of {'average', ' min', ' max', ' dense', ' ordinal', 'random'} " . to_owned ( ) ,
331
331
) )
332
332
}
333
333
} ;
@@ -371,7 +371,7 @@ impl FromNapiValue for Wrap<UniqueKeepStrategy> {
371
371
"last" => UniqueKeepStrategy :: Last ,
372
372
_ => {
373
373
return Err ( napi:: Error :: from_reason (
374
- "use one of 'first, last'" . to_owned ( ) ,
374
+ "use one of { 'first', ' last'} " . to_owned ( ) ,
375
375
) )
376
376
}
377
377
} ;
@@ -387,7 +387,7 @@ impl FromNapiValue for Wrap<NullStrategy> {
387
387
"propagate" => NullStrategy :: Propagate ,
388
388
_ => {
389
389
return Err ( napi:: Error :: from_reason (
390
- "use one of 'ignore', 'propagate'" . to_owned ( ) ,
390
+ "use one of { 'ignore', 'propagate'} " . to_owned ( ) ,
391
391
) )
392
392
}
393
393
} ;
@@ -403,7 +403,7 @@ impl FromNapiValue for Wrap<NullBehavior> {
403
403
"ignore" => NullBehavior :: Ignore ,
404
404
_ => {
405
405
return Err ( napi:: Error :: from_reason (
406
- "use one of 'drop', 'ignore'" . to_owned ( ) ,
406
+ "use one of { 'drop', 'ignore'} " . to_owned ( ) ,
407
407
) )
408
408
}
409
409
} ;
@@ -926,7 +926,7 @@ impl FromJsUnknown for i64 {
926
926
let s: JsNumber = val. try_into ( ) ?;
927
927
s. try_into ( )
928
928
}
929
- dt => Err ( JsPolarsErr :: Other ( format ! ( "cannot cast {} to u64 " , dt) ) . into ( ) ) ,
929
+ dt => Err ( JsPolarsErr :: Other ( format ! ( "cannot cast {} to i64 " , dt) ) . into ( ) ) ,
930
930
}
931
931
}
932
932
}
0 commit comments