bored-electrician-25503
03/12/2025, 8:05 AMComponent Resources
to create VPC and internet gateways. I need to fetch availability zones for the given region for subnets and the region will be passed as JSON in the API. Here is my code looks like:
class VPC(pulumi.ComponentResource):
def __init__(self, name: str, stack_args: AWSStackBase, opts: pulumi.ResourceOptions=None):
super().__init__("Custom:Component:VPC", name, {}, opts)
self.availability_zones = aws.get_availability_zones(filters[{
"name": "region-name",
"values": [f"{stack_args.region}"]
}])
This is giving this error:
AttributeError: 'NoneType' object has no attribute 'Invoke'
Any help in solving this would be highly appreciated.No matter how you like to participate in developer communities, Pulumi wants to meet you there. If you want to meet other Pulumi users to share use-cases and best practices, contribute code or documentation, see us at an event, or just tell a story about something cool you did with Pulumi, you are part of our community.
Powered by