My guess would be that “github.com/myrepo/myproject” is not actually the same in both cases, for example differing in letter case. Show us the the actual command and actual output if this is not the case, not just your fake placeholders.
You are totally right, it was just a simple typo, I fixed it and moved the go file in cmd/stuff/main.go thengo get github.com/me/myrepo/stuff` and everything worked fine