🌐 AI搜索 & 代理 主页
Skip to content
Draft
Prev Previous commit
Next Next commit
fix
  • Loading branch information
youknowone committed Dec 11, 2025
commit 2fa01b1605408a149ed035acf7d1b205a841ab45
2 changes: 1 addition & 1 deletion crates/stdlib/src/bz2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ mod _bz2 {
};
use crate::vm::{
Py, VirtualMachine,
builtins::{PyBytesRef, PyType, PyTypeRef},
builtins::{PyBytesRef, PyType},
common::lock::PyMutex,
function::{ArgBytesLike, OptionalArg},
object::{PyPayload, PyResult},
Expand Down
2 changes: 1 addition & 1 deletion crates/stdlib/src/json.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ mod _json {
use super::machinery;
use crate::vm::{
AsObject, Py, PyObjectRef, PyPayload, PyResult, VirtualMachine,
builtins::{PyBaseExceptionRef, PyStrRef, PyType, PyTypeRef},
builtins::{PyBaseExceptionRef, PyStrRef, PyType},
convert::{ToPyObject, ToPyResult},
function::{IntoFuncArgs, OptionalArg},
protocol::PyIterReturn,
Expand Down
2 changes: 1 addition & 1 deletion crates/stdlib/src/ssl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ mod _ssl {
vm::{
AsObject, Py, PyObject, PyObjectRef, PyPayload, PyRef, PyResult, TryFromObject,
VirtualMachine,
builtins::{PyBaseExceptionRef, PyBytesRef, PyListRef, PyStrRef, PyType, PyTypeRef},
builtins::{PyBaseExceptionRef, PyBytesRef, PyListRef, PyStrRef, PyType},
convert::IntoPyException,
function::{ArgBytesLike, ArgMemoryBuffer, OptionalArg, PyComparisonValue},
stdlib::warnings,
Expand Down
2 changes: 1 addition & 1 deletion crates/vm/src/builtins/code.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! Infamous code object. The python class `code`

use super::{PyBytesRef, PyStrRef, PyTupleRef, PyType, PyTypeRef};
use super::{PyBytesRef, PyStrRef, PyTupleRef, PyType};
use crate::{
AsObject, Context, Py, PyObject, PyObjectRef, PyPayload, PyResult, VirtualMachine,
builtins::PyStrInterned,
Expand Down
2 changes: 1 addition & 1 deletion crates/vm/src/builtins/function.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ mod jit;

use super::{
PyAsyncGen, PyCode, PyCoroutine, PyDictRef, PyGenerator, PyStr, PyStrRef, PyTuple, PyTupleRef,
PyType, PyTypeRef,
PyType,
};
#[cfg(feature = "jit")]
use crate::common::lock::OnceCell;
Expand Down
2 changes: 1 addition & 1 deletion crates/vm/src/builtins/property.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/*! Python `property` descriptor class.

*/
use super::{PyStrRef, PyType, PyTypeRef};
use super::{PyStrRef, PyType};
use crate::common::lock::PyRwLock;
use crate::function::{IntoFuncArgs, PosArgs};
use crate::{
Expand Down
2 changes: 1 addition & 1 deletion crates/vm/src/builtins/traceback.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use super::{PyType, PyTypeRef};
use super::PyType;
use crate::{
Context, Py, PyPayload, PyRef, PyResult, VirtualMachine, class::PyClassImpl, frame::FrameRef,
types::Constructor,
Expand Down
2 changes: 1 addition & 1 deletion crates/vm/src/builtins/zip.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use super::{PyType, PyTypeRef};
use super::PyType;
use crate::{
AsObject, Context, Py, PyObjectRef, PyPayload, PyRef, PyResult, TryFromObject, VirtualMachine,
builtins::PyTupleRef,
Expand Down
2 changes: 1 addition & 1 deletion crates/vm/src/stdlib/ast/python.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ use super::{PY_CF_OPTIMIZED_AST, PY_CF_TYPE_COMMENTS, PY_COMPILE_FLAG_AST_ONLY};
pub(crate) mod _ast {
use crate::{
AsObject, Context, PyObjectRef, PyPayload, PyResult, VirtualMachine,
builtins::{PyStrRef, PyTupleRef, PyType, PyTypeRef},
builtins::{PyStrRef, PyTupleRef, PyTypeRef},
function::FuncArgs,
types::Constructor,
};
Expand Down
4 changes: 1 addition & 3 deletions crates/vm/src/stdlib/posix.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,7 @@ pub(crate) fn make_module(vm: &VirtualMachine) -> PyRef<PyModule> {
pub mod module {
use crate::{
AsObject, Py, PyObjectRef, PyPayload, PyResult, VirtualMachine,
builtins::{
PyDictRef, PyInt, PyListRef, PyStrRef, PyTupleRef, PyType, PyTypeRef, PyUtf8StrRef,
},
builtins::{PyDictRef, PyInt, PyListRef, PyStrRef, PyTupleRef, PyType, PyUtf8StrRef},
convert::{IntoPyException, ToPyObject, TryFromObject},
function::{Either, KwArgs, OptionalArg},
ospath::{IOErrorBuilder, OsPath, OsPathOrFd},
Expand Down
2 changes: 0 additions & 2 deletions crates/vm/src/vm/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -811,8 +811,6 @@ impl VirtualMachine {
pub(crate) fn set_exception(&self, exc: Option<PyBaseExceptionRef>) {
// don't be holding the RefCell guard while __del__ is called
let prev = std::mem::replace(&mut self.exceptions.borrow_mut().exc, exc);
let repr = prev.as_ref().and_then(|e| e.as_object().repr(self).ok());
println!("prev: {:?}", repr);
drop(prev);
}

Expand Down