Merge lp:~mbp/bzr/initialize into lp:bzr
Proposed by
Martin Pool
Status: | Merged |
---|---|
Approved by: | John A Meinel |
Approved revision: | no longer in the source branch. |
Merged at revision: | 5749 |
Proposed branch: | lp:~mbp/bzr/initialize |
Merge into: | lp:bzr |
Diff against target: |
113 lines (+35/-8) 4 files modified
bzrlib/__init__.py (+11/-3) bzrlib/library_state.py (+10/-2) doc/developers/integration.txt (+8/-3) doc/en/release-notes/bzr-2.4.txt (+6/-0) |
To merge this branch: | bzr merge lp:~mbp/bzr/initialize |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
John A Meinel | Approve | ||
Martin Pool | Pending | ||
Review via email: mp+55674@code.launchpad.net |
Commit message
bzrlib.initialize() now actually initializes, as well as returning a context manager
Description of the change
It's just too perverse that
import bzrlib
bzrlib.
doesn't actually initialize things. This keeps it returning a context manager,
but it's effectively started by default.
To post a comment you must log in.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 3/31/2011 6:31 AM, Martin Pool wrote: /bugs.launchpad .net/bzr/ +bug/507710 /code.launchpad .net/~mbp/ bzr/initialize/ +merge/ 55674
> Martin Pool has proposed merging lp:~mbp/bzr/initialize into lp:bzr.
>
> Requested reviews:
> Martin Pool (mbp)
> Related bugs:
> Bug #507710 in Bazaar: "want bzrlib.initialize() to do all typical setup"
> https:/
>
> For more details, see:
> https:/
>
> It's just too perverse that
>
> import bzrlib
> bzrlib.initialize()
>
> doesn't actually initialize things. This keeps it returning a context manager,
> but it's effectively started by default.
I like the idea, but I don't really see that we have to not use things
the way they are documented. In my test scripts, I certainly do:
bzrlib. initialize( ).__enter_ _()
So this does make things easier there.
I'm not sure that it is perverse to ask people to use the api the way it r_context( )'.
was designed. I suppose it is called 'initialize()' and not
'get_initialize
Anyway, if you feel it is worthwhile, that's good enough to overcome my
ambivalence.
merge: approve
John enigmail. mozdev. org/
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://
iEYEARECAAYFAk2 UNxEACgkQJdeBCY SNAAMb7QCfSTWWC zijmHp3x6r1y6CM C5xj 69yfkvbyNkFZ5fH tJ
jyAAnircUUtEkXg
=Gjdl
-----END PGP SIGNATURE-----