3285: Case sensitive comparison between cwd and workspace root causes issues on Windows

Marcin.*******@gmai***** (Google Code) (Is this you? Claim this profile.)
March 7, 2014
3221
I'm running RBTools 0.5.7 with Perforce and Windows 7 Professional. If a path to the workspace root contains capital drive letter (e.g. C:\p4\), post-review and rbt won't let me post a review. Instead I get the following error:

ERROR:root:The current directory does not contain a checkout from a supported source code repository.

I've identified that the problem is that a comparison between the current path (from where the rbt is called) and Perforce workspace root is case sensitive. As os.getcwd() returns lower-case drive letter, the following comparison will fail

perforce.py, PerforceClient():
        if not norm_cwd.startswith(norm_client_root):
            return None

Perhaps this should be made case insensitive for Windows.
david
#1 david
This has been fixed in git and will ship with 0.5.8