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

Support partial request for media resource #1050

Closed
wants to merge 2 commits into from

Conversation

@marschhuynh
Copy link
Contributor

@marschhuynh marschhuynh commented Aug 20, 2017

I am creating an API for record and playback audio. I use Eve as a main lib for my project.
Without partial request, my player in my phone (iPhone) can not work.

So I change a little code to make Eve support partial request for the media resource.

Hope that makes sense.

Thanks.

@Amedeo91
Copy link

@Amedeo91 Amedeo91 commented Aug 22, 2017

@nicolaiarocci: what do you think? Personally I do not see test coverage...

@nicolaiarocci
Copy link
Member

@nicolaiarocci nicolaiarocci commented Aug 30, 2017

Hello and thanks for this. It is indeed a very cool feature. However, it would also need test coverage.

if g[0]:
byte1 = int(g[0])
if g[1]:
byte2 = int(g[1])

This comment has been minimized.

@peterdemin

peterdemin Aug 30, 2017

g[1] might be empty string, which will break int(''):

>>> int('')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ValueError: invalid literal for int() with base 10: ''

This comment has been minimized.

@marschhuynh

marschhuynh Aug 30, 2017
Author Contributor

@nicolaiarocci Yes, I will update the test as soon as possible.

@peterdemin Thank you for correcting me.

@nicolaiarocci
Copy link
Member

@nicolaiarocci nicolaiarocci commented Nov 7, 2017

This is still waiting on proper test coverage. Are you still planning to add it?

@nicolaiarocci nicolaiarocci added this to the 0.8 milestone Nov 7, 2017
@nicolaiarocci
Copy link
Member

@nicolaiarocci nicolaiarocci commented Dec 26, 2017

Thanks for the commit update. I really want to merge this but I can't in its current state. Still waiting for test coverage.

nicolaiarocci added a commit that referenced this pull request Apr 5, 2018
nicolaiarocci added a commit that referenced this pull request Apr 5, 2018
nicolaiarocci added a commit that referenced this pull request Apr 5, 2018
nicolaiarocci added a commit that referenced this pull request Apr 5, 2018
nicolaiarocci added a commit that referenced this pull request Apr 5, 2018
nicolaiarocci added a commit that referenced this pull request Apr 5, 2018
nicolaiarocci added a commit that referenced this pull request Apr 5, 2018
nicolaiarocci added a commit that referenced this pull request Apr 5, 2018
@nicolaiarocci
Copy link
Member

@nicolaiarocci nicolaiarocci commented Apr 5, 2018

Refactored, rebased, test-covered, and finally merged. See 9ee2b5b

lexhung added a commit to lexhung/eve that referenced this pull request Dec 12, 2018
* upstream/master: (32 commits)
  Get rid of unwanted .vscode folder
  Add support for mongo $box geo query operator
  Marsch Huynh
  Improve partial downloads documentation
  Changelog for pyeve#1050
  Test coverage for pyeve#1050
  A little refactoring (DRY). Addresses pyeve#1050.
  fix: media endpoint
  Support partial request for media resource
  Officially deprecate Python 2.6
  Changelog for pyeve#1130
  Reduced error description details
  Fix PUT behavior with User-Restricted Resource Access
  flake8
  typo
  Hung Le
  Changelog for pyeve#1095.
  Regression test for PR pyeve#1095.
  Oplog skipped even if confg.OPLOG=True
  DHuan
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants