Giter VIP home page Giter VIP logo

django-ranged-fileresponse's People

Contributors

m-vellinga avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

django-ranged-fileresponse's Issues

RangedFileReader.__init__ is slow on large file

Version

0.1.2

File / Feature

class RangedFileReader(object):
    def __init(...)

Expected behaviour

Obtaining the size of the file should be much quicker, and less CPU intensive. We should probably use something like this:

os.fstat(self.f)
self.size = statobj.st_size

Actual behaviour

The current approach for obtaining the size of the file is terribly slow on large files : it uses CPU and disk I/O
self.size = len(self.f.read())

Django 2.0 support

I suspect this already works with Django 2.0, but we could add it to the test environments.

Thank you, and is the project still active?

I use Safari, and I've been trying to add HTML 5 Video to my Django project for a while, and nothing has worked.

Use Django-Ranged-Response solved the problem. So Thank you.

My only concern, is that I see an open issue that implies this code hasn't been tested against Django 2? And Django is up to 3.07 / 3.1, at this time.

Now the good news, is that I ran into no obvious issues with using it with Django 3.0x. But since Django out of the box doesn't support Ranges, I'd like to know if there is some development going on here? What's the roadmap?

Upload the package to pipy?

The package is great!!

Pypi is convenient for deployment because install_requires in setup.py only supports pipy but not git.
Would you want to upload it to pipy?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.