summaryrefslogtreecommitdiff
path: root/doc/bugs/On_Windows__44___annex_get_fails_with_HTTP_Remote__44___but_believes_it_has_succeeded..mdwn
blob: 5dc127fe5b6f80e9b44c139d0252f0145cdb5114 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
### Please describe the problem.
On Windows, with a remote annex configured for HTTP access, attempting to annex get a file will not result in the content being downloaded, but will download a 404 error page as the file.

### What steps will reproduce the problem?
1. Create an annex (A1) on a Linux system.
2. "git update-server-info"
3. run an HTTP server with, a directory up. python -m SimpleHTTPServer
4. on a Windows system, clone the annex with 'git clone http://remote_host/annex_dir/.git'
5. "git annex get <file>"

the resulting file will not have the correct content, but rather a 404 error page. In addition, subsequent attempts to "git annex get <file>" will fail, unless you "git annex drop <file>" first. (it appears to believe it correctly retrieved the file).


### What version of git-annex are you using? On what operating system?
Windows 7: 4.20140627-g8a36ec5 (from the git-annex download page)

Debian Linux: 3.20120629 (from the package manager)

### Please provide any additional information below.
After some debugging, I believe the issue is related to the way git-annex uses curl. it appears that git-annex uses the return code of curl or wget to determine if a download was successful, but curl by default will return status code 0 on a 404, unless the -f option is used (which it is not).

getting git-annex on windows to use wget works around the issue.