[PR #1291] [MERGED] Update hyper to 1.x #1321

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

📋 Pull Request Information

Original PR: https://github.com/librespot-org/librespot/pull/1291
Author: @GeorgeHahn
Created: 6/7/2024
Status: Merged
Merged: 6/9/2024
Merged by: @roderickvd

Base: devHead: hyper-update


📝 Commits (6)

  • 98a9758 Enable deprecation warnings and address
  • 0a7a874 Update core to hyper 1.x
  • 6a4053e Update audio to hyper 1.x
  • da0deb1 Convert discovery to hyper 1.x
  • e1113dd cargo fmt
  • bd5c284 Fix build error when hyper's server feature isn't enabled

📊 Changes

12 files changed (+281 additions, -334 deletions)

View changed files

📝 Cargo.lock (+148 -243)
📝 audio/Cargo.toml (+3 -1)
📝 audio/src/fetch/mod.rs (+3 -2)
📝 audio/src/fetch/receive.rs (+2 -1)
📝 core/Cargo.toml (+6 -4)
📝 core/src/apresolve.rs (+3 -2)
📝 core/src/error.rs (+11 -5)
📝 core/src/http_client.rs (+20 -21)
📝 core/src/spclient.rs (+6 -6)
📝 discovery/Cargo.toml (+4 -1)
📝 discovery/src/lib.rs (+1 -1)
📝 discovery/src/server.rs (+74 -47)

📄 Description

This PR updates hyper to version 1.x. I've tested it on windows with default options. The most notable change is in the discovery server, where the code has changed significantly to accommodate changes in hyper. The intent of the code remains the same, and I confirmed that it functions correctly on my devices.

hyper-proxy is swapped out in favor of a maintained fork, hyper-proxy2. I've seen mentions of some alternatives; this appears to be the most stable option.

hyper-rustls is updated to version 0.26.0 to get hyper 1.x support, but is held short of the latest version, 0.27.2, due to build environment changes required for 0.27.0.

Docs I referenced for this change:


🔄 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/librespot-org/librespot/pull/1291 **Author:** [@GeorgeHahn](https://github.com/GeorgeHahn) **Created:** 6/7/2024 **Status:** ✅ Merged **Merged:** 6/9/2024 **Merged by:** [@roderickvd](https://github.com/roderickvd) **Base:** `dev` ← **Head:** `hyper-update` --- ### 📝 Commits (6) - [`98a9758`](https://github.com/librespot-org/librespot/commit/98a97588d3692dc6413bb151f16b7c620179b830) Enable deprecation warnings and address - [`0a7a874`](https://github.com/librespot-org/librespot/commit/0a7a874ca0bb6e6b27904268ded4f1c9609e2003) Update core to hyper 1.x - [`6a4053e`](https://github.com/librespot-org/librespot/commit/6a4053e871db614be4cdc999ebe2418239a05f59) Update audio to hyper 1.x - [`da0deb1`](https://github.com/librespot-org/librespot/commit/da0deb1de6ce499f8ebfd4d4d76931efc3d25273) Convert discovery to hyper 1.x - [`e1113dd`](https://github.com/librespot-org/librespot/commit/e1113dd5e2ec2eb803a1e5d18ca2b5d580c5552b) cargo fmt - [`bd5c284`](https://github.com/librespot-org/librespot/commit/bd5c284790936fd3c3a97575f58bf684313702ba) Fix build error when hyper's `server` feature isn't enabled ### 📊 Changes **12 files changed** (+281 additions, -334 deletions) <details> <summary>View changed files</summary> 📝 `Cargo.lock` (+148 -243) 📝 `audio/Cargo.toml` (+3 -1) 📝 `audio/src/fetch/mod.rs` (+3 -2) 📝 `audio/src/fetch/receive.rs` (+2 -1) 📝 `core/Cargo.toml` (+6 -4) 📝 `core/src/apresolve.rs` (+3 -2) 📝 `core/src/error.rs` (+11 -5) 📝 `core/src/http_client.rs` (+20 -21) 📝 `core/src/spclient.rs` (+6 -6) 📝 `discovery/Cargo.toml` (+4 -1) 📝 `discovery/src/lib.rs` (+1 -1) 📝 `discovery/src/server.rs` (+74 -47) </details> ### 📄 Description This PR updates `hyper` to version 1.x. I've tested it on windows with default options. The most notable change is in the discovery server, where the code has changed significantly to accommodate changes in `hyper`. The intent of the code remains the same, and I confirmed that it functions correctly on my devices. [`hyper-proxy`](https://github.com/tafia/hyper-proxy) is swapped out in favor of a maintained fork, [`hyper-proxy2`](https://github.com/siketyan/hyper-proxy2). I've seen mentions of some alternatives; this appears to be the most stable option. `hyper-rustls` is updated to version [`0.26.0`](https://github.com/rustls/hyper-rustls/releases/tag/v%2F0.26.0) to get `hyper` 1.x support, but is held short of the latest version, `0.27.2`, due to build environment changes required for [`0.27.0`](https://github.com/rustls/hyper-rustls/releases/tag/v%2F0.27.0). Docs I referenced for this change: - [Hyper 1.x update guide](https://hyper.rs/guides/1/upgrading/) - [Hyper 1.0.0 changelog](https://github.com/hyperium/hyper/blob/master/CHANGELOG.md#v100-2023-11-15) - [Graceful shutdown guide](https://hyper.rs/guides/1/server/graceful-shutdown/) - Crate docs: [`hyper`](https://docs.rs/hyper/latest/hyper/), [`hyper-util`](https://docs.rs/hyper-util/latest/hyper_util/), [`hyper-body-util`](https://docs.rs/http-body-util/latest/http_body_util/) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-27 20:02:00 +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/librespot#1321
No description provided.