https://pulumi.com logo
#typescript
Title
# typescript
n

nutritious-flower-51098

09/11/2020, 10:32 AM
Hi, we’re trying to write a StackValidation policy on a helm chart. However, we can’t filter on these resources:
Copy code
args.resources.filter(r => r.isType(kubernetes.helm.v3.Chart)).map( resource => {
      <http://pulumi.log.info|pulumi.log.info>(`We have a resource ${resource.type} = ${resource.name}`)
    }) // This doesn't print out anything
But if we remove
.filter()
, we can see our
kubernetes:<http://helm.sh/v3:Chart|helm.sh/v3:Chart>
resource. Shouldn’t this work?
g

gentle-diamond-70147

09/11/2020, 3:21 PM
I think
Chart
is actually a
ComponentResource
, so you need to do something special there... let me look.
n

nutritious-flower-51098

09/11/2020, 3:55 PM
ok, makes sense
thanks!