Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
P
pkgutils
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 11
    • Issues 11
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 5
    • Merge Requests 5
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • redox-os
  • pkgutils
  • Merge Requests
  • !38

Open
Opened Jul 12, 2020 by Michael McDonnell@MichaelMcDonnell
  • Report abuse
Report abuse

Fix description deprecation warnings

  • Overview 0
  • Commits 1
  • Changes 2

The description and cause methods in Error were soft deprecated in Rust 1.27 and hard deprecated in Rust 1.42 [1]. This change removes the use of these deprecated methods and fixes three deprecation warnings.

You can verify that the test output has not changed with the following steps:

  1. Create the file /etc/pkg.d/localtest
  2. Add the line localhost:1234 to /etc/pkg.d/localtest
  3. Run Netcat on port 1234 in a new terminal to simulate a server:
    $ while true; do { echo -e 'HTTP/0 200 OK\r\n'; } | nc -l 1234; done
    The server returns an invalid HTTP version on purpose.
  4. Try to fetch a package, e.g. pixelcannon:
    $ cargo run -- fetch pixelcannon
  5. Notice that you get the following error message with or without the changes:
    * Requesting http://localhost:1234/x86_64-unknown-linux-gnu/pixelcannon.sig
    pkg: fetch: pixelcannon: failed: Invalid HTTP version specified
Assignee
Assign to
Reviewer
Request review from
None
Milestone
None
Assign milestone
Time tracking
Reference: redox-os/pkgutils!38
Source branch: fix-description-deprecation