/srv/irclogs.ubuntu.com/2011/03/09/#bzr.txt

=== Ursinha-afk is now known as Ursinha
Stavroshello01:32
Stavrosis there a way to have bzr store branches in the same directory and switch uncommitted changes too?01:33
Stavrosbasically, colocated branches but with shelving01:33
lifelessbzr switch should just do that01:34
Stavroslifeless: last i tried, switch didn't switch uncommitted changes, was that added?01:35
Stavroslifeless: nope, it doesn't01:38
lifelesswhat do you mean by switch uncommitted changes then ?01:39
lifelessfor me, it keeps uncommitted changes in the tree, so I can commit them to another branch.01:39
Stavrosoh01:39
Stavrosi mean shelve them in the branch01:39
Stavrosso i can have uncommitted changes per branch01:39
Stavrosfor example, i'm working on feature 1 but it's half done01:40
lifelessso, standard shelve is in the working tree01:40
Stavrosyes, but per-branch01:40
lifelessthe pipeline plugin adds a shelf per branch as well01:40
Stavroshmm01:40
Stavrosnothing that will automatically shelve everything on swich, though?01:40
lifelesspipeline does when working with a pipeline01:41
Stavrosis pipeline good? i found it a bit confusing01:41
lifelesssome folk love it01:41
Stavroswhat i want to do is work on feature1, switch to feature 2 even if 1 is half finished, work on 2, switch back to 1 and finish and commit 101:41
lifelessits quite polished at the use case it aims to solve (a series of feature branches tackling one large problem)01:41
Stavrosright now i have to do some complicated shelving01:41
Stavrosah01:41
Stavroshmm yes01:41
Stavrosmaybe this is what i need, then01:41
lifelessStavros: what about just committing?:01:41
Stavrosi don't like committing half-working things :/01:42
lifelesswork on feature 1, commit, switch to feature 2, work, commit, switch to feature 1, *uncommit*, keep working.01:42
Stavrosi don't trust me to remember to uncommit :/01:42
Stavrosgood solution if you're not ocd, though01:42
lifelessa shelf per branch would be a good facility for core I think, perhaps file a bug ?01:43
Stavrosi will, thanks01:43
Stavrosi'll try pipeline in the mean time01:43
Stavrosshouldn't i post a feature request rather than a bug?01:44
lifelessStavros: there is no difference01:45
Stavrosah, thanks, i'm filing one now01:46
lifelessStavros: bugs.launchpad.net/bzr01:46
vilahi all !07:47
* fullermd waves at vila through the lightning.07:49
vila:)07:49
jammorning all08:20
jamMoggûh, jelmer (though you're probably not up yet :)08:21
jammorning vila08:21
vilahey jam !08:21
jamso vila, what are you working on these days? Still poking at the package importer mostly?08:22
vilaI've been catching up with mails and reviews so far, I will focus on the p-i again now08:23
vilajam: oh, and 2.3.1 should have been released last week so I need to catch up with that too08:27
jamwell, give it a sec, since I have a patch progressing through the stack :)08:27
vilajam: did you merge your fix up to trunk for the missing inventories ?08:27
vilahehe08:27
jamI'm up to 2.308:27
jamwhich is where you get NEWS conflicts because of the split-out08:27
vilajam: I intend to work on 2.3.1 tomorrow only, I'd like to summarize all the mails about which plugins are carried by which distros first08:28
mr-russHi, I'm reading the smart http server documentation and setting up mod_python method of using http smart server.  Where do I find bzr-smart.py?08:41
mr-russrunning ubuntu 10.0408:43
vilamr-russ: which doc are you reading ? bzr-smart.py doesn't appear to be part of the bzr sources08:48
PengIt's more or less part of the docs.08:49
PengLast I checked.08:49
mr-russyeah, that was my complaint really.  http://doc.bazaar.canonical.com/bzr.dev/en/user-guide/http_smart_server.html08:49
mr-russbut there is no way to easily find the source from that page.08:49
mr-russafter 10-15 minutes googling, I think https://lists.ubuntu.com/archives/bazaar/2006q4/020376.html  has the details I need.08:49
Pengmr-russ: But the source is in that page.08:50
Pengmr-russ: Copy and paste it.08:50
mr-russthanks, excuse the dumb moment.08:50
PengIt's not ideal, of course. Maybe someone should stuff them all in contrib/ or somethuing.08:51
mr-russyeah, it would be nice to have an example as part of the bzr doc when you apt-get.08:52
mr-russI'm about to find out what I need to do to get modpywsgi installed.08:53
=== Ursinha is now known as Ursinha-afk
=== hunger_ is now known as hunger
jamvila: on the plus side, it seems this was the only patch that needs merging-up09:17
jamso you've kept the branches fairly in-sync09:17
vila:)09:18
mr-russmodpywsgi seems difficult to find, links don't work.09:20
jammr-russ: http://code.google.com/p/modwsgi/ ?09:21
vilamr-russ: :-/ patch welcome !09:21
jamif you can give updates to the docs, that would be great09:21
mr-russwhat branch would I checkout?09:21
vilafor http://doc.bazaar.canonical.com/bzr.dev/ it should be the bzr trunk itself09:22
mr-russso there is no python file, I need an apache module now?09:23
vilaand then follow the path from the url doc/en/user-guide, once there, there should be a .txt corresponding to the .html09:23
vilamr-russ: could very well be the case, that's why we generally encourage the use of bzr+ssh09:23
mr-russokay.  I was trying to keep away from having server accounts for each user.09:24
vilashudder09:25
vilayeah, that's the other missing bit...09:25
mr-russwhat does lp use under the hood?09:25
vilassh :)09:25
mr-russI understand the authentication issues I think09:25
vilamr-russ: for lp you authenticate with one of your registered ssh keys09:26
mr-russmaybe I'll switch back to ssh.  But is there a tute on restricting the ssh commands users can run?09:26
PengLP doesn't use an ordinary sshd server, though.09:26
vilamr-russ: as in restricting the ssh command to bzr ?09:26
mr-russyes.09:26
mr-russyou can only use bzr over ssh, no account login at all.09:27
vilaoh, it's in ~/.ssh/authorized_keys IIRC09:27
vilalet me check09:27
mr-russyes, with the funny commands out the front.09:27
mr-russIt's getting those commands right that is always painful.09:27
vilaindeed (searching for an example)09:27
mr-russI think I may have gone that route first if I found a clear example.09:28
mr-russI'm branching bzr now, so I'll see how I go with doc patches.09:28
mr-russI've not used bzr with launchpad before, how does patch contribution work?09:28
vilamr-russ: so, in the general case: branch; hack hack; commit; push lp:~<lpname>/<project>/<meaningful-branch-name>09:29
vilamr-russ: 'bzr lp-open' will open the pushed branch page from where you can select: 'propose for merging'09:30
mr-russcool.09:30
mr-russI'm sure it's easy when I get the hang of it.09:30
vilamr-russ: for bzr you will need to go thru http://www.canonical.com/contributors09:31
mr-russOh the joy of the legal world :)09:33
vilamr-russ: yeah, the whole process is pretty easy, there is also 'bzr lp-propose' which further simplify some steps but I don't use it myself (for... various uninteresting reasons) so I can't comment precisely there09:33
vilamr-russ: yeah :-/ There is a work in progress to satisfy more people but as often with legal it takes time09:34
mr-russhttp://thias.marmotte.net/2009/05/creating-a-restricted-bzrssh-smart-server/09:35
mr-russdoes that look right for the bzrssh server setup?09:35
spivmr-russ: looks highly plausible09:37
vilaroughly yes, I'm not sure about the options restrictions (but they shouldn't harm) and I can't find back my example locally (I could swear I used one at some point :-/)09:37
spivmr-russ: see also contrib/bzr_ssh_path_limiter in the bzr source tree09:37
vilaspiv: hey !09:37
spivHey :)09:37
mr-russI"m still waiting for my branch to finish downloading, not the greatest performance09:38
mr-russI'll see if the lucid package installed contrib.09:38
vilamr-russ: I don't think contrib is ever installed (apart from the bash completion stuff though...)09:38
mr-russthat's what I'm seeing on my server.  waiting for branch to complete.09:39
vilamr-russ: so you server is lucid, you know you can use the stable ppa to get newer releases right ?09:39
mr-russno.  As a standard kind of user, I use what's packaged by default.  That way it's 'supposed' to be support for 3-5 years.09:40
vilamr-russ: lucid provides bzr-2.1.1 while the ppa will gives you bzr-2.3.0 (and the associated plugins)09:40
mr-russI usually upgrade with all LTS releases though.09:40
vilathe stable PPA will support LTS as well09:41
mr-russbut LTS does not support the PPA :)09:41
vilathe PPA content ?  no :)09:42
vilabut *we* do :)09:42
mr-russThat is not what the average user will expect.09:42
mr-russI will consider upgrading once I actually have this working neatly.09:43
vilavia SRUs we may be able to provides 2.1.4 for lucid, but we are not there yet09:43
mr-russtoo many things that I and others are used to with SVN.09:43
vilamr-russ: and what clients are you using ?09:43
mr-russlucid.09:44
mr-russall lucid at the moment.09:44
mr-russcommand line bzr mostly.09:44
mr-russI'm hoping to convince my work to switch from svn to bzr in the next year.  But that will require evaluation of windows tools, particularly with regard eclipse and a setup for ssh for users, possibly against AD.09:45
vilaright, so, indeed, if you start using the PPA you'd better deploy it everywhere too, no urgency09:45
vilaAD ?09:45
vilaactive dir09:45
mr-russSo I have a lot of learning todo before I can encourage them towards that stance.09:45
vilasry09:45
mr-russActive Directory. ldap windows.09:45
vilaright, so we don't support 2.1 on windows, only the most recent stable release (2.3)09:46
vilathis shouldn't be a problem09:46
vilabut if you'll get better performance with 2.309:46
vilas/if//09:46
vilamr-russ: no pressure, just presenting the options09:47
mr-russokay, that will go with we use RedHat as a server and I'm sure it has and older version of bzr.09:47
mr-russah the joy of learning new stuff.09:48
vilahehe09:48
vilaright, I've heard rumors about some bzr packaging on rh but I've never been able to get a contact there, pointers welcome !09:48
mr-russWell, I've backed back to using bzr+ssh, much easier.  No tricks with folder permissions when new branches are created?09:49
vilamr-russ: no, as  long as you use a single user on the server09:49
mr-russWe only have a regular education support contract and an account manager, so I'm not sure I can help you a lot with RH contacts.09:49
vilaerr09:49
vilaas long as the same user owns the branch and is used to ssh connect, no permissions tricks are needed09:50
mr-russI've created a bzr group.  added relevant users to it, and set all permissions to group rw(x).09:50
vilamr-russ: no worries, but if you find some bzr packages for rh or centos or fedora, whatever, I'd be happy to hear about it09:51
mr-russnow when anybody pushes a new branch, will group stuff get set correctly, or do I need to set some sticky bits or something like that?09:51
mr-russvila: If I find anything or progress down that path, I'll report back.09:51
vilamr-russ: right, but the ssh server filters the group permissions bits IIRC which is the source of all the problems09:51
vilamr-russ: thx09:51
vilamr-russ: so the ssh setup is generally easier when a single user is created on the server and collect all authorized user keys09:52
fullermdOr use a real OS with simpler FS semantics   8-}09:52
mr-russoh.09:52
vilafullermd: you mean... Windows ?09:53
fullermdYou'll still need to correct on pushing new branches.  The perms in the repo for new data are preserved, but new branches just run off umask.09:53
mr-russso user a single user account on server with shared ssh key, lock down to relevant command only and all the commit names are managed by bzr itself?09:53
mr-russand bzr won't mess with permissions/ you can't set a different umask for that folder?09:54
* mr-russ feels so out of his depth09:54
vilamr-russ: the commits always occur on local hosts and as long as you can push to a server, you can push your own commits or anybody else's09:54
vilamr-russ: think of it as a user with different roles, each role is associated to a key09:55
vilamr-russ: you give keys to users that can push to the server09:55
vilamr-russ: and you define a single user on the server for this role09:55
mr-russssh account developer has (x) ssh keys that can run bzr.09:56
vilaon the server, yes09:56
mr-russAll developers on remote boxes  use;  bzr push bzr+ssh://user@my-bzr-server/path/to/bzr/branch/09:57
mr-russwhere user is the common user.  Their ssh key is of course already setup properly.09:57
vilawith an appropriate ~/.ssh/config you can even use bzr push bzr+ssh://my-bzr-server/path/to/bzr/branch/09:57
mr-russI just wish I could short circuit the /path/to/bzr/branch to /branch.09:58
mr-russI think I need to write a tutorial for this kind of setup.09:58
vilabzr+ssh://my-bzr-server/~/project/branch/09:58
vila'~' will expand to the ssh user home directory on the server09:59
mr-russthe URL I sent before fixes taht.09:59
mr-russas the command forces the folder for you.09:59
mr-russhttp://thias.marmotte.net/2009/05/creating-a-restricted-bzrssh-smart-server/09:59
vilamr-russ: http://paste.ubuntu.com/577750/ is an excerpt of my ~/.ssh/config09:59
mr-russI think I have found a winning configuration.  Thanks all for your help.10:00
vilamr-russ: good !10:00
mr-russand after 3 years of trying to really understand dvcs and how to set it up, I think I'm finally over the line.  I'm sure I'll find some merging issues and fun ahead.  But we are much further down the load.10:01
mr-russs/load/road/10:01
mr-russSo if I created a tutorial on a central bzr setup as we have discussed, should it go in bzr/doc/en/tutorial?10:02
vilamr-russ: sounds like it, that would be awesome !10:03
catphishis it possible to create a shared / default branch.conf?10:04
vilamr-russ: may be check in admin-guide too10:04
vilacatphish: what's your use case ?10:04
catphisheg. repo.conf or just plain bzr.conf10:04
vilacatphish: there is a work in progress to allow that10:05
catphishwell i am setting up some hooks, and i want them to run on all branches in a particular  repository10:05
mr-russvila: can I send the contributor form to you, or to Mr Pool?10:05
vilacatphish: see configurations.txt in lp:~bzr-core/bzr/devnotes for an almost up-to-date description10:05
vilamr-russ: poolie10:06
vilamr-russ: err, yeah, Martin Pool10:06
mr-russyes, I know poolie is Martin Pool :)10:06
catphishthanks vila, bazaar.conf will probably do, i was really hoping to do it per-repo10:06
vilacatphish: me too :)10:07
vilacatphish: but out of curiosity (and to help ensure your use case is addressed in the future), can you tell me what kind of feature you're implementing with these hooks ?10:07
catphishvila: i run a repository hosting service, and i am using the post_change_branch_tip hook to update a log when people push10:09
catphishnow, i could use a single hook globally, however in every other SCM, hooks are defined per-repository10:10
catphishi can't define it per-branch easily because users can dynamically create branches within their repository10:10
catphishmy hook currently reads the name of a shell script from the [hooks] configuration parameter and executes it10:11
mr-russvila: I've sent the agreement, so that mean magic happens and my contributions will be considered for merging?10:12
catphishso ideally, for compatibility with the way other SCM's work, I would like to be able to define the [hooks] configuration per repository10:12
vilamr-russ: yup, poolie should process it and from there we will land your contributions after reviewing them10:13
mr-russthanks.10:13
mr-russvila: what's the ppa address?10:16
vilahttps://launchpad.net/~bzr/+archive/ppa10:22
vilathe various ppas are described at https://launchpad.net/bzr10:23
mr-russand it's stable, even though it's labelled for developers?10:23
mr-russokay, reading that page says it's stable releases.10:25
vilamr-russ: oh, it's labeled for 'Bazaar Developers' because they are the maintainers not the targeted users10:26
catphishi am having problems with locking12:35
catphishbzr: ERROR: No such file: '/data/repos2/b5/70ff4d-c20f-d082-210b-d51b37b6bb92/default/.bzr/branch/lock/held'12:35
catphisha directory that quite clearly does exist12:36
jelmerhi catphish12:40
catphishhi12:40
jelmercatphish: when do you get that error, what are you trying to do?12:40
catphishjelmer: http://paste.codebasehq.com/pastes/xpt7u0ga715212:43
jelmercatphish: is it perhaps a path that exists remotely?12:43
catphishit DOES exist remotely, see the ls12:44
jelmercatphish: sorry, I missed that that was on the remote host12:48
jelmercatphish: This is probably a bug in the smart server, can you file a bug report?12:49
catphishideally i'd like to be able to confirm whether it's a bug in my http server first12:49
jelmercatphish: It could be, but I think a bug in the bzr smart server is a lot more likely12:50
catphishjelmer: the error certainly implies an error in the smart server12:51
catphishthe file it is complaining about clearly exists12:51
jelmerjam: Goeiesmorgens!12:51
catphishwhere do i report it?12:51
jamjelmer: when you sleep in, boy do you sleep in :)12:51
jelmerjam: :)12:52
jelmercatphish: it might be that the path is being sent across the wire and the bzr client tries to access it locally12:52
catphishgood point12:53
catphishi'm using a sucky old client12:53
catphishwill try upgrading first12:53
jelmerjam: I'm having fun with the CommitBuilder.. do you know what fast deltas are, and why they are a reason for avoiding record_iter_changes() ?12:53
jamjelmer: dirstate can compute deltas quickly, and 2a can store deltas quickly12:54
jamso rather than build the whole inventory12:54
jamand save it12:54
jamwe build a delta and apply it12:54
jamit was slower in pre-2a12:54
jamand didn't handle merge commits for a while12:54
jamI think that has been fixed12:54
jambut I'm not positive12:55
jelmerah, thanks12:55
jamI'm pretty sure record_iter_changes is the recommended path right now12:56
jelmerjam: at the moment we seem to use record_entry_contents() if the repository format supports nested trees, the commit has excludes or if the format doesn't support fast deltas /and/ there is more than one parent12:57
jelmerThe last condition is the one you mentioned, I assume?12:58
catphishjelmer: i think i found my problem by looking closer at the protocol log12:58
jamI'm not sure what is ANDed and what is ORed in that statement12:58
jambut sure12:58
jamI trust that you're looking at it more closely than I12:59
jamwe don't support it with nested trees, because it isn't well defined12:59
jamso no work was actually done on it12:59
jelmerfilter_iter_changes() does actually handle kind == 'tree-reference' though, strangely enough12:59
jamjelmer: that doesn't mean that all the other bits of the stack do13:00
catphishjelmer: the smart protocol was being sent this by my http server: ["rename", "default/.bzr/branch/lock/held", ".bzr/branch/lock/broken.8y5qi3f3qq5hft5r28km.tmp"]13:00
jelmerjam: right13:00
catphishthe branch name wasn't appended to the second parameter, the error it returns is misleading13:01
jelmerjam: anyway, it seems like the only thing that really matters for me is the exclude parameter, the others can't be triggered for foreign formats.13:01
jamjelmer: well, if you want to implement --exclude handling for record_iter_changes, I'd be ok with that13:02
jelmercatphish: Ah, I see13:02
jamI think there was some discussion about how it should be done13:02
jamthat it should be passed into iter_changse13:02
jamrather than filtered on top, etc.13:02
catphishi guess my code that injects branch names needs to be a little more intelligent13:03
jelmercatphish: you're running a custom http server?13:03
catphishjelmer: yes13:03
catphishit just accepts http requests and passes them on to bzr serve --inet13:05
catphishunfortunately because my url structure contains a repo and a branch, it is necessary to inject the branch name into commands13:06
catphishright now i just have (ruby code): command[1] = branch + '/' + command[1] if branch13:06
catphishassuming the second parameter is always a path13:06
catphishunfortunately the smart protocol isn't all that well documented, so i'm not sure which commands have more than one path as parameters13:09
catphishthough i'd appreciate it if anyone who knows could tell me :)13:09
* jelmer isn't all that familiar with the smart protocol either, unfortunately13:10
catphishi can just address them as i find them13:10
catphishlooks like my original problem is fixed anyway :)13:42
ChrisCauserHi guys, have I come to the right place for bzr-svn help?13:50
catphishprobably13:50
ChrisCausercatphish Thanks13:51
catphishby the way, is this room affiliated with canonical and launchpad directly?13:51
ChrisCauserBasically, I'm getting weird things with bzr 2.4 dev and was wondering if anyone had seen it before?13:51
ChrisCauser$ bzr commit13:51
ChrisCauserCommitting to: svn+https://SVN_REPO13:51
ChrisCausermodified FILES13:51
ChrisCauserbzr: ERROR: Layout CustomLayout([PATH_FROM_SVN_ROOT],[]) does not support custom branch paths.13:51
ChrisCauserArgh, stupid formatting13:52
vilacatphish: not per se, but many people haunt the same channels13:52
ChrisCauserBasically, If I checkout a svn repo, I get the error above13:52
ChrisCauserIf I unbind it and push to it, there is no error13:52
ChrisCauserDoes anyone know what I'm doing wrong? The svn layout is indeed a little strange13:52
catphishi wasn't really sure how closely bazaar was tied to canonical and to launchpad13:53
catphishbut it's not really important13:54
jelmerChrisCauser: PATH_FROM_SVN_ROOT is not the path you have checked out?13:57
ChrisCauserjelmer: Apologies that wasn't clear.  the svn root is at SVN_ROOT. I checkout SVN_ROOT/masterfiles/production and PATH_FROM_SVN_ROOT comes up as ['masterfiles/production']13:58
jelmerChrisCauser: but "bzr commit" says "Committing to SVN_ROOT" ?13:59
ChrisCauserjelmer: No. It says "Committing to SVN_ROOT/PATH_FROM_SVN_ROOT"14:00
jelmerChrisCauser: hmm, that's odd. Do you perhaps have push_merged_revisions enabled? Does the branch have tags?14:02
ChrisCauserjelmer: It's a pretty bog standard bazaar install. The checkout is fresh so has no tags. Interestingly, I have a second svn repo that I'm committing to just fine which has a standard trunk/branches/tags layout14:04
jelmerChrisCauser: Can you try that commit again with BZR_PDB=1 set and pastebin a backtrace?14:05
vilacatphish: bzr is a GNU project for which Canonical is the copyright holder14:08
ChrisCauserjelmer: Thanks for that. It has entered the debugger but the lines prior to that are at http://pastebin.com/3fX6dTQP14:08
catphishthat's fine then, it was primarily the integration with launchpad that concerned me, seemed that a bit of a commercial injection14:09
vilacatphish: look harder :) 1) launchpad is free software, 2) the integration is done via a single plugin (bundled with bzr core though)14:10
catphishvila: that's cool, it hadn't occurred to me that LP was free / multihomed :)14:10
catphishi won't concern myself then14:11
vilacatphish: see https://launchpad.net/launchpad, licence: GNU Affero GPL v314:12
catphishi did :)14:12
catphishthanks14:12
vilahehe14:12
catphishhow do i read global config? right now i am using TreeConfig to read branch config but it doesn't fall back to the user or system config14:14
catphishJust Config?14:16
jelmercatphish: bzrlib.config.GlobalConfig14:20
jelmerChrisCauser: can you run "bt" in the python debugger and pastebin the output?14:21
ChrisCauserjelmer: http://pastebin.com/Ak7e0m2N14:22
catphishjelmer: sorry to be dumb but how do actually use the GlobalConfig class to read a config option?14:24
jelmercatphish: GlobalConfig().get_user_option('bar') IIRC14:24
jelmerChrisCauser: hmm, that's odd. It's trying to push a non-mainline revision for some reason. What does "bzr missing SVN_URL" report?14:24
catphishjelmer: works like a charm, thanks14:26
ChrisCauserjelmer: I appear to get back the entire history of the repo. There is an svn revno right up to the point I see my first [merge]. Could this be a clue? I have two branches which I merge via bzr locally and push to svn separately. Any merges I have done purely in svn don't seem to have revno: number [merge] written on them.14:32
jelmerChrisCauser: yes, that's probably related. Was the branch you're working in currently based on the remote svn repo?14:35
jelmerChrisCauser: Is there a difference in any way between the local and the remote commits reported by "bzr missing"14:35
jelmer?14:35
ChrisCauserjelmer: So basically I had two branches, development and production. I branched both of them and merged back and forth and pushed to the svn repo.14:41
ChrisCauserjelmer: On the same machine, but in a completely new bzr repo, I have checked out the production branch and it seems to have checked out the branch but the missing command reports that the 200 commits I have made on svn are not commited locally yet I have 200 identical commits locally.14:43
ChrisCauserjelmer: There are no local commits as yet. This is a fresh checkout that I haven't changed.14:44
catphishjelmer: it appears that the problem with my http server isn't as simple as i thought, the bzr client is (sometimes) sending duplicate identical HTTP requests at once14:46
catphishso it sends 2 lock requests, the first succeeds and the second one of course fails14:46
catphishi'm sure there's a reason, just can't see what it is :(14:47
jelmercatphish: is there any reason for using a custom http server rather than e.g. just apache with wsgi?14:48
catphishyes14:48
vilacatphish: highly suspicious, there shouldn't be multiple lock requests coming from a bzr client14:49
vilaany gentoo packager around ?14:49
jelmerChrisCauser: can you spot any differences in the revisions present locally and remotely?14:49
catphishi'll get a full packet dump and see if i'm doing something to upset it14:49
vilahttp://packages.gentoo.org/category/dev-vcs?full_cat seem to imply (I'm a gentoo noob) that 2.3.0 is not available (hardmask). What's the rationale ?14:50
jelmervila: They filed some bugs earlier about several plugins not having a compatible release with 2.3 out yet14:51
vilajelmer: ho ! thanks. Now that you mention it...14:51
ChrisCauserjelmer: I've just realized, when you say SVN_URL, is that the path to the SVN_ROOT or does it include the path? If it includes the path then bzr is reporting that the branch is up to date.14:52
jelmerah, hmm.. time for my afternoon tea!14:52
* jelmer runs off14:52
jelmerChrisCauser: including the path14:52
jelmerChrisCauser: even in the original branch?14:53
ChrisCauserjelmer: Hope you have a nice tea! I'm afraid there is no original bazaar branch as I suffered data loss.14:53
jelmerChrisCauser: I was just teasing vila since he was going to ask me about doing a bzr-svn release...14:54
vilajelmer: haha14:54
ChrisCauserjelmer: Ooops. Sorry14:54
vilajelmer: I haven't made the connection yet, but I plan to freeze 2.3.1 tomorrow, be ready ;-D14:54
jelmerChrisCauser: I mean, the original branch in which you tried to run "bzr commit"14:54
ChrisCauserjelmer: Oh, there is now only one bzr branch checked out at the moment, the "production branch." I originally had on my last computer two branches "production" and "development" (both in svn) which have now gone and these were the ones that I merged back and forth14:58
jelmerChrisCauser: Hmm, ok14:58
=== andreas__ is now known as ahasenack
jelmerI wonder why it's trying to commit to a non-mainline branch then14:58
jelmerthe change you're trying to commit, what sort of change is it?14:59
ChrisCauserjelmer: I've just tried to check out the development branch and that is causing another error on checkout: http://pastebin.com/XrQmAQet (hopefully nothing too incriminating here ;) )14:59
jelmerChrisCauser: but it still did the checkout I presume (those are just warnings)?15:00
ChrisCauserjelmer: Yes, it still did the checkout15:00
jelmerChrisCauser: the change you're trying to commit, what sort of change is it?15:01
ChrisCauserjelmer: It happens on modifying, adding and removing15:02
jelmerChrisCauser: any merges involved?15:02
ChrisCauserNo15:02
jelmerah, I see what's happening15:06
jelmerChrisCauser: this is a regression caused by bzr 2.415:06
jelmerChrisCauser: please file a bug15:07
ChrisCauserjelmer: Brilliant :) Will do.15:07
ChrisCauserjelmer: Is there any information that will help describe the situation?15:07
jelmerChrisCauser: bzr-svn doesn't implement Branch.import_last_revision_info_and_tags(), which was added recently15:08
jelmerhmm, Branch.import_last_revision_info_and_tags doesn't make sense15:10
jelmerChrisCauser: can you try trunk?15:12
ChrisCauserof bzr-svn or bzr?15:12
jelmerChrisCauser: bzr-svn15:12
ChrisCauserjelmer: :-$ I'm having a bit of difficulty here. I got a "AttributeError: 'SvnBranch' object has no attribute 'source'" when I commited to the same checkout and when I checkout a new branch and commit I get an invalid http code (401)15:18
ChrisCauserjelmer: Did I not supply enough flags to the setup script?15:19
jelmerChrisCauser: I've committed a fix, please try again15:35
=== Ursinha-afk is now known as Ursinha
catphishdoes anyone know if bzr with http has problems with keepalive? i'm pretty sure it tries to send requests down connections that have already been closed15:57
vilacatphish: it's been a very long time since we had reports about problems with keep-alive16:06
vilacatphish: you can use -Dhttp on your bzr client commands to get a debug output of all requests16:07
vilacatphish: the output should go to ~/.bzr.log IIRC16:07
catphishyeah, i tried that, the duplicates i'm seeing don't appear there16:07
catphishbut i see them in a packet dump16:07
catphishso i'm a little confused at the moment16:07
vilaweird16:07
vilado you have some proxy may be ?16:07
catphishwill post some info if it persists16:08
catphishi do have a proxy, which was my first suspicion, but the duplicate requests are visible at the client too16:08
vilacatphish: if -Dhttp doesn't output the faulty request, bzr is out of the equation16:08
vilaerr16:08
vilawhat do you mean by 'visible at the client' ?16:09
catphishi mean, wireshark on my client shows 2 http requests to lock a repo16:09
catphishone at the end of a kept-alive http session16:09
catphishand another at the start of a new http connection16:09
catphishhowever i will confirm that and get some logs and evidence together to make sure i'm not being stupid16:10
catphishi have no doubt it's the result of one of my proxies, but i need to establish exactly why16:10
catphishvila: actually the duplicate http requests do show up in the http log16:16
vilacatphish: ha ! now we've got something :)16:17
catphishbut the response doesn't appear16:17
catphishhttp://paste.codebasehq.com/pastes/sxze691xetsn16:17
vilacatphish: can you pastebin the relevant part making sure you remmo... you're too fast :)16:17
catphishi didn't remove my auth details16:18
vilacatphish: argh, change your password, the Auth header is only lightly protected16:18
catphishi know that all too well16:18
vilaok16:18
catphishbrb16:18
* vila should really obfuscate these headers...16:19
catphishseems wise16:20
vilacatphish: can you paste a bit more ?16:20
catphishsure16:20
fullermdBah.  Silly diff algorithm, picking the wrong bit of code to leave in place.16:20
vilafullermd: ha, one of those cases, painful heh ?16:21
catphishhttp://paste.codebasehq.com/pastes/64m6nvijy78816:21
fullermdThe "oh crap, why and how did I delete that important code?!" sudden-panic is particularly fun.16:22
vila:)16:22
catphishpasswords changed, dunce cap applied16:23
vila:)16:23
vilaerr, didn't I just say that ?16:23
vilacatphish: so, the first thing that catch my eye is that the keep-alive is reset far too early (at 92 !)16:24
catphishvila: what's odd is that the request is sent, the reply is received (at least to the packet sniffer on my pc), but bzr misses the reply and opens a new connection to send the request again16:26
vilaha crap, the pieces I'm searching for are logged only when _debuglevel is set16:26
vilacatphish: can you edit bzrlib/transport/http/_urllib2_wrappers.py for a test /16:26
vila?16:26
catphishsure16:27
catphishbut you'll need to guide me in the right direction since i'm not a python developer16:28
vilathere is a DEBUG variable at the top the file set to 0, setting it to 3 will give us more data16:28
vilano worries, you just have to change 0 to 3 :)16:28
vilahmm, is upgrading to bzr-2.3.0 an option too ?16:28
catphishwow16:29
catphishthat's a lot of info16:29
vilaI don't remember related fixes since 2.1.1 but it's quite old so I may be wrong16:29
vilacatphish: I don't remember the details, but 3 should output a lot about proxies but only once whereas 2 will output for requests but not significantly more than -Dhttp16:30
ChrisCauserjelmer: Thank you so much. That did the trick wonderfully. I can now checkout and commit to an svn repository.16:32
vilacatphish: concretely, I suspect some transient error trigering a resent of the same request16:33
catphishi have a full log now16:33
catphishjust going to clean the passwords and paste it16:33
vilacatphish: in your case, it could be that the request went through to the server but we still get what looks like a transient error16:33
catphishReceived exception: [BadStatusLine('0\r\n',)]16:34
vilaurgh, the infamous :(16:34
catphishyou know it well?16:34
vilacatphish: more or less, it generally means a bug somewhere else :-/16:35
vilacatphish: the status line is something like 'HTTP/1.1 200 OK' , if we got a bad one... it could mean we didn't consume the socket content properly16:36
catphishi wonder if it's bad handling of the chunked encoding16:37
catphishsince all responses end with 0\r\n16:39
catphishit may have still had 0\r\n in the buffer from the previous request16:39
catphishand read it as the start of the next response16:39
vilacatphish: that would trigger with the second request then16:40
catphishvila: http://paste.codebasehq.com/pastes/eaoht6hslbts16:41
catphishthere's the log snipper16:41
catphish*snippet16:41
vilawhere is that 'reply:' coming from ?16:44
catphishhttp://paste.codebasehq.com/pastes/49osq8c9otx716:46
catphishthat's the data on the tcp socket16:46
catphishonly the bottom is relevent (the lock_write) request16:47
catphishbut the response appears the same as the others, nothing unusual16:48
vilacatphish: I mean, did you type that or is it coming from bzr ?16:48
catphishfrom bzr16:48
vilagrep 'reply:' returns no matches16:49
catphishwhat are you grepping?16:50
vilathe bzr sources for 2.1.116:50
catphishyou're right, but i can see it clearly on my screen16:50
vilaho ! probably from httplib itself16:51
catphish'send:' doesn't appear either16:51
vilahmm, what python version are you using ?16:51
vilaconfirmed, from httplib when debuglevel is set (via DEBUG)16:52
catphishPython 2.6.5 (r265:79063, Apr 16 2010, 13:09:56)16:52
vilahmmm16:54
vila0\r\n is an empty chunk no ?16:54
catphishcorrect16:54
catphishmore than that, it's the end of the response16:54
vilaone possible cause would be that the server issues an empty chunk wrongly (as in bzr doesn't expect it), but we've never encountered such servers...16:55
catphishempty chunks are necessary as far as i know16:55
catphishthey mark then end of the chunked response16:55
catphishhttp://en.wikipedia.org/wiki/Chunked_transfer_encoding#Encoded_response16:55
catphishThe response ends with a zero-length last chunk: "0\r\n" and the final "\r\n".16:56
vilasure, but what if the sever is sending two of them instead of one16:56
=== beuno is now known as beuno-lunch
vilacatphish: just throwing ideas there16:56
catphishit's not on this occasion16:56
vilacatphish: ok16:57
catphishi sent the raw tcp dump16:57
vilawhere ?16:57
catphishhttp://paste.codebasehq.com/pastes/49osq8c9otx716:58
catphishthat's just one tcp connection16:58
vilawow, I missed that16:58
catphishspecifically the one that is terminated prematurely16:58
catphishyou see it send the successful response at the end16:58
catphishthe one that is never received by bzr16:58
vilaindeed, so you got that from the server side ?17:00
catphishno17:00
catphishpacket sniffer on the client17:00
vilaO_o17:00
catphishit's 100% what the http library is seeing17:00
vilawaitaminute17:02
catphish:)17:02
catphishi'd love to hear that my server is doing something dumb17:02
vilathe status lines appears at the end of the lines in a weird form17:02
vilahmm17:02
vilamay be just some formatting wart of the packet sniffer but...17:03
catphishthe response status lines are just on the same line as the end of the request17:03
catphishbecause technically there is no \n between them17:03
vilawell, they don't travel in the same part of the socket either17:03
catphishunfortunately i had no way to colour in the data in each direction17:03
vilayup17:03
catphishyou have to assume where they client and server packets start and end17:04
catphish"....d16:Software version5:2.1.1es...!l25:Branch.get_stacked_on_url1:.ee" << end of request17:04
catphishstart of response >> "HTTP/1.1 200 OK"17:04
vilacatphish: so from the send:/reply: in the full trace you should be able to match that no ?17:05
vilaha, well, no17:05
vilahttplib will only tell you that it read the headers but nothing about the body17:06
vilaso, try setting DEBUG to 917:06
catphisheek ok17:06
viladon't worry, only 1 2 3 9 are used17:06
vila9 will output a bunch of crap once at the beginning and then the bodies (well, some bodies IIRC :-/)17:07
catphishok17:07
catphishi'll try it17:07
vilamore precisely the bodies that the higher levels didn't consume...17:08
vila... damn, that's silly, we are indeed searching for a case where bzr fail to consume such bory remains :(17:08
catphishi don't think that made any difference to the log17:10
vilacatphish: did you see any 'Consumed body:' ?17:11
catphishno17:11
vilaI'm a bit lost :-/17:12
vilacatphish: looking at the modifications in _urllib2_wrappers *after* 2.1.1, I don't see clearly connected modifications but some may apply...17:12
vilacatphish: what os are you using on the client and the server ?17:13
catphishubuntu 10.0417:13
catphish32 and 64 respectively17:13
catphishthe server is actually an apache2 proxy and a backend server17:13
vilashudder... nothing weird there17:14
vilacatphish: anyway, there is a PPA you can use to upgrade both: https://launchpad.net/~bzr/+archive/ppa17:15
catphishit's a complicated arrangement, which is why i'm focusing this discussion on what the client sees17:15
vilacatphish: sure, and you're doing well, it's just that remote debugging is.... hard :-/17:15
catphishthe server is running 2.3.0 from easy_install17:15
vilacatphish: and the extensions get compiled with easy_install ?17:16
catphishi honestly don't know17:16
vilanot that this should make a difference...17:16
catphishi haven't needed any17:16
vilacatphish: oh yes you need them :)17:16
catphishwhy?17:16
vilacatphish: otherwise we use the python fallback implementation and the performance suffers17:17
catphishah17:17
vilacatphish: the ppa is the next best thing after the official Ubuntu releases17:18
vilacatphish: you just need to do 'sudo add-apt-repository ppa:bzr/ppa' and you'll get the repository added17:20
catphishnot sure what best to do17:22
catphishinterestingly if i disable keepalive at the server side, the client receives the connection: closed header and sends another request anyway17:22
catphishmaybe i'll just try the ppa and tell customers to do the same17:23
catphishi'm also trying to get my post_change_branch_tip hook on the server running when i push over http17:25
catphishbut hopefully that won't be a problem17:25
=== deryck is now known as deryck[lunch]
vilacatphish: right, without keepalive, the things are far simpler, no need to babysit the socket content (but that's not enough evidence to confirm a bug in the bzr client side there :-/)17:26
vilacatphish: https is not involved here right ?17:27
catphishno, i pulled that ages ago because it was totally broken with my version17:28
catphishthe same problem exists with the 2.3.0 ppa version17:28
vilainstalled on both client and server ? (just checking)17:29
catphishno, the server is running the 2.3.0 from easy_install17:29
vilahmm, shouldn't be relevant17:29
catphishbut that's almost entirely irrelevant since the http stuff is done in ruby17:29
catphishand in apache17:29
catphishwell definitely a server problem17:34
vilacatphish: ? why ?17:34
catphishbecause i can't be the only person using the smart protocol over http17:35
vilaoh no, you aren't17:35
catphishand since i'm using the lastest version, something must be different about my server17:35
catphishnot a bug necessarily17:35
catphishbut something about my server that bzr or the http library doesn't like17:35
vilacatphish: try pinging spiv, he's in AU times and should arrive later, I'm about to EOD myself17:36
catphishwhere are you?17:36
vilacatphish: what is the most troubling for me is that your tcp dump looks fine17:36
vilacatphish: france17:37
catphishah ok17:37
catphishdefinitely home time then :)17:37
catphishi thought my tcp dump looked fine, and i don't do any of the keepalive or chunked encoding myself so i trust that it's correct17:37
vilacatphish: spiv should be able to validate this stream better than me17:37
vilacatphish: you mean your server do something between the bzr server and the client ?17:38
catphishin my case the 'bzr server' is just "bzr serve --inet"17:39
catphishand there's a ruby server sitting in front of it, with an apache proxy17:39
catphishone day i'll explain why that is17:40
vilabut in this case you're just relaying the bytes right ?17:40
catphishcorrect17:40
lifelessuhm17:40
lifelessso bzr+http:// uses a different encapsulation to bzr://17:40
catphishthe only thing i interfere with is the request, prepending the branch name to any paths17:40
jamvila: it is very funny to still see you online at 7pm my time. but I realize, you never were very good at stopping by 5/6 :)17:41
vilajam: :)17:41
catphishvila: i will try getting rid of the chunked encoding17:41
catphishthere's no need for it17:41
lifelesscatphish: you probably need to get a wsgi service up and forward to that, not to bzr serve --inet17:42
catphishlifeless: i hope i don't need to do that17:42
catphishsince my implementation works well, apart from these randomly dropped http sessions17:42
jamlifeless: I believe he wants to use a ruby server17:42
lifelessjam: sure, you can do that17:42
vilacatphish: worth a try, we don't it need it AFAIR but I think it's handled by httplib so we shouldn't care either... but may be not17:42
lifelessjam: I'm just trying to remember the exact framing changes for bzr over http17:43
catphishi think the problem is in httplib personally17:43
catphishchunked should never be necessary17:43
catphishvila: thanks very much for taking so long to help debug and tracing it to the 0\r\n17:44
vilacatphish: always happy to help (TM by jam ;)17:44
catphishvila: setting a content-length prevented my http server from using chunked encoding17:45
catphishand... it works17:45
catphishnow just to get the hook working and i have a fully working service :)17:46
vilacatphish: huh, how stupid ! I didn't check the Content-Length !17:46
catphishcontent-length is not required for chunked encoding, they're mutually exclusive17:46
catphishbut apparantly one works and the other doesn't :)17:46
catphishso that'll do17:47
catphishi prefer sending content-length anyway, much simpler approach17:47
vilacatphish: indeed, I used chunked encoding so long ago I forgot it *is* targeted at unknown length contents :-D17:50
catphishanyway i must get home17:50
catphishthanks again :)17:51
=== zura is now known as Guest79794
guesthello, I have a question on hooks and was wandering if someone could have time to help ...17:56
lifelessask away17:56
guesttogether with source files I have a compiled file versioned as well, so need to not forget to compile before commiting17:57
guestso was thinking, can it be done in a hook (pre_commit etc) or I'll have to do it outside in a batch running compiler first then bzr commit?17:57
lifelessguest: you are storing the compiled versions in bzr?18:00
guestyes18:00
lifelessif you run 'bzr help hooks | less' and look for 'start_commit18:00
lifeless'18:00
lifelessthat hook runs before bzr starts calculating the commit18:00
lifelessso it can change things however you like18:01
guestaha, I was just reading that, figured pre_commit is not good since it already has deltas, so start_ commit is the way to go. great, thanks a lot :)18:02
=== beuno-lunch is now known as beuno
=== deryck[lunch] is now known as deryck
briandealwishi jelmer.  I saw yesterday that you might try to add an env var to specify remote branch names in bzr-git?18:31
Stavroshello18:59
Stavroscan someone explain the pipeline plugin to me? it looks like it does exactly what i want, but i don't get all the pumping18:59
beunoStavros, have you seen: http://www.youtube.com/watch?v=HujoyGSq8n419:02
Stavrosi haven't, i'll watch that now, thanks19:02
Stavroshmm, that video mentions the same things as the docs19:17
Stavrosbasically what i want is colocated branches with uncommitted changes being stored in the branch19:17
Stavroswhich is exactly what pipes do19:17
Stavrosbut with colocated branches i can merge into trunk whenever i finish a feature in a branch19:18
Stavroswhereas pipes always go from top to bottom19:18
Stavroswhich is what i don't understand, what sort of workflow needs things to go from top to bottom?19:18
shakaranHi, I have a bzr repository, but I want merge a commit from a svn repository. It is possible? I try with bzr-svn merge -c 419 svn_url_repo, but it don't work19:27
shakaranI am doing a:19:38
shakaransvn diff -r 419 snv_url_repo19:38
shakaranFor get the diff, but this is tricky, someone with better solution?19:38
jelmerre22:14
jelmerbriandealwis: hi22:14
briandealwishi jelmer22:14
jelmerbriandealwis: It's a gross hack so I won't add it to bzr-git itself, but I'm looking at providing a patch that does that22:14
briandealwisthat's cool, jelmer.  I hurt my brain trying to figure out git's push command line.  Gross hacks are preferrable.22:15
briandealwisI currently use Eclipse's EGit to do pushes :)22:16
* jelmer wished there were some more people to help with eclipse-bzr :-/22:16
mr-russeclipse has a git plugin?22:16
mr-russI wish that too.22:16
mr-russI'd like to make use of eclipse-bzr.  But my python and java skills don't exist.22:17
briandealwismr-russ: yeah.  They're moving to git.22:17
briandealwismr-russ: There are two Eclipse projects: JGit, equivalent to Dulwich, and EGit, providing Eclipse tooling22:17
mr-russOh, that's going to hurt.  Good eclipse support makes the game different.22:18
briandealwismr-russ: the good news is that the EGit tooling reflects Git.  My thoughts were that if bzr-git can push to branches, then BzrEclipse may be a happy medium.22:19
briandealwisGerrit looks pretty nice too.22:20
lifelessbriandealwis: which 'they' are moving to git?22:20
jelmereclipse itself I think?22:21
briandealwislifeless: There's a concerted effort to move all Eclipse projects to Git.22:21
lifelessbriandealwis: oh, interesting.22:21
briandealwisAlmost all projects are currently either still CVS or Subversion22:21
wolfpackHey, Can bzr push the code on launchpad with http protocol? I am working behind http proxy and cannot make ssh connection.22:32
spivwolfpack: no, Launchpad doesn't run the bzr service over http22:33
wolfpackspiv: but branching is allowed! So is there any options to work on the projects?22:34
wolfpackany other option *22:34
spivhttps://bugs.launchpad.net/launchpad/+bug/16508722:34
ubot5Ubuntu bug 165087 in Launchpad itself "Launchpad should offer a bzr+http smart server" [Low,Triaged]22:34
spivwolfpack: you can sometimes convince http proxies to carry SSH traffic22:36
wolfpackspiv: How?22:36
spivIf you're using Ubuntu, try installing the 'corkscrew' package and using that22:36
spivIt can help to have an SSH server of your own somewhere listening on port 443 (i.e. the HTTPS port)22:38
spivOtherwise, I don't know that there's much you can do.22:38
wolfpackAre you referring to this "http://omappedia.org/wiki/Using_bzr_and_launchpad_behind_a_proxy "22:39
spivwolfpack: I hadn't seen that link before, but those instructions look reasonable22:40
wolfpackspiv: Well, I tried that but that does not works :(22:41
spivYour proxy is probably restricts access to ports other than 80 and 443 then :(22:42
wolfpackthanks for helping .23:08

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!