About this question
I was trying to create a scratch def org following the trailhead
But get stuck in the following section Create and Test Our Scratch Org - Step 2
while executing the following command getting the following error.
sfdx force:org:create -s -f config/project-scratch-def.json -a dreamhouse-org
ERROR running force:org:create: Must pass a username and/or OAuth options when creating an AuthInfo instance.
Steps Executed
Created Project in VSCode
Authorized an Org
Executed Trailhead steps as mentioned in the link
How can I resolve the error while creating scratch def org?