Skip to content

Commit

Permalink
env reader fix for RUST_LOG
Browse files Browse the repository at this point in the history
  • Loading branch information
erhant committed Oct 4, 2024
1 parent 05fb478 commit 2e720c1
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "dkn-oracle"
description = "Dria Knowledge Network: Oracle Node"
version = "0.1.3"
version = "0.1.4"
edition = "2021"
license = "Apache-2.0"
readme = "README.md"
Expand Down
6 changes: 4 additions & 2 deletions src/compute/workflows/executor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,9 @@ pub trait WorkflowsExt {
/// Returns a generation workflow for the executor.
#[inline]
fn get_generation_workflow(&self) -> Result<Workflow> {
Ok(serde_json::from_str(include_str!("generation.json"))?)
Ok(serde_json::from_str(include_str!(
"presets/generation.json"
))?)
}
}

Expand Down Expand Up @@ -116,7 +118,7 @@ mod tests {
async fn test_parse_input_workflow() {
let executor = Executor::new(Default::default());

let workflow_str = include_str!("generation.json");
let workflow_str = include_str!("presets/generation.json");
let (entry, _) = executor
.prepare_input(&workflow_str.as_bytes().into())
.await
Expand Down
File renamed without changes.
6 changes: 3 additions & 3 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ use eyre::{Context, Result};

#[tokio::main]
async fn main() -> Result<()> {
let dotenv_result = dotenvy::dotenv();
env_logger::try_init().wrap_err("could not initialize env_logger")?;
color_eyre::install().wrap_err("could not install color_eyre")?;

if let Err(e) = dotenvy::dotenv() {
log::warn!("Could not load .env file: {}", e);
if let Err(err) = dotenv_result {
log::warn!("Could not load .env file: {}", err);
}

dkn_oracle::cli().await?;
Expand Down

0 comments on commit 2e720c1

Please sign in to comment.