Permalink
Browse files

lxml is not a hard requirement anymore

  • Loading branch information...
1 parent ad62e5f commit 9ea9c9976ddc5cb6bc351ba1d183c0937e2c3092 @plq plq committed Nov 17, 2012
Showing with 11 additions and 12 deletions.
  1. +1 −0 CHANGELOG.rst
  2. +3 −8 README.rst
  3. +1 −2 setup.py
  4. +6 −2 spyne/server/wsgi.py
View
@@ -7,6 +7,7 @@ spyne-2.10.0
* XmlDocument and friends: cleanup_namespaces is now True by default.
* You can now set Http response headers via ctx.out_object when
out_protocol is HttpRpc. https://github.com/arskom/spyne/pull/201
+ * lxml is not a hard requirement anymore.
spyne-2.9.3
-----------
View
@@ -46,20 +46,15 @@ Requirements
Spyne runs on any version of Python from 2.5 through 2.7. We're also looking for
volunteers to test Python 3.x.
-While the aim is to have no requirements besides the standard Python library for
-the Spyne core, the following packages are needed if you want to run any
-Spyne service at all:
-
-* `lxml <http://codespeak.net/lxml/>`_
-* `pytz <http://pytz.sourceforge.net/>`_
-
-both of which are available through ``easy_install``.
+The only hard requirement is `pytz <http://pytz.sourceforge.net/>`_ which is
+available via pypi.
Additionally the following software packages are needed for various subsystems
of Spyne:
* A Wsgi server of your choice is needed to wrap
``spyne.server.wsgi.WsgiApplication``
+* `lxml>=2.3 <http://lxml.de`_ is needed for any xml or html related operation.
* `SQLAlchemy <http://sqlalchemy.org>`_ is needed for
``spyne.model.table.TableModel``.
* `pyzmq <https://github.com/zeromq/pyzmq>`_ is needed for
View
@@ -114,7 +114,7 @@ def run_tests(self):
raise SystemExit(ret)
-test_reqs = ['pytest', 'werkzeug', 'sqlalchemy', 'suds', 'msgpack-python', 'pyparsing']
+test_reqs = ['pytest', 'werkzeug', 'sqlalchemy', 'suds', 'msgpack-python', 'pyparsing', 'lxml>=2.3']
if sys.version_info < (2,6):
test_reqs.extend([
@@ -161,7 +161,6 @@ def run_tests(self):
zip_safe=False,
install_requires=[
'pytz',
- 'lxml>=2.3',
],
entry_points = {
View
@@ -46,10 +46,15 @@
from spyne.error import RequestTooLongError
from spyne.protocol.http import HttpPattern
-from spyne.protocol.soap.mime import apply_mtom
from spyne.util import reconstruct_url
from spyne.server.http import HttpBase
+try:
+ from spyne.protocol.soap.mime import apply_mtom
+except ImportError, e:
+ def apply_mtom(*args, **kwargs):
+ raise f
+
from spyne.const.ansi_color import LIGHT_GREEN
from spyne.const.ansi_color import END_COLOR
from spyne.const.http import HTTP_200
@@ -378,7 +383,6 @@ def __finalize(self, p_ctx):
return []
-
def __reconstruct_wsgi_request(self, http_env):
"""Reconstruct http payload using information in the http header."""

0 comments on commit 9ea9c99

Please sign in to comment.