Replace uses of `as_string` from the email lib.

The `as_string` function from `email.message.Message` assumes that it's being
used to encode a message for, well, email transmission -- and as a result, it
changes lines beginning with "From " into lines beginning with ">From ". Given
that we're using that module for multipart uploads, this behavior is surely
not what we want.

We basically inline the body of `as_string`, setting `mangle_from_` to
`False`.
2 files changed
tree: 3108c856a0f882dfc5120518bb24c3d7206ef456
  1. docs/
  2. googleapiclient/
  3. samples/
  4. static/
  5. tests/
  6. tools/
  7. .gitignore
  8. .gitmodules
  9. .hgignore
  10. CHANGELOG
  11. describe.py
  12. expandsymlinks.py
  13. FAQ.md
  14. LICENSE
  15. Makefile
  16. MANIFEST.in
  17. README.md
  18. samples-index.py
  19. setup.py
  20. sitecustomize.py
  21. tox.ini
README.md

About

This is the Python client library for Google's discovery based APIs. To get started, please see the full documentation for this library.

Installation

To install, simply use pip or easy_install:

    $ pip install --upgrade google-api-python-client

or

    $ easy_install --upgrade google-api-python-client

See the Developers Guide for more detailed instructions and additional documentation.

Third Party Libraries

The following libraries will be installed when you install the client library:

Depending on your version of Python, these libraries may also be installed:

For development you will also need:

Contributing

Please see the contributing page for more information. In particular, we love pull requests - but please make sure to sign the contributor license agreement.