TF-003 Interact with Terraform modules Practice Question
This TF-003 practice question tests your understanding of interact with terraform modules. This is a configuration task: choose the command set that satisfies every stated requirement. Small differences — like 'secret' vs 'password' or 'transport input ssh' vs 'all' — change whether the answer is correct. After answering, compare your reasoning against the explanation and wrong-answer breakdown below. Once you have made your selection, read the full explanation to reinforce the concept and understand why each distractor is designed to mislead on exam day.
Exhibit
Refer to the exhibit.
```hcl
module "vpc" {
source = "terraform-aws-modules/vpc/aws"
version = "3.19.0"
name = "my-vpc"
cidr = "10.0.0.0/16"
azs = ["us-east-1a", "us-east-1b"]
private_subnets = ["10.0.1.0/24", "10.0.2.0/24"]
public_subnets = ["10.0.101.0/24", "10.0.102.0/24"]
}
output "vpc_id" {
value = module.vpc.vpc_id
}
```
The above configuration references a module from the Terraform Registry. After running 'terraform init', the user runs 'terraform plan' and gets an error: 'Error: Unsupported argument' for 'version'. What is the most likely cause?
Clue words in this question
Noticing these words before you look at the options changes how you read each choice.
Clue: "most likely"
Why it matters: Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.
Refer to the exhibit.
```hcl
module "vpc" {
source = "terraform-aws-modules/vpc/aws"
version = "3.19.0"
name = "my-vpc"
cidr = "10.0.0.0/16"
azs = ["us-east-1a", "us-east-1b"]
private_subnets = ["10.0.1.0/24", "10.0.2.0/24"]
public_subnets = ["10.0.101.0/24", "10.0.102.0/24"]
}
output "vpc_id" {
value = module.vpc.vpc_id
}
```
A
The 'version' argument is not supported for this module because the source is not a registry module.
The version argument is only valid for registry modules. If the source is misconfigured, Terraform might treat it as a non-registry source.
B
The 'version' argument must be specified as a constraint like '>= 3.19.0' instead of an exact version.
Why wrong: Exact versions are allowed.
C
The module source is from a Git repository, which does not support the 'version' argument.
If the source is a Git URL, 'version' is not supported; but the exhibit shows a registry source. However, if the source was actually a Git URL, version would be invalid. The error suggests the source is not a registry module.
D
The 'version' argument should be placed inside a 'required_providers' block.
Why wrong: required_providers is for providers, not modules.
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
The 'version' argument is not supported for this module because the source is not a registry module.
The error 'Unsupported argument' for 'version' occurs because the module source is not from a Terraform Registry. The 'version' argument is only valid when the source is a registry module (e.g., 'hashicorp/consul/aws'). If the source is a local path, Git URL, or other non-registry source, Terraform does not support the 'version' argument, as versioning is managed by the registry's metadata.
Key principle: Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
✓
The 'version' argument is not supported for this module because the source is not a registry module.
Why this is correct
The version argument is only valid for registry modules. If the source is misconfigured, Terraform might treat it as a non-registry source.
Clue confirmation
The clue word "most likely" in the question point toward this answer.
Related concept
Read the scenario before looking for a memorised answer.
✗
The 'version' argument must be specified as a constraint like '>= 3.19.0' instead of an exact version.
Why it's wrong here
Exact versions are allowed.
✓
The module source is from a Git repository, which does not support the 'version' argument.
Why this is correct
If the source is a Git URL, 'version' is not supported; but the exhibit shows a registry source. However, if the source was actually a Git URL, version would be invalid. The error suggests the source is not a registry module.
Clue confirmation
The clue word "most likely" in the question point toward this answer.
Related concept
Read the scenario before looking for a memorised answer.
✗
The 'version' argument should be placed inside a 'required_providers' block.
Why it's wrong here
required_providers is for providers, not modules.
Common exam traps
Common exam trap: answer the scenario, not the keyword
HashiCorp often tests the distinction between registry and non-registry module sources, trapping candidates who assume the 'version' argument is universally supported across all module source types.
Detailed technical explanation
How to think about this question
When a module source is a registry module, Terraform fetches the module's metadata from the registry API, which includes available versions. The 'version' argument is then used to select a specific version from that metadata. For non-registry sources (e.g., Git, local paths), Terraform has no version metadata to query, so the 'version' argument is not recognized, leading to the 'Unsupported argument' error. This behavior is defined in the Terraform module source documentation, where only registry modules support version constraints.
KKey Concepts to Remember
Read the scenario before looking for a memorised answer.
Find the constraint that changes the correct option.
Eliminate answers that are true in general but not in this case.
TExam Day Tips
→Watch for words such as best, first, most likely and least administrative effort.
→Review why wrong options are wrong, not only why the correct option is correct.
Key takeaway
Answer the scenario, not the keyword: identify the specific constraint before choosing the most familiar-sounding option.
Real-world example
How this comes up in practice
A small business has 20 workstations on the 192.168.1.0/24 network and one public IP from its ISP. The router uses PAT (NAT overload) so all 20 devices share one public address using different source ports. NAT questions test whether you understand the four address terms and which direction each translation applies.
What to study next
Got this wrong? Here's your next step.
Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.
Interact with Terraform modules — This question tests Interact with Terraform modules — Read the scenario before looking for a memorised answer..
What is the correct answer to this question?
The correct answer is: The 'version' argument is not supported for this module because the source is not a registry module. — The error 'Unsupported argument' for 'version' occurs because the module source is not from a Terraform Registry. The 'version' argument is only valid when the source is a registry module (e.g., 'hashicorp/consul/aws'). If the source is a local path, Git URL, or other non-registry source, Terraform does not support the 'version' argument, as versioning is managed by the registry's metadata.
What should I do if I get this TF-003 question wrong?
Identify which exam domain this question belongs to, review the core concept, then practise similar questions from the same domain.
Are there clue words in this question I should notice?
Yes — watch for: "most likely". Probability qualifier — the question wants the most probable cause or outcome, not a guaranteed one. Eliminate low-probability options.
What is the key concept behind this question?
Read the scenario before looking for a memorised answer.
About these practice questions
Courseiva creates original exam-style practice questions with explanations and wrong-answer analysis. It does not publish real exam questions, exam dumps, or protected exam content. Learn why practice questions differ from exam dumps →
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
This TF-003 practice question is part of Courseiva's free HashiCorp certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the TF-003 exam.
Question Discussion
Share a tip, memory trick, or ask about the reasoning behind this question. Do not post real exam questions, leaked content, braindumps, or copyrighted exam material. Comments are moderated and may be removed without notice.
Sign in to join the discussion.