Skip to content

Invalid index in module "ecs_service" in v 4.0.1 #369

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

Closed
1 task
alexandreags opened this issue Nov 10, 2023 · 3 comments · Fixed by #370
Closed
1 task

Invalid index in module "ecs_service" in v 4.0.1 #369

alexandreags opened this issue Nov 10, 2023 · 3 comments · Fixed by #370

Comments

@alexandreags
Copy link

Description

│ Error: Invalid index

│ on main.tf line 378, in module "ecs_service":
│ 378: access_point_id = module.efs.access_points["atlantis"].id
│ ├────────────────
│ │ module.efs.access_points is object with no attributes

│ The given key does not identify an element in this collection value.

  • ✋ I have searched the open/closed issues and my issue is not listed.

Versions

  • Module version 4.0.1:

  • Terraform version:
    1.5.7

  • Provider version(s):
    5.24.0

Reproduction Code: Use default Values

Expected behavior

Actual behavior

Module install successfully

Terminal Output Screenshot(s)

│ Error: Invalid index

│ on main.tf line 378, in module "ecs_service":
│ 378: access_point_id = module.efs.access_points["atlantis"].id
│ ├────────────────
│ │ module.efs.access_points is object with no attributes

│ The given key does not identify an element in this collection value.

Additional context

I have fixed this (temporarily) changing the logic to:

378: access_point_id = try(module.efs.access_points["atlantis"].id, "")

I dont know if this is ideal, but is a workaround

@bryantbiggs
Copy link
Member

thank you - this should be fixed in #370

@antonbabenko
Copy link
Member

This issue has been resolved in version 4.0.2 🎉

Copy link

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Dec 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
3 participants