--
To reply, visit https://hellosplat.com/s/beanbag/tickets/4948/
--
New ticket #4948 by b.stoop
For Beanbag, Inc. > RBTools
Status: New
Tags: Priority:Medium, Type:Defect
--
Error 207 when using --parent
==
# What version are you running?
RBTools 2.0.1 (Python 3.9.5)
# What steps will reproduce the problem?
1. Switch to the master branch.
2. Create a new branch from the master branch using `git switch -c test1`.
3. Make some changes to a file and commit those.
4. Create a new branch form the test1 branch using `git switch -c test2`.
5. Make some changes to a file and commit those too.
6. Push test1 or test2 to origin with the same branch name.
7. Use `git switch test2`, or make sure your current branch is test2.
8. Post to reviewboard with `rbt post --parent test1`
# What is the expected output? What do you see instead?
```
ERROR: Error validating diff
docs/manual/pipeline/README.md: The file was not found in the repository. (HTTP
400, API Error 207)
```
I get the error that the file that is changed in the `test2` branch is not
found in the repository. It doesn't matter which if `test1` or `test2` is
pushed to origin.
# What operating system are you using?
I use windows 10 as main OS. I run RBTools on a ubuntu 21.4 WSL on my windows
10.
# Attach the debug out from the command.
```
$ rbt post --debug --parent test1
>>> RBTools 2.0.1
>>> Python 3.9.5 (default, May 11 2021, 08:20:37)
[GCC 10.3.0]
>>> Running on Linux-5.10.16.3-microsoft-standard-WSL2-x86_64-with-glibc2.33
>>> Home = /home/brian
>>> Current directory = /home/brian/development/stellr
>>> Command line: rbt post --debug --parent test1
>>> Running: tf vc help
>>> Checking for a Bazaar repository...
>>> Unable to execute "brz help" or "bzr help": skipping Bazaar
>>> Checking for a ClearCase repository...
>>> Unable to execute "cleartool help": skipping ClearCase
>>> Checking for a CVS repository...
>>> Unable to execute "cvs": skipping CVS
>>> Checking for a Git repository...
>>> Running: git rev-parse --git-dir
>>> Running: git config core.bare
>>> Running: git rev-parse --show-toplevel
>>> Running: git symbolic-ref -q HEAD
>>> Running: git config --get remote.test1.url
>>> Command exited with rc 1: ['git', 'config', '--get', 'remote.test1.url']
---
>>> Repository info: Path: /home/brian/development/stellr/.git, Base path: ,
>>> Supports changesets: False
>>> Checking for a Mercurial repository...
>>> Unable to execute "hg --help": skipping Mercurial
>>> Checking for a Perforce repository...
>>> Unable to execute "p4 help": skipping Perforce
>>> Checking for a Plastic repository...
>>> Unable to execute "cm version": skipping Plastic
>>> Checking for a Subversion repository...
>>> Unable to execute "svn help": skipping SVN
>>> Checking for a Team Foundation Server repository...
>>> Unable to execute "tf help": skipping TFS
>>> Making HTTP GET request to https://reviews.m2mobi.com/api/
>>> Running: git rev-parse refs/heads/test2
>>> Running: git branch --remotes
>>> Running: git config --get branch.test1.remote
>>> Running: git rev-parse test1
>>> Running: git rev-list 12ed902642ce0cba8b2b8b9b6e24febc6cf106f2 --not
>>> --remotes=origin
>>> Running: git status --porcelain --untracked-files=no
>>> --ignore-submodules=dirty
>>> Running: git version
>>> Running: git -c core.quotepath=false -c diff.noprefix=false diff --no-color
>>> --full-index --ignore-submodules --find-renames --no-ext-diff
>>> 12ed902642ce0cba8b2b8b9b6e24febc6cf106f2..53aa20b071d71d8a065279e4563b2173d3ed7f99
>>> Making HTTP GET request to https://reviews.m2mobi.com/api/validation/diffs/
>>> Cached response for HTTP GET
>>> https://reviews.m2mobi.com/api/validation/diffs/ expired and was modified
>>> Making HTTP POST request to https://reviews.m2mobi.com/api/validation/diffs/
>>> Got API Error 207 (HTTP code 400): The file was not found in the repository.
>>> Error data: {'stat': 'fail', 'err': {'msg': 'The file was not found in the
>>> repository.', 'code': 207}, 'file': 'docs/manual/pipeline/README.md',
>>> 'revision': 'e3cc1558ef8cf88e6dc700ebc20b7f4421fc836d'}
Traceback (most recent call last):
File "/home/brian/.local/lib/python3.9/site-packages/rbtools/api/request.py",
line 812, in make_request
rsp = self._urlopen(Request(
File "/home/brian/.local/lib/python3.9/site-packages/rbtools/api/cache.py",
line 209, in make_request
return self.urlopen(request)
File "/usr/lib/python3.9/urllib/request.py", line 214, in urlopen
return opener.open(url, data, timeout)
File "/usr/lib/python3.9/urllib/request.py", line 523, in open
response = meth(req, response)
File "/home/brian/.local/lib/python3.9/site-packages/rbtools/api/request.py",