9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: John Floren <slawmaster@gmail.com>
To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net>
Subject: Re: [9fans] Plan 9 hg with private repositories
Date: Fri, 21 May 2010 08:33:08 -0400	[thread overview]
Message-ID: <AANLkTikjR3Lozvcw-vNrMoHxI5n7WAcZMIo9xiFvBRH1@mail.gmail.com> (raw)
In-Reply-To: <AANLkTiljMgjhP3FMR2pzaxFmwfwH1NCuLAa7aAihrDSq@mail.gmail.com>

On Fri, May 21, 2010 at 1:08 AM, ron minnich <rminnich@gmail.com> wrote:
> On Tue, Aug 11, 2009 at 4:37 PM, John Floren <slawmaster@gmail.com> wrote:
>> Hi
>>
>> So I'm trying to clone a private repository I just created on
>> bitbucket. This is what I see:
>>
>> jerq% hg clone https://<username>@bitbucket.org/<username>/<repo>/
>> destination directory: <repo>
>> http authorization required
>> realm: Bitbucket.org HTTP
>> user: <username>
>> abort: could not import module msvcrt!
>
> I just hit this problem again with a clean install of the mercurial
> and python from sources (and my package tool .. but I don't think it's
> the problem).
>
> ratrace helped.
>
> 115 hg Open 0x228045 0fffc1d7/"/sys/lib/python/getpass.py" 00000000 =
> 7 "" 0x11afa42962dc41a0 0x11afa42962dfdf68
> 115 hg Fstat 0x229874 00000007 00742ed4 00000071 = 66 ""
> 0x11afa429635fb9e0 0x11afa429636b75c8
> 115 hg Open 0x228045 0fffbd73/"/sys/lib/python/getpass.pyc" 00000000 =
> 8 "" 0x11afa42963e38040 0x11afa42963f16ea8
> 115 hg Pread 0x22b14c 8
> 00fcbb48/".......Kc............@...s....d..Z..d..d..k..Z..d..d..g..Z..d..d"
> 4096 -0x1 = 3320 "" 0x11afa429648f9ad8 0x11afa429649bf6e8
> 115 hg Fstat 0x229874 00000008 00742ed4 00000071 = 67 ""
> 0x11afa429651731c8 0x11afa429651977d0
> 115 hg Pread 0x22b14c 8 00fcbb48/"" 4096 -0x1 = 0 ""
> 0x11afa429659a2538 0x11afa429659c6370
> 115 hg Close 0x22aa13 8 = 0 "" 0x11afa429666099e8 0x11afa42966623be0
> 115 hg Brk 0x22acd6 011e7600 00394918 0022826c = 0 ""
> 0x11afa42967031790 0x11afa42967037550
> 115 hg Open 0x2288bc 00262904/"#c/pid" 00000000 = 8 ""
> 0x11afa42967899928 0x11afa429678a8770
> 115 hg Pread 0x22b14c 8 0fffb4b9/"........115." 15 -0x1 = 12 ""
> 0x11afa42968056c60 0x11afa4296805e960
> 115 hg Close 0x2288f3 8 = 0 "" 0x11afa42968827818 0x11afa4296882be68
> 115 hg Stat 0x229730 0fffac7b 00742ed4/"��;" 00000073 = -1
> "'/bin/termios' file does not exist" 0x11afa42968dfe610
> 0x11afa42968ef6ab8
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa42969625c80
> 0x11afa4296962d980
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa42969debc58
> 0x11afa42969df3d40
> 115 hg Open 0x228045 0fffac7b/"/bin/termios.py" 00000000 = -1
> "'/bin/termios.py' file does not exist" 0x11afa4296a5ba100
> 0x11afa4296a6c2390
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa4296ae0d2a8
> 0x11afa4296ae15390
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa4296b5d3a50
> 0x11afa4296b5dbb38
> 115 hg Open 0x228045 0fffac7b/"/bin/termios.pyc" 00000000 = -1
> "'/bin/termios.pyc' file does not exist" 0x11afa4296bda55a8
> 0x11afa4296bea0160
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa4296c3352e8
> 0x11afa4296c340a80
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa4296cb1a6c0
> 0x11afa4296cb25688
> 115 hg Stat 0x229730 0fffac7b 00742ed4/"��;" 00000073 = -1
> "'/sys/lib/python/termios' does not exist" 0x11afa4296d3a4368
> 0x11afa4296d3d5490
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa4296de091a0
> 0x11afa4296de11288
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa4296e5c2e28
> 0x11afa4296e5caf10
> 115 hg Open 0x228045 0fffac7b/"/sys/lib/python/termios.py" 00000000 =
> -1 "'/sys/lib/python/termios.py' does not exist" 0x11afa4296ed872a8
> 0x11afa4296ee4f9b0
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa4296f708458
> 0x11afa4296f710928
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa4296ff17428
> 0x11afa4296ff1f510
> 115 hg Open 0x228045 0fffac7b/"/sys/lib/python/termios.pyc" 00000000 =
> -1 "'/sys/lib/python/termios.pyc' does not exist" 0x11afa429706e1e38
> 0x11afa4297070a2c0
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa42970f163b0
> 0x11afa42970f22ed0
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa429716e57f8
> 0x11afa429716f07c0
> 115 hg Stat 0x229730 0fffac7b 00742ed4/"��;" 00000073 = -1
> "'/sys/lib/python/lib/python2.5/site-packages/termios' does not exist"
> 0x11afa42971ed6750 0x11afa429721c04e8
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa429729d4aa8
> 0x11afa429729dcb90
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa429732579f0
> 0x11afa4297325f6f0
> 115 hg Open 0x228045
> 0fffac7b/"/sys/lib/python/lib/python2.5/site-packages/termios.py"
> 00000000 = -1 "'/sys/lib/python/lib/python2.5/site-packages/termios.py'
> does not exist" 0x11afa42973a3a2d0 0x11afa42973d53638
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa429742a3fc0
> 0x11afa429742afb40
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa42974a75b18
> 0x11afa42974a80ec8
> 115 hg Open 0x228045
> 0fffac7b/"/sys/lib/python/lib/python2.5/site-packages/termios.pyc"
> 00000000 = -1 "'/sys/lib/python/lib/python2.5/site-packages/termios.pyc'
> does not exist" 0x11afa4297523f588 0x11afa42975328800
> 115 hg Errstr 0x22bd6f 0x36b19c/"" 128 = 0 "" 0x11afa42975cd2608
> 0x11afa42975cda6f0
> 115 hg Errstr 0x22bdc4 0x36b19c/"" 128 = 0 "" 0x11afa4297648b6d8
> 0x11afa429764933d8
> 115 hg Open 0x2288bc 00262904/"#c/pid" 00000000 = 8 ""
> 0x11afa42976a50b90 0x11afa42976a63858
> 115 hg Pread 0x22b14c 8 0fffb4c1/"........115." 15 -0x1 = 12 ""
> 0x11afa42977216780 0x11afa429772207a8
> 115 hg Close 0x2288f3 8 = 0 "" 0x11afa429779d4670 0x11afa429779dafe8
> 115 hg Close 0x22aa13 7 = 0 "" 0x11afa42978cdcf60 0x11afa42978d8fac0
> 115 hg Open 0x2288bc 00262904/"#c/pid" 00000000 = 7 ""
> 0x11afa4297929f920 0x11afa429792abc70
> 115 hg Pread 0x22b14c 7 0fffca1d/"........115." 15 -0x1 = 12 ""
> 0x11afa42979a1dc88 0x11afa42979a25988
> 115 hg Close 0x2288f3 7 = 0 "" 0x11afa4297a1e9638 0x11afa4297a1ee840
> 115 hg Open 0x2288bc 00262904/"#c/pid" 00000000 = 7 ""
> 0x11afa4297aa01690 0x11afa4297aa12be8
> 115 hg Pread 0x22b14c 7 0fffc855/"........115." 15 -0x1 = 12 ""
> 0x11afa4297b823160 0x11afa4297b82aa78
> 115 hg Close 0x2288f3 7 = 0 "" 0x11afa4297bfb64b8 0x11afa4297bfbab08
> 115 hg Open 0x2288bc 00262904/"#c/pid" 00000000 = 7 ""
> 0x11afa4297c55c188 0x11afa4297c56ea68
> 115 hg Pread 0x22b14c 7 0fffc85d/"........115." 15 -0x1 = 12 ""
> 0x11afa4297cd292a8 0x11afa4297cd33e88
> 115 hg Close 0x2288f3 7 = 0 "" 0x11afa4297d4c3b30 0x11afa4297d4c75c8
> 115 hg Open 0x2288bc 00262904/"#c/pid" 00000000 = 7 ""
> 0x11afa4297dbbecf0 0x11afa4297dbcb040
> 115 hg Pread 0x22b14c 7 0fffccbd/"........115." 15 -0x1 = 12 ""
> 0x11afa4297e3700c0 0x11afa4297e377dc0
> 115 hg Close 0x2288f3 7 = 0 "" 0x11afa4297eb698d0 0x11afa4297eb6d750
> 115 hg Stat 0x229730 0fffc47f 00742ed4/"��;" 00000073 = -1
> "'/bin/msvcrt' file does not exist" 0x11afa4297f181da8
> 0x11afa4297f4f1010
>
>
> Ow, that hurt, did it not?
>
> Basically, it found getpass, did not find termios, then went looking
> for some MS VC runtime. Yuck.
>
> The code (getpass.py):
> # Bind the name getpass to the appropriate function
> try:
>    import termios
>    # it's possible there is an incompatible termios from the
>    # McMillan Installer, make sure we have a UNIX-compatible termios
>    termios.tcgetattr, termios.tcsetattr
> except (ImportError, AttributeError):
>    try:
>        import msvcrt
>    except ImportError:
>        try:
>            from EasyDialogs import AskPassword
>        except ImportError:
>            getpass = default_getpass
>        else:
>            getpass = AskPassword
>    else:
>        getpass = win_getpass
> else:
>    getpass = unix_getpass
>
> Wow, that hurt too.
>
> So, it's trying to get a password, as it is an https import, so it
> pulls in getpass, which pulls in termios, and it's failing, and the
> only reasonable thing to do when you can't find a unix package is to
> try to use an MS VC runtime package and, when that fails, bail out
> with one of the worst error messages one can imagine.
>
> Wow, GRRoss.
>
> Anyway, that is why you get that utterly useless error message:
> because you're not unix. It just tells you that the error is that you
> are not windows. Clear?
>
> ron
>
>

