Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError 'NoneType' object is not iterable version 0.9.8 #433

Closed
hiennguyenvan-agilityio opened this issue Dec 4, 2019 · 4 comments
Closed

Comments

@hiennguyenvan-agilityio
Copy link

hiennguyenvan-agilityio commented Dec 4, 2019

Describe the bug
I got an issue TypeError 'NoneType' object is not iterable with the latest version 0.9.8 on MacOS 10.14

To Reproduce

  • Install taskcat pip3 install taskcat
  • Write .taskcat.yml
general:
  s3_bucket: test-bucket
  auth:
    default: myaccount
project:
  name: my-cfn-project
  auth:
    default: myaccount
tests:
  default:
    auth:
      default: myaccount
    template: ./vpc.yml
    parameters:
      EnvironmentName: Test
  • Run taskcat test run. It's worked as expection
  • Add a nested stack to vpc.yml with wrong path
  • Run taskcat test run. I got path not found error and TypeError 'NoneType' object is not iterable
  • I replace wrong path with correct path (even s3 path). I don't got path not found any more but still got TypeError 'NoneType' object is not iterable
  • Now I got error TypeError 'NoneType' object is not iterable anytime run taskcat test run. I tried remove nested stack but the error still here.

Screenshots
Screen Shot 2019-12-04 at 4 55 34 PM
Screen Shot 2019-12-04 at 4 58 17 PM
Screen Shot 2019-12-04 at 5 01 47 PM
Screen Shot 2019-12-04 at 5 02 52 PM

**Version

  • Taskcat Version 0.9.8
  • Python 3.7.4
  • MacOS version 10.14
@andrew-glenn andrew-glenn added bug next-point-release Slated for the next release of taskcat labels Dec 4, 2019
@hiennguyenvan-agilityio
Copy link
Author

hiennguyenvan-agilityio commented Dec 5, 2019

I got the detail message when try again in the morning

version 0.9.8
[ERROR  ] : ValidationError None is not of type 'object'

