Skip to content

Feat(jssg): better validation #1620

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 14 commits into
base: main
Choose a base branch
from
Prev Previous commit
Next Next commit
fix: fmt
  • Loading branch information
AugustinMauroy committed Jul 22, 2025
commit e6c403abe08f65ab864e0ecf7e10dbc6932955d2
8 changes: 4 additions & 4 deletions crates/core/src/utils.rs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
use std::collections::{HashMap, HashSet};
use std::fs;
use std::path::{Path, PathBuf};
use serde_yaml;
use anyhow::{Context, Result};
use butterflow_models::step::StepAction;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We use anyhow in CLI only. In CLI, we use anyhow for ergonomic error propagation and user-facing reports.
In core/library crates, we define typed errors with thiserror.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

got it I had moved the function from cli to core to reused it so I have to modify that

use butterflow_models::{Error, Node, Result, Workflow};
use serde_yaml;
use std::collections::{HashMap, HashSet};
use std::fs;
use std::path::{Path, PathBuf};

/// Parse a workflow definition from a file
pub fn parse_workflow_file<P: AsRef<Path>>(path: P) -> Result<Workflow> {
Expand Down
Loading
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