Bug 1757414 - ovirt-hosted-engine-ha python3 unicode fails testing
Summary: ovirt-hosted-engine-ha python3 unicode fails testing
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: ovirt-hosted-engine-ha
Classification: oVirt
Component: General
Version: 2.3.5
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ovirt-4.4.0
: 2.4.0
Assignee: Simone Tiraboschi
QA Contact: Sandro Bonazzola
URL:
Whiteboard:
Depends On:
Blocks: 1726988
TreeView+ depends on / blocked
 
Reported: 2019-10-01 13:07 UTC by Sandro Bonazzola
Modified: 2020-05-20 20:01 UTC (History)
1 user (show)

Fixed In Version: ovirt-hosted-engine-ha-2.4.0
Clone Of:
Environment:
Last Closed: 2020-05-20 20:01:17 UTC
oVirt Team: Integration
Embargoed:
sbonazzo: ovirt-4.4?
sbonazzo: blocker?


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 103756 0 'None' MERGED Fix unicode handling on python-3 on EngineXml 2020-04-07 12:17:14 UTC

Description Sandro Bonazzola 2019-10-01 13:07:40 UTC
Building on Fedora 30 with python3:

+ make test
nosetests-3 .
........EE......
======================================================================
ERROR: test_convert_to_dict_42 (ovirt_hosted_engine_ha.lib.ovf.ovf2VmParams_test.Ovf2vmConfTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/jenkins/workspace/ovirt-hosted-engine-ha_standard-check-patch/ovirt-hosted-engine-ha/tmp.repos/BUILD/ovirt-hosted-engine-ha-2.4.0-0.0.master.20191001124801/ovirt_hosted_engine_ha/lib/ovf/ovf2VmParams_test.py", line 558, in test_convert_to_dict_42
    t = ovf2VmParams.toDict(OVF_42)
  File "/home/jenkins/workspace/ovirt-hosted-engine-ha_standard-check-patch/ovirt-hosted-engine-ha/tmp.repos/BUILD/ovirt-hosted-engine-ha-2.4.0-0.0.master.20191001124801/ovirt_hosted_engine_ha/lib/ovf/ovf2VmParams.py", line 231, in toDict
    engine_xml_tree = ovfenvelope.etree_.fromstring(engine_xml[0])
  File "src/lxml/etree.pyx", line 3213, in lxml.etree.fromstring
  File "src/lxml/parser.pxi", line 1872, in lxml.etree._parseMemoryDocument
ValueError: Unicode strings with encoding declaration are not supported. Please use bytes input or XML fragments without declaration.

======================================================================
ERROR: test_convert_to_dict_42_unsafe (ovirt_hosted_engine_ha.lib.ovf.ovf2VmParams_test.Ovf2vmConfTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/jenkins/workspace/ovirt-hosted-engine-ha_standard-check-patch/ovirt-hosted-engine-ha/tmp.repos/BUILD/ovirt-hosted-engine-ha-2.4.0-0.0.master.20191001124801/ovirt_hosted_engine_ha/lib/ovf/ovf2VmParams_test.py", line 541, in test_convert_to_dict_42_unsafe
    ovf2VmParams.toDict(OVF_42_UNSAFE))
  File "/home/jenkins/workspace/ovirt-hosted-engine-ha_standard-check-patch/ovirt-hosted-engine-ha/tmp.repos/BUILD/ovirt-hosted-engine-ha-2.4.0-0.0.master.20191001124801/ovirt_hosted_engine_ha/lib/ovf/ovf2VmParams.py", line 231, in toDict
    engine_xml_tree = ovfenvelope.etree_.fromstring(engine_xml[0])
  File "src/lxml/etree.pyx", line 3213, in lxml.etree.fromstring
  File "src/lxml/parser.pxi", line 1872, in lxml.etree._parseMemoryDocument
ValueError: Unicode strings with encoding declaration are not supported. Please use bytes input or XML fragments without declaration.

----------------------------------------------------------------------
Ran 16 tests in 0.520s

Comment 1 Sandro Bonazzola 2019-10-01 13:08:14 UTC
This issue is blocking https://gerrit.ovirt.org/103724

Comment 4 Sandro Bonazzola 2020-05-20 20:01:17 UTC
This bugzilla is included in oVirt 4.4.0 release, published on May 20th 2020.

Since the problem described in this bug report should be
resolved in oVirt 4.4.0 release, it has been closed with a resolution of CURRENT RELEASE.

If the solution does not work for you, please open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.