pub struct Python {
pub path: PathBuf,
pub managed: bool,
}Expand description
A resolved interpreter.
Fields§
§path: PathBuf§managed: boolIt’s byob’s managed venv.
Implementations§
Source§impl Python
impl Python
Sourcepub fn resolve(data_dir: Option<&Path>) -> Option<Self>
pub fn resolve(data_dir: Option<&Path>) -> Option<Self>
Find an interpreter (see the module docs).
Sourcepub fn resolve_in(data_dir: Option<&Path>, env_path: &[PathBuf]) -> Option<Self>
pub fn resolve_in(data_dir: Option<&Path>, env_path: &[PathBuf]) -> Option<Self>
Like Python::resolve, but a python3 in the workspace environment’s PATH
entries (installed packages, a .venv, the dev shell) comes right after $BYOB_PYTHON.
Sourcepub fn read_paths(&self) -> Vec<PathBuf>
pub fn read_paths(&self) -> Vec<PathBuf>
Folders the sandbox must let this interpreter read (see
byob_sandbox::interpreter_read_paths).
Trait Implementations§
impl Eq for Python
impl StructuralPartialEq for Python
Auto Trait Implementations§
impl Forget for Python
impl Freeze for Python
impl RefUnwindSafe for Python
impl Send for Python
impl Sync for Python
impl Unpin for Python
impl UnsafeUnpin for Python
impl UnwindSafe for Python
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more