Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

actix-test: re-export types from awc #3349

Merged
merged 2 commits into from May 18, 2024
Merged

Conversation

mpalmer
Copy link
Contributor

@mpalmer mpalmer commented May 4, 2024

PR Type

... Other, I guess?

PR Checklist

  • Tests for the changes have been added / updated.
  • Documentation comments have been added / updated.
  • A changelog entry has been made for the appropriate packages.
  • Format code with the latest stable rustfmt.
  • (Team) Label with affected crates and semver status.

Overview

At present, if you want to be able to pass (for example) the response from srv.get()... to a function (so you can, say, parse out the response body and parse it as HTML), you've got to add awc as a dependency and use the types from there.

This change re-exports these awc types directly, to avoid the need for the extra dependency, as well as the risk of dependencies getting out of sync and laying waste to the landscape.

This allows us to pass these types around in functions, without having
to add `awc` as a direct (dev-)dependency.
@mpalmer
Copy link
Contributor Author

mpalmer commented May 4, 2024

I'm not seeing the relationship between my PR and the CI failures; my changes don't seem to relate to TlsConnectorService at all...

@asonix
Copy link
Contributor

asonix commented May 4, 2024

I think those test failures are related to rust 1.78, which just released and is now better at detecting unused code

@mpalmer
Copy link
Contributor Author

mpalmer commented May 4, 2024

Well, I'm glad it's not my fault, because I had no idea how to fix it. 😀 I guess a merge/rebase/whatever once the underlying problem is sorted will green up CI to clear for merge.

@asonix
Copy link
Contributor

asonix commented May 4, 2024

Working on a fix for the build failures: #3350

@robjtede robjtede added B-semver-minor A-test-server project: test-server labels May 18, 2024
@robjtede robjtede enabled auto-merge May 18, 2024 18:44
@robjtede
Copy link
Member

Thanks, this is a fair enough improvement 👍🏻

@robjtede robjtede added this pull request to the merge queue May 18, 2024
Merged via the queue into actix:master with commit 0a2788d May 18, 2024
13 checks passed
jonatansalemes pushed a commit to jonatansalemes/actix-web that referenced this pull request May 19, 2024
This allows us to pass these types around in functions, without having
to add `awc` as a direct (dev-)dependency.

Co-authored-by: Rob Ede <robjtede@icloud.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants