Skip to content

Commit 0ac8a52

Browse files
authored
make Python logging fn public (#1414)
1 parent 00650e8 commit 0ac8a52

File tree

1 file changed

+2
-2
lines changed
  • pgml-extension/src/bindings

1 file changed

+2
-2
lines changed

pgml-extension/src/bindings/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ use pyo3::{pyfunction, PyResult, Python};
88
use crate::orm::*;
99

1010
#[pyfunction]
11-
fn r_insert_logs(project_id: i64, model_id: i64, logs: String) -> PyResult<String> {
11+
pub fn r_insert_logs(project_id: i64, model_id: i64, logs: String) -> PyResult<String> {
1212
let id_value = Spi::get_one_with_args::<i64>(
1313
"INSERT INTO pgml.logs (project_id, model_id, logs) VALUES ($1, $2, $3::JSONB) RETURNING id;",
1414
vec![
@@ -23,7 +23,7 @@ fn r_insert_logs(project_id: i64, model_id: i64, logs: String) -> PyResult<Strin
2323
}
2424

2525
#[pyfunction]
26-
fn r_log(level: String, message: String) -> PyResult<String> {
26+
pub fn r_log(level: String, message: String) -> PyResult<String> {
2727
match level.as_str() {
2828
"info" => info!("{}", message),
2929
"warning" => warning!("{}", message),

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy