Bug 2111 - make tests: test-schemes fails
Summary: make tests: test-schemes fails
Status: RESOLVED FIXED
Alias: None
Product: Mercurial
Classification: Unclassified
Component: Mercurial (show other bugs)
Version: unspecified
Hardware: All All
: normal bug
Assignee: Bugzilla
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-03-23 11:23 UTC by Jon Ribbens
Modified: 2012-05-13 04:56 UTC (History)
5 users (show)

See Also:
Python Version: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jon Ribbens 2010-03-23 11:23 UTC
make tests fails for me in test-schemes.

jon@snowy:/home/jon/tmp/mercurial-1.5 $ uname -a
Linux snowy 2.6.26-2-amd64 #1 SMP Thu May 28 21:28:49 UTC 2009 x86_64 GNU/Linux
jon@snowy:/home/jon/tmp/mercurial-1.5 $ python -V
Python 2.6.5

ERROR: /home/jon/tmp/mercurial-1.5/tests/test-schemes output changed
--- /home/jon/tmp/mercurial-1.5/tests/test-schemes.out 
+++ /home/jon/tmp/mercurial-1.5/tests/test-schemes.err 
@@ -1,5 +1,5 @@
 adding a
-comparing with l://
+comparing with l:
 searching for changes
 no changes found
 % check that {1} syntax works
Comment 1 Michael Glassford 2010-04-07 13:25 UTC
As pointed out by Mads Kiilerich on the the mercurial-devel mailing list, this 
is caused by Python change http://svn.python.org/view/python/branches/release26-maint/Lib/urlparse.py?
r1=66717&r2=78235 which was made to fix http://bugs.python.org/issue7904.

I'm working on a patch now.
Comment 2 Michael Glassford 2010-04-08 05:48 UTC
Patch submitted.
Comment 3 HG Bot 2010-04-30 01:00 UTC
Fixed by http://hg.intevation.org/mercurial/crew/rev/e4f911ce21de
(schemes: fix // breakage with Python 2.6.5 (issue2111))
Comment 4 Etienne Robillard 2010-05-19 18:36 UTC
Hi,

I believe the proposed patch did *not* worked well with my setup. As a result of
upgrading to mercurial 1.5.2, all urls which were generated by hgwebdir
(running as a fastcgi process) were made broken. This issue seems to appear
in 1.5.2, as Mercurial 1.5 (and possibly 1.5.1) seems immune to this issue.

Is this fixed in 1.5.3 ? If not, I'd kindly suggest for a revised patch.


Thanks,

erob
Comment 5 kiilerix 2010-05-19 18:46 UTC
erob: Please be more specific. Which urls broke in which way?
Comment 6 Etienne Robillard 2010-05-20 18:48 UTC
kirellix:

Thanks for your reply. I'll try to be more specific. ;)

I think the domain part (remote address) is simply not appearing
as it should. For example:  

hgwebdir 1.5: http://example.com/path/to/project (good)
hgwebdir 1.5.2: http://path/to/project (bad!)



nginx conf for serving hgwebdir with fastcgi:

location / {
            fastcgi_pass  127.0.0.1:8809;
            fastcgi_param PATH_INFO $fastcgi_script_name;
            fastcgi_param QUERY_STRING $query_string;
            fastcgi_param REQUEST_METHOD $request_method;
            fastcgi_param SERVER_NAME $server_name;
            fastcgi_param SERVER_PORT $server_port;
            fastcgi_param SERVER_PROTOCOL $server_protocol;
            fastcgi_param CONTENT_TYPE $content_type;
            fastcgi_param CONTENT_LENGTH $content_length;
            #include /etc/nginx/fastcgi_params;
}

Kind regards,

erob
Comment 7 kiilerix 2010-05-21 03:47 UTC
erob: 

Are you sure that that is caused by the patch here? Could you try to change
both occurrences of _urlunparse in 1.5.2 mercurial/url.py
with urlparse.urlunparse and see if that makes a difference?

It sounds to me like a different issue which might require another fix in
another release, so we would like to track separately.

The original issue discussed here has been fixed and the fix has been
released, so I will change from testing to resolved.
Comment 8 Etienne Robillard 2010-05-25 05:02 UTC
kiilerix:

did a test with your proposed changes and got no broken urls. (python 2.6.5+
and mercurial 1.5.2). 

Will now attempt to upgrade to 1.5.3 and merge your changes in.. :) 


Thanks,

erob
Comment 9 Etienne Robillard 2010-05-30 08:00 UTC
sorry please ignore my last comment. Mercurial 1.5 is the only
version not affected by this issue, it seems. 

so far, I tried the following versions without success:

- 1.5.2 (fail)
- 1.5.1 (fail)
- 1.5   (pass)
Comment 10 kiilerix 2010-05-30 14:18 UTC
erob: You lost me there. But let's try to keep it simple and start over.

The original "test-schemes fails" issue has been resolved and the fix has
been released. Please leave this issue as resolved.

Your "broken nginx / hgwebdir urls" issue seems different, and the comments
here only adds confusion. I suggest that you file a new issue here in the
tracker and include all facts and relevant information there.
Comment 11 Bugzilla 2012-05-12 09:07 UTC

--- Bug imported by bugzilla@serpentine.com 2012-05-12 09:07 EDT  ---

This bug was previously known as _bug_ 2111 at http://mercurial.selenic.com/bts/issue2111