Skip to content

Commit

Permalink
Fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
visr committed Sep 23, 2024
1 parent 5ea17fb commit 1a6c087
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion core/src/util.jl
Original file line number Diff line number Diff line change
Expand Up @@ -447,7 +447,7 @@ function get_all_priorities(db::DB, config::Config)::Vector{Int32}
(FlowDemandTimeV1, "FlowDemand / time"),
]
priority_col = load_structvector(db, config, type).priority
priority_col = coalesce.(priority_col, Int32(0))
priority_col = Int32.(coalesce.(priority_col, Int32(0)))
if valid_priorities(priority_col, config.allocation.use_allocation)
union!(priorities, priority_col)
else
Expand Down
1 change: 1 addition & 0 deletions pixi.toml
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ test-ribasim-regression = { cmd = "julia --project=core --eval 'using Pkg; Pkg.t
generate-testmodels = { cmd = "python utils/generate-testmodels.py", inputs = [
"python/ribasim",
"python/ribasim_testmodels",
"utils/generate-testmodels.py",
], outputs = [
"generated_testmodels",
] }
Expand Down
3 changes: 2 additions & 1 deletion python/ribasim/ribasim/delwaq/generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,8 @@ def _make_boundary(data, boundary_type):
.reset_index()
.reset_index(drop=True)
)
piv.time = piv.time.dt.strftime("%Y/%m/%d-%H:%M:%S")
# Convert Arrow time to Numpy to avoid needing tzdata somehow
piv.time = pd.to_datetime(piv.time).dt.strftime("%Y-%m-%d %H:%M:%S")

Check warning on line 78 in python/ribasim/ribasim/delwaq/generate.py

View check run for this annotation

Codecov / codecov/patch

python/ribasim/ribasim/delwaq/generate.py#L78

Added line #L78 was not covered by tests
boundary = {
"name": bid,
"substances": list(map(_quote, piv.columns[1:])),
Expand Down

0 comments on commit 1a6c087

Please sign in to comment.