Skip to content

Commit

Permalink
Update jiff and other dependencies
Browse files Browse the repository at this point in the history
jiff: Use new iso_week_date API

Signed-off-by: 35V LG84 <[email protected]>
  • Loading branch information
35VLG84 committed Jan 15, 2025
1 parent cfa27c9 commit 387fe81
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 32 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@ New features:

Changed functionality:

* Replaced ANTLR based Txn parser with winnow parser combinator
** This is affecting how invalid journal syntax is reported
** This has NO changes to journal syntax
* Replaced time and time-tz with jiff
** This have some user visible changes, e.g. 'Z' is replaced with '+00:00'
** Txn Filters, Txn Timestamp: Begin and End are displayed with report timezone
Expand All @@ -60,6 +63,7 @@ Updated deps and tools:

* Dependencies
** serde: 1.0.217
** jiff: 0.1.23

===== Rust toolchain

Expand Down
71 changes: 41 additions & 30 deletions Cargo.lock

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

4 changes: 2 additions & 2 deletions tackler-api/src/txn_ts.rs
Original file line number Diff line number Diff line change
Expand Up @@ -203,15 +203,15 @@ fn fmt_year(ts: &Zoned) -> String {
}

fn fmt_week(ts: &Zoned) -> String {
let iso_date = ts.date().to_iso_week_date();
let iso_date = ts.date().iso_week_date();
let y = iso_date.year();
let w = iso_date.week();

format!("{}-W{:02}", y, w)
}

fn fmt_week_date(ts: &Zoned) -> String {
let iso_date = ts.date().to_iso_week_date();
let iso_date = ts.date().iso_week_date();
let y = iso_date.year();
let w = iso_date.week();
let wd = iso_date.weekday().to_monday_one_offset();
Expand Down

0 comments on commit 387fe81

Please sign in to comment.