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

Deprecated BaseRequest.has_body, replaced with 2 new attributes (#2005) #2169

Merged
merged 2 commits into from
Aug 7, 2017
Merged

Deprecated BaseRequest.has_body, replaced with 2 new attributes (#2005) #2169

merged 2 commits into from
Aug 7, 2017

Conversation

ghost
Copy link

@ghost ghost commented Aug 5, 2017

#2005

  • Deprecated BaseRequest.has_body in favour of BaseRequest.can_read_body
  • Added BaseRequest.body_exists attribute that stays static for the lifetime
    of the request

@codecov-io
Copy link

codecov-io commented Aug 5, 2017

Codecov Report

Merging #2169 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2169      +/-   ##
==========================================
+ Coverage   97.12%   97.12%   +<.01%     
==========================================
  Files          39       39              
  Lines        7848     7884      +36     
  Branches     1360     1366       +6     
==========================================
+ Hits         7622     7657      +35     
  Misses        101      101              
- Partials      125      126       +1
Impacted Files Coverage Δ
aiohttp/web_request.py 99.01% <100%> (+0.01%) ⬆️
aiohttp/web_urldispatcher.py 99.34% <0%> (-0.14%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4aba753...171ad0a. Read the comment docs.

warnings.warn(
"Deprecated, use .can_read_body #2005",
DeprecationWarning, stacklevel=2)
return not self._payload.at_eof()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please add a test for the case

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added old attr back into test cases - is this okay or should I break it out into another test case?

@asvetlov asvetlov merged commit dda632b into aio-libs:master Aug 7, 2017
@asvetlov
Copy link
Member

asvetlov commented Aug 7, 2017

thanks

arthurdarcet pushed a commit to arthurdarcet/aiohttp that referenced this pull request Aug 8, 2017
…libs#2005) (aio-libs#2169)

* Deprecated BaseRequest.has_body, replaced with 2 new attributes

* Test obsolete BaseRequest.has_body attr
@lock
Copy link

lock bot commented Oct 28, 2019

This thread has been automatically locked since there has not been
any recent activity after it was closed. Please open a new issue for
related bugs.

If you feel like there's important points made in this discussion,
please include those exceprts into that new issue.

@lock lock bot added the outdated label Oct 28, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Oct 28, 2019
@psf-chronographer psf-chronographer bot added the bot:chronographer:provided There is a change note present in this PR label Oct 28, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bot:chronographer:provided There is a change note present in this PR outdated
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants