I had a similar problem in this task. Looking around this forum I saw a gentleman sugesting change your directory to the folder that is been used on the task. In my case I used “cd sql_reference” before using the others commands that the task is asking for. It worked for me.
Reference: sandy13 BUG: Got kicked out, Lost all progress/branches and Unable to move forward in lesson (Relational Database Cert > Learn Git by Building an SQL Reference Object )