I think you should be able to replace getpass.py with
http://plan9.bell-labs.com/sources/contrib/john/getpass.py; I added
plan9_getpass last summer and it seemed to work.

John
-- 
"With MPI, familiarity breeds contempt. Contempt and nausea. Contempt,
nausea, and fear. Contempt, nausea, fear, and .." -- Ron Minnich



      parent reply	other threads:[~2010-05-21 12:33 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-11 16:37 John Floren
2009-08-11 17:52 ` Russ Cox
2009-08-11 18:03   ` John Floren
2009-08-11 18:21   ` Jeff Sickel
2009-08-11 21:13     ` John Floren
2009-08-13  9:13   ` Bela Valek
2009-08-13  9:47     ` Ethan Grammatikidis
2009-08-13 14:53       ` David Leimbach
2009-08-13 15:13         ` Devon H. O'Dell
2009-08-13 15:31           ` Russ Cox
2009-08-13 17:45           ` Daniel Lyons
2009-08-13 18:00             ` erik quanstrom
2009-08-13 10:11     ` Adrian Tritschler
2009-08-15 12:38       ` Steve Simon
2009-08-11 18:19 ` John Floren
2010-05-21  5:08 ` ron minnich
2010-05-21  5:15   ` erik quanstrom
2010-05-21  6:10   ` Federico G. Benavento
2010-05-21 14:31     ` ron minnich
2010-05-21 12:33   ` John Floren [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=AANLkTikjR3Lozvcw-vNrMoHxI5n7WAcZMIo9xiFvBRH1@mail.gmail.com \
    --to=slawmaster@gmail.com \
    --cc=9fans@9fans.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).