title: lxml.etree.XMLSyntaxError: Start tag expected, '<' not found, line 1, column 1
body: <p>This should be simple so not sure why I am getting the error in the title. SVG created is fine as I have manually checked</p>
  
  <pre><code>code to generate svg
  ....
  
  mod_svg = 'final1.svg'
  tree.write(mod_svg)
  
  import cairosvg
  fileout = open('finaltree','w')
  cairosvg.svg2png(bytestring=mod_svg,write_to=fout)
  fileout.close()
  </code></pre>
  
  <p>Im using python 2.7 on pythonanywhere in case it matters. </p>
  
  <p>full traceback</p>
  
  <pre><code>Traceback (most recent call last):
    File "/home/drdavepier/mysite/flask_app.py", line 184, in &lt;module&gt;
      cairosvg.svg2png(bytestring=mod_svg,write_to=fout)
    File "/usr/local/lib/python2.7/dist-packages/cairosvg/__init__.py", line 43, in &lt;lambda&gt;
      surface_type.convert(*args, **kwargs))(_surface_type)
    File "/usr/local/lib/python2.7/dist-packages/cairosvg/surface/__init__.py", line 82, in convert
      tree = Tree(**kwargs)
    File "/usr/local/lib/python2.7/dist-packages/cairosvg/parser.py", line 270, in __init__
      tree = ElementTree.fromstring(bytestring)
    File "lxml.etree.pyx", line 3032, in lxml.etree.fromstring (src/lxml/lxml.etree.c:68121)
    File "parser.pxi", line 1786, in lxml.etree._parseMemoryDocument (src/lxml/lxml.etree.c:102470)
    File "parser.pxi", line 1674, in lxml.etree._parseDoc (src/lxml/lxml.etree.c:101299)
    File "parser.pxi", line 1074, in lxml.etree._BaseParser._parseDoc (src/lxml/lxml.etree.c:96481)
    File "parser.pxi", line 582, in lxml.etree._ParserContext._handleParseResultDoc (src/lxml/lxml.etree.c:91290)
    File "parser.pxi", line 683, in lxml.etree._handleParseResult (src/lxml/lxml.etree.c:92476)
    File "parser.pxi", line 622, in lxml.etree._raiseParseError (src/lxml/lxml.etree.c:91772)
  lxml.etree.XMLSyntaxError: Start tag expected, '&lt;' not found, line 1, column 1
  </code></pre>
  
  <p>opening lines of the relevant SVG</p>
  
  <pre><code>&lt;!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"&gt;
  &lt;!-- Created with matplotlib (http://matplotlib.org/) --&gt;&lt;svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" height="432pt" version="1.1" viewBox="0 0 576 432" width="576pt"&gt;
  </code></pre>
  
  <p>initialisation of tree:</p>
  
  <pre><code>filename = "/path/to/file.svg"
  with open( filename, 'r') as infile:
      tree = etree.parse( infile )
  </code></pre>