[PR #366] [MERGED] Replace std::time::Duration with chrono::Duration to support negative duration #418

Closed
opened 2026-02-27 20:24:39 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/ramsayleung/rspotify/pull/366
Author: @ramsayleung
Created: 10/27/2022
Status: Merged
Merged: 12/27/2022
Merged by: @marioortizmanero

Base: masterHead: ramsay_fix_negative_progress_ms


📝 Commits (6)

  • e94af5b replace std::time::Duration with chrono::Duration
  • 882194d Replace std::time::Duraion with chrono::Duration
  • b487d13 fix compile error
  • ce706fa impl visit_u64 method, fix failed functions
  • 393fb2e Update doc
  • a49a5f9 Fix clippy error.

📊 Changes

8 files changed (+59 additions, -52 deletions)

View changed files

📝 CHANGELOG.md (+14 -13)
📝 rspotify-model/src/audio.rs (+1 -1)
📝 rspotify-model/src/context.rs (+1 -2)
📝 rspotify-model/src/custom_serde.rs (+27 -20)
📝 rspotify-model/src/show.rs (+2 -2)
📝 rspotify-model/src/track.rs (+3 -2)
📝 tests/test_models.rs (+9 -10)
📝 tests/test_with_oauth.rs (+2 -2)

📄 Description

Description

https://github.com/ramsayleung/rspotify/issues/363

Motivation and Context

https://github.com/ramsayleung/rspotify/issues/363

Dependencies

Type of change

Please delete options that are not relevant.

  • Bug fix (non-breaking change which fixes an issue)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How has this been tested?

All existing tests pass.

  • Test A: test_resume_point_negative

Is this change properly documented?

Yes


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/ramsayleung/rspotify/pull/366 **Author:** [@ramsayleung](https://github.com/ramsayleung) **Created:** 10/27/2022 **Status:** ✅ Merged **Merged:** 12/27/2022 **Merged by:** [@marioortizmanero](https://github.com/marioortizmanero) **Base:** `master` ← **Head:** `ramsay_fix_negative_progress_ms` --- ### 📝 Commits (6) - [`e94af5b`](https://github.com/ramsayleung/rspotify/commit/e94af5be94fb46f6ac16a4daea5e728867943f00) replace std::time::Duration with chrono::Duration - [`882194d`](https://github.com/ramsayleung/rspotify/commit/882194d31f7ad05d49c20ea6c5466ca439a5eeab) Replace std::time::Duraion with chrono::Duration - [`b487d13`](https://github.com/ramsayleung/rspotify/commit/b487d13303abb712b5a90b4cd71f2f4a5dc3819b) fix compile error - [`ce706fa`](https://github.com/ramsayleung/rspotify/commit/ce706fa0b186fc5a0cbc229729af2e862826e634) impl visit_u64 method, fix failed functions - [`393fb2e`](https://github.com/ramsayleung/rspotify/commit/393fb2e6402aa9a2d13803ad87c72cc6b6b26723) Update doc - [`a49a5f9`](https://github.com/ramsayleung/rspotify/commit/a49a5f9980111c4210943d64b0a80b44f964b9e0) Fix clippy error. ### 📊 Changes **8 files changed** (+59 additions, -52 deletions) <details> <summary>View changed files</summary> 📝 `CHANGELOG.md` (+14 -13) 📝 `rspotify-model/src/audio.rs` (+1 -1) 📝 `rspotify-model/src/context.rs` (+1 -2) 📝 `rspotify-model/src/custom_serde.rs` (+27 -20) 📝 `rspotify-model/src/show.rs` (+2 -2) 📝 `rspotify-model/src/track.rs` (+3 -2) 📝 `tests/test_models.rs` (+9 -10) 📝 `tests/test_with_oauth.rs` (+2 -2) </details> ### 📄 Description ## Description https://github.com/ramsayleung/rspotify/issues/363 ## Motivation and Context https://github.com/ramsayleung/rspotify/issues/363 ## Dependencies ## Type of change Please delete options that are not relevant. - [x] Bug fix (non-breaking change which fixes an issue) - [x] Breaking change (fix or feature that would cause existing functionality to not work as expected) - [x] This change requires a documentation update ## How has this been tested? All existing tests pass. - [x] Test A: test_resume_point_negative ## Is this change properly documented? Yes --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-27 20:24:39 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/rspotify#418
No description provided.