Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.maint.python > #9943

Bug#879125: ITP: python-requests-file -- File transport adapter for Requests

From Antoine Beaupre <anarcat@debian.org>
Newsgroups linux.debian.bugs.dist, linux.debian.devel, linux.debian.maint.python
Subject Bug#879125: ITP: python-requests-file -- File transport adapter for Requests
Date 2017-10-19 20:30 +0200
Message-ID <uCnJU-1Gz-9@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Cross-posted to 3 groups.

Show all headers | View raw


Package: wnpp
Severity: wishlist
Owner: Antoine Beaupre <anarcat@debian.org>

* Package name    : python-requests-file
  Version         : 2017-04-28
  Upstream Author : David Shea
* URL             : https://pypi.python.org/pypi/requests-file
* License         : Apache 2.0
  Programming Lang: Python
  Description     : File transport adapter for Requests

Requests-File is a transport adapter for use with the Requests Python
library to allow local filesystem access via file:// URLs.

Features:

 * Will open and read local files
 * Might set a Content-Length header
 * That’s about it

No encoding information is set in the response object, so be careful
using Response.text: the chardet library will be used to convert the
file to a unicode type and it may not detect what you actually want.

EACCES is converted to a 403 status code, and ENOENT is converted to a
404. All other IOError types are converted to a 400.

==

I plan on shoving this into py2dsp and co-maintaining it with whoever
wants to. I need this to simplify feed2exec local file:// access
routines and I think it's a generally good package to have available
(and why isn't this in requests in the first place??)

I'd be happy to delegate this to the Python team as well of course.

Back to linux.debian.maint.python | Previous | Next | Find similar | Unroll thread


Thread

Bug#879125: ITP: python-requests-file -- File transport adapter for Requests Antoine Beaupre <anarcat@debian.org> - 2017-10-19 20:30 +0200

csiph-web