Create Git Troubleshooting authored by Radek Ošlejšek's avatar Radek Ošlejšek
**Git says `fatal: refusing to merge unrelated histories`.**
- Add `--allow-unrelated-histories` argument and try again.
**I cannot push to git, I am getting a message: ```GitLab: you are not allowed to push code to this project. Fatal: Could not read from remote repository.```**
- You are probably pushing to public repository. You want to push to your private one.
**I cannot pull iteration.**
- You probably have uncommited changes. The solution is one of these:
- commit (save) changes: `git add -A && git commit -m "Message"`
- remove (delete) changes: `git reset --hard`
**I get an error `Git command returned with the following error: <some-url>: 404 Not Found`.**
- Check your URL ends with **.git**, or use the _copy button_ on the project's gitlab web page
**When I push my code to GitLab, I got an email saying ```Your pipeline has failed```.**
- If you pushed an unfinished code, ignore this mail.
- If you pushed a final code and your IDE doesn't show any error, then it usually means that you skip the unit and/or checkstyle tests on your computer. When using IntelliJ IDEA, check the [IntelliJ IDEA Troubleshooting page](IntelliJ-IDEA-Troubleshooting).
- Anyway, click (in your email) `build` button for more information on why the compilation has failed. Either the tests didn't pass, or the checkstyle showed some checkstyle errors.