We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 282ebcb commit f22e042Copy full SHA for f22e042
crates/model/src/identifiers/position_id.rs
@@ -20,7 +20,7 @@ use std::{
20
hash::Hash,
21
};
22
23
-use nautilus_core::correctness::{FAILED, check_valid_string_ascii};
+use nautilus_core::correctness::{FAILED, check_valid_string_utf8};
24
use ustr::Ustr;
25
26
/// Represents a valid position ID.
@@ -44,7 +44,7 @@ impl PositionId {
44
/// PyO3 requires a `Result` type for proper error handling and stacktrace printing in Python.
45
pub fn new_checked<T: AsRef<str>>(value: T) -> anyhow::Result<Self> {
46
let value = value.as_ref();
47
- check_valid_string_ascii(value, stringify!(value))?;
+ check_valid_string_utf8(value, stringify!(value))?;
48
Ok(Self(Ustr::from(value)))
49
}
50
0 commit comments