diff rust/hg-pyo3/src/lib.rs @ 52788:264047bf4b9b

rust-pyo3-revlog: new Python and Rust module We anticipate that we will actually need to organize the code in several Rust submodules, but it will of course still be exposed as a single Python module.
author Georges Racinet <georges.racinet@cloudcrane.io>
date Tue, 24 Dec 2024 18:02:11 +0100
parents 0f9ed7e7a71b
children 6fa23eed335b
line wrap: on
line diff
--- a/rust/hg-pyo3/src/lib.rs	Fri Dec 20 20:40:09 2024 +0100
+++ b/rust/hg-pyo3/src/lib.rs	Tue Dec 24 18:02:11 2024 +0100
@@ -5,6 +5,7 @@
 mod dagops;
 mod exceptions;
 mod revision;
+mod revlog;
 mod util;
 
 #[pymodule]
@@ -15,9 +16,11 @@
         "Mercurial core concepts - Rust implementation exposed via PyO3",
     )?;
     let dotted_name: String = m.getattr("__name__")?.extract()?;
+    env_logger::init();
 
     m.add_submodule(&ancestors::init_module(py, &dotted_name)?)?;
     m.add_submodule(&dagops::init_module(py, &dotted_name)?)?;
+    m.add_submodule(&revlog::init_module(py, &dotted_name)?)?;
     m.add("GraphError", py.get_type::<exceptions::GraphError>())?;
     Ok(())
 }