Failed validating 'type' in schema:
    {'$schema': 'http://json-schema.org/draft-06/schema#',
     'additionalProperties': False,
     'definitions': {'GeneralConfig': {'additionalProperties': False,
                                       'description': 'General '
                                                      'configuration '
                                                      'settings.',
                                       'properties': {'auth': {'additionalProperties': {'type': 'string'},
                                                               'description': 'AWS '
                                                                              'authentication '
                                                                              'section',
                                                               'type': 'object'},
                                                      'parameters': {'additionalProperties': {'oneOf': [{'type': 'string'},
                                                                                                        {'type': 'integer'},
                                                                                                        {'type': 'boolean'},
                                                                                                        {'items': {'oneOf': [{'type': 'integer'},
                                                                                                                             {'type': 'string'}]},
                                                                                                         'type': 'array'}]},
                                                                     'description': 'Parameter '
                                                                                    'key-values '
                                                                                    'to '
                                                                                    'pass '
                                                                                    'to '
                                                                                    'CloudFormation, '
                                                                                    'parameters '
                                                                                    'provided '
                                                                                    'in '
                                                                                    'global '
                                                                                    'config '
                                                                                    'take '
                                                                                    'precedence',
                                                                     'type': 'object'},
                                                      's3_bucket': {'description': 'Name '
                                                                                   'of '
                                                                                   'S3 '
                                                                                   'bucket '
                                                                                   'to '
                                                                                   'upload '
                                                                                   'project '
                                                                                   'to, '
                                                                                   'if '
                                                                                   'left '
                                                                                   'out '
                                                                                   'a '
                                                                                   'bucket '
                                                                                   'will '
                                                                                   'be '
                                                                                   'auto-generated',
                                                                    'type': 'string'},
                                                      'tags': {'additionalProperties': {'type': 'string'},
                                                               'description': 'Tags '
                                                                              'to '
                                                                              'apply '
                                                                              'to '
                                                                              'CloudFormation '
                                                                              'template',
                                                               'type': 'object'}},
                                       'type': 'object'},
                     'ProjectConfig': {'additionalProperties': False,
                                       'description': 'Project specific '
                                                      'configuration '
                                                      'section',
                                       'properties': {'auth': {'additionalProperties': {'type': 'string'},
                                                               'description': 'AWS '
                                                                              'authentication '
                                                                              'section',
                                                               'type': 'object'},
                                                      'az_blacklist': {'description': 'List '
                                                                                      'of '
                                                                                      'Availablilty '
                                                                                      'Zones '
                                                                                      "ID's "
                                                                                      'to '
                                                                                      'exclude '
                                                                                      'when '
                                                                                      'generating '
                                                                                      'availability '
                                                                                      'zones',
                                                                       'items': {'description': 'Availability '
                                                                                                'Zone '
                                                                                                'ID, '
                                                                                                'eg.: '
                                                                                                "'use1-az1'",
                                                                                 'pattern': '^(ap|eu|us|sa|ca|cn|af|me)(n|s|e|w|c|ne|se|nw|sw)[0-9]-az[0-9]$',
                                                                                 'type': 'string'},
                                                                       'type': 'array'},
                                                      'build_submodules': {'description': 'Build '
                                                                                          'Lambda '
                                                                                          'zips '
                                                                                          'recursively '
                                                                                          'for '
                                                                                          'submodules, '
                                                                                          'set '
                                                                                          'to '
                                                                                          'false '
                                                                                          'to '
                                                                                          'disable',
                                                                           'type': 'boolean'},
                                                      'lambda_source_path': {'description': 'Path '
                                                                                            'relative '
                                                                                            'to '
                                                                                            'the '
                                                                                            'project '
                                                                                            'root '
                                                                                            'containing '
                                                                                            'Lambda '
                                                                                            'zip '
                                                                                            'files, '
                                                                                            'default '
                                                                                            'is '
                                                                                            "'lambda_functions/source'",
                                                                             'type': 'string'},
                                                      'lambda_zip_path': {'description': 'Path '
                                                                                         'relative '
                                                                                         'to '
                                                                                         'the '
                                                                                         'project '
                                                                                         'root '
                                                                                         'to '
                                                                                         'place '
                                                                                         'Lambda '
                                                                                         'zip '
                                                                                         'files, '
                                                                                         'default '
                                                                                         'is '
                                                                                         "'lambda_functions/zips'",
                                                                          'type': 'string'},
                                                      'name': {'description': 'Project '
                                                                              'name, '
                                                                              'used '
                                                                              'as '
                                                                              's3 '
                                                                              'key '
                                                                              'prefix '
                                                                              'when '
                                                                              'uploading '
                                                                              'objects',
                                                               'pattern': '^[a-z0-9-]*$',
                                                               'type': 'string'},
                                                      'owner': {'description': 'email '
                                                                               'address '
                                                                               'for '
                                                                               'project '
                                                                               'owner '
                                                                               '(not '
                                                                               'used '
                                                                               'at '
                                                                               'present)',
                                                                'type': 'string'},
                                                      'package_lambda': {'description': 'Package '
                                                                                        'Lambda '
                                                                                        'functions '
                                                                                        'into '
                                                                                        'zips '
                                                                                        'before '
                                                                                        'uploading '
                                                                                        'to '
                                                                                        's3, '
                                                                                        'set '
                                                                                        'to '
                                                                                        'false '
                                                                                        'to '
                                                                                        'disable',
                                                                         'type': 'boolean'},
                                                      'parameters': {'additionalProperties': {'oneOf': [{'type': 'string'},
                                                                                                        {'type': 'integer'},
                                                                                                        {'type': 'boolean'},
                                                                                                        {'items': {'oneOf': [{'type': 'integer'},
                                                                                                                             {'type': 'string'}]},
                                                                                                         'type': 'array'}]},
                                                                     'description': 'Parameter '
                                                                                    'key-values '
                                                                                    'to '
                                                                                    'pass '
                                                                                    'to '
                                                                                    'CloudFormation, '
                                                                                    'parameters '
                                                                                    'provided '
                                                                                    'in '
                                                                                    'global '
                                                                                    'config '
                                                                                    'take '
                                                                                    'precedence',
                                                                     'type': 'object'},
                                                      'regions': {'description': 'List '
                                                                                 'of '
                                                                                 'AWS '
                                                                                 'regions',
                                                                  'items': {'description': 'AWS '
                                                                                           'Region '
                                                                                           'name '
                                                                                           'eg.: '
                                                                                           "'us-east-1'",
                                                                            'pattern': '^(ap|eu|us|sa|ca|cn|af|me|us-gov)-(central|south|north|east|west|southeast|southwest|northeast|northwest)-[0-9]$',
                                                                            'type': 'string'},
                                                                  'type': 'array'},
                                                      's3_bucket': {'description': 'Name '
                                                                                   'of '
                                                                                   'S3 '
                                                                                   'bucket '
                                                                                   'to '
                                                                                   'upload '
                                                                                   'project '
                                                                                   'to, '
                                                                                   'if '
                                                                                   'left '
                                                                                   'out '
                                                                                   'a '
                                                                                   'bucket '
                                                                                   'will '
                                                                                   'be '
                                                                                   'auto-generated',
                                                                    'pattern': '^[a-z0-9-]*$',
                                                                    'type': 'string'},
                                                      's3_enable_sig_v2': {'description': 'Enable '
                                                                                          '(deprecated) '
                                                                                          'sigv2 '
                                                                                          'access '
                                                                                          'to '
                                                                                          'auto-generated '
                                                                                          'buckets',
                                                                           'type': 'boolean'},
                                                      's3_object_acl': {'description': 'ACL '
                                                                                       'for '
                                                                                       'uploaded '
                                                                                       's3 '
                                                                                       'objects, '
                                                                                       'defaults '
                                                                                       'to '
                                                                                       "'private'",
                                                                        'type': 'string'},
                                                      'tags': {'additionalProperties': {'type': 'string'},
                                                               'description': 'Tags '
                                                                              'to '
                                                                              'apply '
                                                                              'to '
                                                                              'CloudFormation '
                                                                              'template',
                                                               'type': 'object'},
                                                      'template': {'description': 'path '
                                                                                  'to '
                                                                                  'template '
                                                                                  'file '
                                                                                  'relative '
                                                                                  'to '
                                                                                  'the '
                                                                                  'project '
                                                                                  'config '
                                                                                  'file '
                                                                                  'path',
                                                                   'type': 'string'}},
                                       'type': 'object'},
                     'TestConfig': {'additionalProperties': False,
                                    'description': 'Test specific '
                                                   'configuration section.',
                                    'properties': {'auth': {'additionalProperties': {'type': 'string'},
                                                            'description': 'AWS '
                                                                           'authentication '
                                                                           'section',
                                                            'type': 'object'},
                                                   'az_blacklist': {'description': 'List '
                                                                                   'of '
                                                                                   'Availablilty '
                                                                                   'Zones '
                                                                                   "ID's "
                                                                                   'to '
                                                                                   'exclude '
                                                                                   'when '
                                                                                   'generating '
                                                                                   'availability '
                                                                                   'zones',
                                                                    'items': {'description': 'Availability '
                                                                                             'Zone '
                                                                                             'ID, '
                                                                                             'eg.: '
                                                                                             "'use1-az1'",
                                                                              'pattern': '^(ap|eu|us|sa|ca|cn|af|me)(n|s|e|w|c|ne|se|nw|sw)[0-9]-az[0-9]$',
                                                                              'type': 'string'},
                                                                    'type': 'array'},
                                                   'parameters': {'additionalProperties': {'oneOf': [{'type': 'string'},
                                                                                                     {'type': 'integer'},
                                                                                                     {'type': 'boolean'},
                                                                                                     {'items': {'oneOf': [{'type': 'integer'},
                                                                                                                          {'type': 'string'}]},
                                                                                                      'type': 'array'}]},
                                                                  'default': {},
                                                                  'description': 'Parameter '
                                                                                 'key-values '
                                                                                 'to '
                                                                                 'pass '
                                                                                 'to '
                                                                                 'CloudFormation, '
                                                                                 'parameters '
                                                                                 'provided '
                                                                                 'in '
                                                                                 'global '
                                                                                 'config '
                                                                                 'take '
                                                                                 'precedence',
                                                                  'type': 'object'},
                                                   'regions': {'description': 'List '
                                                                              'of '
                                                                              'AWS '
                                                                              'regions',
                                                               'items': {'description': 'AWS '
                                                                                        'Region '
                                                                                        'name '
                                                                                        'eg.: '
                                                                                        "'us-east-1'",
                                                                         'pattern': '^(ap|eu|us|sa|ca|cn|af|me|us-gov)-(central|south|north|east|west|southeast|southwest|northeast|northwest)-[0-9]$',
                                                                         'type': 'string'},
                                                               'type': 'array'},
                                                   's3_bucket': {'description': 'Name '
                                                                                'of '
                                                                                'S3 '
                                                                                'bucket '
                                                                                'to '
                                                                                'upload '
                                                                                'project '
                                                                                'to, '
                                                                                'if '
                                                                                'left '
                                                                                'out '
                                                                                'a '
                                                                                'bucket '
                                                                                'will '
                                                                                'be '
                                                                                'auto-generated',
                                                                 'pattern': '^[a-z0-9-]*$',
                                                                 'type': 'string'},
                                                   'tags': {'additionalProperties': {'type': 'string'},
                                                            'description': 'Tags '
                                                                           'to '
                                                                           'apply '
                                                                           'to '
                                                                           'CloudFormation '
                                                                           'template',
                                                            'type': 'object'},
                                                   'template': {'description': 'path '
                                                                               'to '
                                                                               'template '
                                                                               'file '
                                                                               'relative '
                                                                               'to '
                                                                               'the '
                                                                               'project '
                                                                               'config '
                                                                               'file '
                                                                               'path',
                                                                'type': 'string'}},
                                    'type': 'object'}},
     'description': 'Taskcat configuration file',
     'properties': {'general': {'$ref': '#/definitions/GeneralConfig',
                                'default': {'auth': None,
                                            'parameters': None,
                                            's3_bucket': None,
                                            'tags': None}},
                    'project': {'$ref': '#/definitions/ProjectConfig',
                                'default': {'auth': None,
                                            'az_blacklist': None,
                                            'build_submodules': None,
                                            'lambda_source_path': None,
                                            'lambda_zip_path': None,
                                            'name': None,
                                            'owner': None,
                                            'package_lambda': None,
                                            'parameters': None,
                                            'regions': None,
                                            's3_bucket': None,
                                            's3_enable_sig_v2': None,
                                            's3_object_acl': None,
                                            'tags': None,
                                            'template': None}},
                    'tests': {'additionalProperties': {'$ref': '#/definitions/TestConfig'},
                              'default': {},
                              'type': 'object'}},
     'type': 'object'}

On instance:
    None

@andrew-glenn
Copy link
Contributor

@HienNguyenAsnet - can you confirm this is still present in 0.9.12?

@andrew-glenn andrew-glenn removed bug next-point-release Slated for the next release of taskcat labels Apr 19, 2020
@andrew-glenn
Copy link
Contributor

This should be fixed at this point (0.9.17). If this is not the case, please reopen.

@AmrishJhaveri
Copy link

I would like to reopen this issue. I am facing the same issue and have tried with taskcat version 0.9.17 and 0.9.20

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants