Skip to content

Commit ee4ee54

Browse files
committed
Use vm.import when running with -m
1 parent 72febb7 commit ee4ee54

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/main.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -98,8 +98,7 @@ fn run_command(vm: &VirtualMachine, mut source: String) -> PyResult {
9898

9999
fn run_module(vm: &VirtualMachine, module: &str) -> PyResult {
100100
debug!("Running module {}", module);
101-
let current_path = PathBuf::from(".");
102-
import::import_module(vm, current_path, module)
101+
vm.import(module, &vm.ctx.new_tuple(vec![]), 0)
103102
}
104103

105104
fn run_script(vm: &VirtualMachine, script_file: &str) -> PyResult {

0 commit comments

Comments
 (0)