Check validity of username and and repository before doing any operation and raise error accordingly.
Check validity of username and and repository before doing any operation and raise error accordingly.