Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 11 additions & 11 deletions 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
Expand Up @@ -4,7 +4,7 @@ resolver = "2"

[workspace.package]
edition = "2021"
version = "0.3.41"
version = "0.3.42"
description = "Tower is the best way to host Python data apps in production"
rust-version = "1.81"
authors = ["Brad Heller <brad@tower.dev>"]
Expand Down
17 changes: 11 additions & 6 deletions crates/tower-package/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,13 @@ pub const MAX_BUNDLE_SIZE: u64 = 50 * 1024 * 1024;

#[derive(Clone, Serialize, Deserialize, Debug)]
pub struct Parameter {
#[serde(default)]
pub name: String,
pub description: String,

#[serde(default)]
pub description: Option<String>,

#[serde(default)]
pub default: String,
}

Expand Down Expand Up @@ -115,7 +120,7 @@ fn get_parameters(towerfile: &Towerfile) -> Vec<Parameter> {
for p in &towerfile.parameters {
parameters.push(Parameter {
name: p.name.clone(),
description: p.description.clone(),
description: Some(p.description.clone()),
default: p.default.clone(),
});
}
Expand Down Expand Up @@ -190,16 +195,16 @@ impl Package {
}
}

pub async fn from_unpacked_path(path: PathBuf) -> Self {
pub async fn from_unpacked_path(path: PathBuf) -> Result<Self, Error> {
let manifest_path = path.join("MANIFEST");
let manifest = Manifest::from_path(&manifest_path).await.unwrap();
let manifest = Manifest::from_path(&manifest_path).await?;

Self {
Ok(Self {
tmp_dir: None,
package_file_path: None,
unpacked_path: Some(path),
manifest,
}
})
}

// build creates a new package from a PackageSpec. PackageSpec is typically composed of fields
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "maturin"

[project]
name = "tower"
version = "0.3.41"
version = "0.3.42"
description = "Tower CLI and runtime environment for Tower."
authors = [{ name = "Tower Computing Inc.", email = "brad@tower.dev" }]
readme = "README.md"
Expand Down
2 changes: 1 addition & 1 deletion uv.lock

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