← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1482958] Re: Don't escape full_path in containers panel in Django 1.8

 

** Changed in: horizon
       Status: Fix Committed => Fix Released

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Dashboard (Horizon).
https://bugs.launchpad.net/bugs/1482958

Title:
  Don't escape full_path in containers panel in Django 1.8

Status in OpenStack Dashboard (Horizon):
  Fix Released

Bug description:
  In Django 1.8, request.get_full_path is now escaped. we don't need
  additional escape call.

  This result to test failure for containers since the url is escaped
  twice:

  ======================================================================
  FAIL: test_delete (openstack_dashboard.dashboards.project.containers.tests.SwiftTests)
  ----------------------------------------------------------------------
  Traceback (most recent call last):
    File "/home/lin-hua-cheng/Documents/workspace/horizon/openstack_dashboard/test/helpers.py", line 110, in instance_stub_out
      return fn(self, *args, **kwargs)
    File "/home/lin-hua-cheng/Documents/workspace/horizon/openstack_dashboard/dashboards/project/containers/tests.py", line 311, in test_delete
      self.assertEqual(handled['location'], index_url)
  AssertionError: '/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'
      "'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'" = '%s != %s' % (safe_repr('/project/containers/container%2520one%2525%25E6%258D%2586/'), safe_repr(u'/project/containers/container%20one%25%E6%8D%86/'))
      "'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'" = self._formatMessage("'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'", "'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'")
  >>  raise self.failureException("'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'")
      

  ======================================================================
  FAIL: test_delete_pseudo_folder (openstack_dashboard.dashboards.project.containers.tests.SwiftTests)
  ----------------------------------------------------------------------
  Traceback (most recent call last):
    File "/home/lin-hua-cheng/Documents/workspace/horizon/openstack_dashboard/test/helpers.py", line 110, in instance_stub_out
      return fn(self, *args, **kwargs)
    File "/home/lin-hua-cheng/Documents/workspace/horizon/openstack_dashboard/dashboards/project/containers/tests.py", line 331, in test_delete_pseudo_folder
      self.assertEqual(handled['location'], index_url)
  AssertionError: '/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'
      "'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'" = '%s != %s' % (safe_repr('/project/containers/container%2520one%2525%25E6%258D%2586/'), safe_repr(u'/project/containers/container%20one%25%E6%8D%86/'))
      "'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'" = self._formatMessage("'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'", "'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'")
  >>  raise self.failureException("'/project/containers/container%2520one%2525%25E6%258D%2586/' != u'/project/containers/container%20one%25%E6%8D%86/'")
      

  ======================================================================
  FAIL: test_index_container_selected (openstack_dashboard.dashboards.project.containers.tests.SwiftTests)
  ----------------------------------------------------------------------
  Traceback (most recent call last):
    File "/home/lin-hua-cheng/Documents/workspace/horizon/openstack_dashboard/test/helpers.py", line 110, in instance_stub_out
      return fn(self, *args, **kwargs)
    File "/home/lin-hua-cheng/Documents/workspace/horizon/openstack_dashboard/dashboards/project/containers/tests.py", line 195, in test_index_container_selected
      self.assertContains(res, form_action, count=2)
    File "/home/lin-hua-cheng/Documents/workspace/horizon/.venv/local/lib/python2.7/site-packages/django/test/testcases.py", line 355, in assertContains
      " (expected %d)" % (real_count, text_repr, count))
  AssertionError: Found 0 instances of ' action="/project/containers/container%20one%25%E6%8D%86/" ' in response (expected 2)
      '0 != 2' = '%s != %s' % (safe_repr(0), safe_repr(2))
      u'Found 0 instances of \' action="/project/containers/container%20one%25%E6%8D%86/" \' in response (expected 2)' = self._formatMessage(u'Found 0 instances of \' action="/project/containers/container%20one%25%E6%8D%86/" \' in response (expected 2)', '0 != 2')
  >>  raise self.failureException(u'Found 0 instances of \' action="/project/containers/container%20one%25%E6%8D%86/" \' in response (expected 2)')

To manage notifications about this bug go to:
https://bugs.launchpad.net/horizon/+bug/1482958/+subscriptions


References