JohannesEbke / aws_list_all

List all your AWS resources, all regions, all services.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

application-insights failure

AgentCormac opened this issue · comments

When trying a simple query:
aws-list-all query

the following error is generated:

~\envs\aws\lib\site-packages\aws_list_all\introspection.py", line 343, in get_regions_for_service
regions = set(get_service_regions()[requested_service])
KeyError: 'application-insights'

Dos this mean that the application-insight services reported by AWS is not available in any region? Although this doesnt make sense I would expect this type of error to handled rather than a crash.

OR

What am I doing wrong?

Thanks for your help.

I did have this error. Looks like the service is unsupported at this point of time. The service has to be blacklisted for now.

This is what I have on my introspection.py SERVICE_BLACKLIST attribute

SERVICE_BLACKLIST = [ 'alexaforbusiness', # TODO: Mostly organization-specific calls and would need to be queried differently 'apigatewaymanagementapi', # This API allows management of deployed APIs, and requires an endpoint per API. 'cloudsearchdomain', # Domain-specific endpoint required 'mediastore-data', # Mediastore Container-specific endpoint required 's3control', # TODO: Account-ID specific endpoint required 'application-insights', 'ec2-instance-connect', 'groundstation', 'iotevents', 'iotevents-data', 'iotthingsgraph', 'lakeformation', 'managedblockchain', 'mediapackage-vod', 'personalize', 'personalize-events', 'personalize-runtime', 'service-quotas', ]

Thanks for the bug report - thankfully @arel fixed this in #16 which is included in the latest PyPI version.

The root cause was that your boto3 version was newer than the one aws-list-all was built with. If you install a new boto3 version and want to pick up new services, you can now run aws-list-all recreate-caches. This will discover new endpoints and enable the use of new services without updating aws-list-all.