Reviewed:  https://review.opendev.org/698732
Committed: 
https://git.openstack.org/cgit/openstack/nova/commit/?id=0378c2c780998e7bbba0f2f4f3db281e68f8d981
Submitter: Zuul
Branch:    master

commit 0378c2c780998e7bbba0f2f4f3db281e68f8d981
Author: Stephen Finucane <[email protected]>
Date:   Thu Dec 12 15:00:07 2019 +0000

    Don't hardcode Python versions in test
    
    As noted in change If8184c190e76d8cefb5b097f8fa8cb7564207103, the format
    of an internal error message changed in Python 3. There's no need to
    manually list each of these versions though - just ensure it's Python 3.
    
    Change-Id: Ie1a97d251c6098054bdc963acf53c3182b52b2aa
    Signed-off-by: Stephen Finucane <[email protected]>
    Closes-Bug: #1855493


** Changed in: nova
       Status: In Progress => Fix Released

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

Title:
  py38 unit test failure - test_validate_patternProperties_fails

Status in OpenStack Compute (nova):
  Fix Released

Bug description:
  {0} 
nova.tests.unit.test_api_validation.PatternPropertiesTestCase.test_validate_patternProperties_fails
 [0.132395s] ... FAILED
                                                                                
                                                                                
                                              
  Captured traceback:                                                           
                        
  ~~~~~~~~~~~~~~~~~~~                                                           
                                                                                
                                                  b'Traceback (most recent call 
last):'                                                             
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/nova/api/validation/validators.py", line 
280, in validate'                                
      b'    self.validator.validate(*args, **kwargs)'                           
                        
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/.tox/py38/lib/python3.8/site-packages/jsonschema/validators.py",
 line 352, in validate'         
      b'    for error in self.iter_errors(*args, **kwargs):'                    
                        
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/.tox/py38/lib/python3.8/site-packages/jsonschema/validators.py",
 line 328, in iter_errors'
      b'    for error in errors:'                    
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/.tox/py38/lib/python3.8/site-packages/jsonschema/_validators.py",
 line 22, in patternProperties'
      b'    if re.search(pattern, k):'               
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/.tox/py38/lib/python3.8/re.py", line 199, 
in search'
      b'    return _compile(pattern, flags).search(string)'                     
                        
      b'TypeError: expected string or bytes-like object'                        
                        
      b''                                            
      b'During handling of the above exception, another exception occurred:'    
                        
      b''                                            
      b'Traceback (most recent call last):'          
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/nova/tests/unit/test_api_validation.py", 
line 145, in check_validation_error'
      b'    method(body=body, req=req)'              
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/nova/api/validation/__init__.py", line 
107, in wrapper'
      b"    _schema_validation_helper(request_body_schema, kwargs['body'],"     
                        
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/nova/api/validation/__init__.py", line 
88, in _schema_validation_helper'
      b'    schema_validator.validate(target)'       
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/nova/api/validation/validators.py", line 
314, in validate'
      b'    raise exception.ValidationError(detail=detail)'                     
                        
      b'nova.exception.ValidationError: expected string or bytes-like object'   
                        
      b''                                            
      b'During handling of the above exception, another exception occurred:'    
                        
      b''                                            
      b'Traceback (most recent call last):'          
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/nova/tests/unit/test_api_validation.py", 
line 451, in test_validate_patternProperties_fails'
      b"    self.check_validation_error(self.post, body={None: 'bar'},"         
                        
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/nova/tests/unit/test_api_validation.py", 
line 152, in check_validation_error'
      b"    self.assertEqual(expected_detail, ex.kwargs['detail'],"             
                        
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/.tox/py38/lib/python3.8/site-packages/testtools/testcase.py",
 line 411, in assertEqual'
      b'    self.assertThat(observed, matcher, message)'                        
                        
      b'  File 
"/home/corey/pkg/ussuri/upstream/nova/.tox/py38/lib/python3.8/site-packages/testtools/testcase.py",
 line 498, in assertThat'
      b'    raise mismatch_error'                    
      b"testtools.matchers._impl.MismatchError: 'expected string or buffer' != 
'expected string or bytes-like object': Exception details did not match 
expected"
      b''

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

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp

Reply via email to