Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      Libcloud 0.11.3 fails some tests with Python 3.3. Some failures are caused by hash randomization.

      1. libcloud-0.11.3-tests.log
        237 kB
        Arfrever Frehtes Taifersar Arahesis

        Activity

        Hide
        arfrever Arfrever Frehtes Taifersar Arahesis added a comment -

        Output of `PYTHONPATH="build/lib" python3.3 setup.py test`

        Show
        arfrever Arfrever Frehtes Taifersar Arahesis added a comment - Output of `PYTHONPATH="build/lib" python3.3 setup.py test`
        Hide
        kami Tomaz Muraus added a comment -

        Thanks for the report. I'll have a look.

        Show
        kami Tomaz Muraus added a comment - Thanks for the report. I'll have a look.
        Hide
        kami Tomaz Muraus added a comment -

        I've fixed test failures which happened with Python 3.3 due to:

        • changes in xml.etree module
        • changes in xmlrpclib module
        • dictionary hash radnomization

        All the test now pass with Python 3.3 for me. Can you please confirm it?

        Thanks

        Show
        kami Tomaz Muraus added a comment - I've fixed test failures which happened with Python 3.3 due to: changes in xml.etree module changes in xmlrpclib module dictionary hash radnomization All the test now pass with Python 3.3 for me. Can you please confirm it? Thanks
        Hide
        kami Tomaz Muraus added a comment -

        Closing because it the issue has been fixed.

        Show
        kami Tomaz Muraus added a comment - Closing because it the issue has been fixed.
        Hide
        arfrever Arfrever Frehtes Taifersar Arahesis added a comment -

        You accidentally reverted fix in test_ex_get_object_temp_url() in libcloud/branches/0.12.x/libcloud/test/storage/test_cloudfiles.py in r1439028:

        • self.assertEquals(''.join(sorted(ret)), ''.join(sorted(temp_url)))
          + self.assertEquals(ret, temp_url)
        Show
        arfrever Arfrever Frehtes Taifersar Arahesis added a comment - You accidentally reverted fix in test_ex_get_object_temp_url() in libcloud/branches/0.12.x/libcloud/test/storage/test_cloudfiles.py in r1439028: self.assertEquals(''.join(sorted(ret)), ''.join(sorted(temp_url))) + self.assertEquals(ret, temp_url)
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1449746 from Tomaz Muraus
        [ https://svn.apache.org/r1449746 ]

        Fix a regression which could cause test to fail under some circumstances because
        hash ordering is not guaranteed. Part of LIBCLOUD-245.

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1449746 from Tomaz Muraus [ https://svn.apache.org/r1449746 ] Fix a regression which could cause test to fail under some circumstances because hash ordering is not guaranteed. Part of LIBCLOUD-245 .
        Hide
        kami Tomaz Muraus added a comment -

        Arfrever Frehtes Taifersar Arahesis Thanks for spotting this!

        I've fixed it in 1449746.

        A couple of days ago a user on the IRC also reported that 0.12.1 is not working with Python 3 (tests passed). I pushed a fix to 0.12.x branch which I believe fixes the problem (tests still pass, my "manual" testing also worked), but I wasn't able track down the user down and get his confirmation.

        If you are using Libcloud with Python 3.x I would appreciate if you can test it and confirm that the latest version of 0.12.x branch works correctly.

        Show
        kami Tomaz Muraus added a comment - Arfrever Frehtes Taifersar Arahesis Thanks for spotting this! I've fixed it in 1449746. A couple of days ago a user on the IRC also reported that 0.12.1 is not working with Python 3 (tests passed). I pushed a fix to 0.12.x branch which I believe fixes the problem (tests still pass, my "manual" testing also worked), but I wasn't able track down the user down and get his confirmation. If you are using Libcloud with Python 3.x I would appreciate if you can test it and confirm that the latest version of 0.12.x branch works correctly.
        Hide
        arfrever Arfrever Frehtes Taifersar Arahesis added a comment -

        I had seen r1448492. Directly before this revision, tests were passing with Python 3.2, but test suite was failing to run (even before running individual tests) with Python 3.1 and 3.3.

        I confirm that 0.12.x branch now passes all tests with Python 2.6, 2.7, 3.2 and 3.3.

        Show
        arfrever Arfrever Frehtes Taifersar Arahesis added a comment - I had seen r1448492. Directly before this revision, tests were passing with Python 3.2, but test suite was failing to run (even before running individual tests) with Python 3.1 and 3.3. I confirm that 0.12.x branch now passes all tests with Python 2.6, 2.7, 3.2 and 3.3.
        Hide
        arfrever Arfrever Frehtes Taifersar Arahesis added a comment -

        Exact output for Libcloud 0.12.1 and Python 3.3:

        $ python3.3 setup.py test
        running test
        Traceback (most recent call last):
          File "setup.py", line 257, in <module>
            'Programming Language :: Python :: Implementation :: PyPy'])
          File "/usr/lib64/python3.3/distutils/core.py", line 148, in setup
            dist.run_commands()
          File "/usr/lib64/python3.3/distutils/dist.py", line 917, in run_commands
            self.run_command(cmd)
          File "/usr/lib64/python3.3/distutils/dist.py", line 936, in run_command
            cmd_obj.run()
          File "setup.py", line 91, in run
            status = self._run_tests()
          File "setup.py", line 137, in _run_tests
            tests = TestLoader().loadTestsFromNames(testfiles)
          File "/usr/lib64/python3.3/unittest/loader.py", line 137, in loadTestsFromNames
            suites = [self.loadTestsFromName(name, module) for name in names]
          File "/usr/lib64/python3.3/unittest/loader.py", line 137, in <listcomp>
            suites = [self.loadTestsFromName(name, module) for name in names]
          File "/usr/lib64/python3.3/unittest/loader.py", line 105, in loadTestsFromName
            parent, obj = obj, getattr(obj, part)
        AttributeError: 'module' object has no attribute 'test'
        $ python3.3 -c 'import libcloud.utils.py3'
        Traceback (most recent call last):
          File "<string>", line 1, in <module>
          File "./libcloud/utils/py3.py", line 129, in <module>
            from __builtin__ import reload
        ImportError: No module named '__builtin__'
        
        Show
        arfrever Arfrever Frehtes Taifersar Arahesis added a comment - Exact output for Libcloud 0.12.1 and Python 3.3: $ python3.3 setup.py test running test Traceback (most recent call last): File "setup.py", line 257, in <module> 'Programming Language :: Python :: Implementation :: PyPy']) File "/usr/lib64/python3.3/distutils/core.py", line 148, in setup dist.run_commands() File "/usr/lib64/python3.3/distutils/dist.py", line 917, in run_commands self.run_command(cmd) File "/usr/lib64/python3.3/distutils/dist.py", line 936, in run_command cmd_obj.run() File "setup.py", line 91, in run status = self._run_tests() File "setup.py", line 137, in _run_tests tests = TestLoader().loadTestsFromNames(testfiles) File "/usr/lib64/python3.3/unittest/loader.py", line 137, in loadTestsFromNames suites = [self.loadTestsFromName(name, module) for name in names] File "/usr/lib64/python3.3/unittest/loader.py", line 137, in <listcomp> suites = [self.loadTestsFromName(name, module) for name in names] File "/usr/lib64/python3.3/unittest/loader.py", line 105, in loadTestsFromName parent, obj = obj, getattr(obj, part) AttributeError: 'module' object has no attribute 'test' $ python3.3 -c 'import libcloud.utils.py3' Traceback (most recent call last): File "<string>", line 1, in <module> File "./libcloud/utils/py3.py", line 129, in <module> from __builtin__ import reload ImportError: No module named '__builtin__'
        Hide
        kami Tomaz Muraus added a comment -

        Thanks for posting the full output. It's the same issue other user has been experiencing. It looks like my changes fixed it so I will work on creating a new release (0.12.2) with this fix soon.

        It's weird that tox tests passed for 0.12.1 with Python 3.3 though. I need to have a look and make sure tox correctly executes Python 3.3 binary.

        Show
        kami Tomaz Muraus added a comment - Thanks for posting the full output. It's the same issue other user has been experiencing. It looks like my changes fixed it so I will work on creating a new release (0.12.2) with this fix soon. It's weird that tox tests passed for 0.12.1 with Python 3.3 though. I need to have a look and make sure tox correctly executes Python 3.3 binary.

          People

          • Assignee:
            kami Tomaz Muraus
            Reporter:
            arfrever Arfrever Frehtes Taifersar Arahesis
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development