/srv/irclogs.ubuntu.com/2009/05/16/#bzr.txt

xiaohuihow to  change the parent branch of bzr?02:05
jelmerxiaohui: bzr pull --remember02:10
xiaohuijelmer, thank you02:12
rockstarabentley, around?02:15
rockstarjelmer, do you know much about bzr hooks?02:15
jelmerrockstar: hi02:16
jelmerrockstar: a bit02:16
rockstarjelmer, so, I've got a class that inherits from bzrlib.hooks.Hook, and it registers two hook points.  How do I fire those two hook points?02:17
jelmerrockstar: the hook points are iterables over the registered hooks02:18
jelmerso you can just do something like:02:18
jelmerfor hook in myhooks_instance['hook_name']:02:19
jelmer   hook(42)02:19
rockstarbzrlib.hooks.HookPoint has a hook method, but not an fire method.02:19
rockstarjelmer, you would think that the HookPoint would know how to fire itself.  :/02:19
jelmerrockstar: no, you have to call the individually registered entries yourself02:20
jelmeralthough I guess it would indeed make sense for HookPoint to have such a method02:20
rockstarjelmer, yea.  Something like HookPoint.fire(*args)02:22
rockstarjelmer, I'll implement create a subclass of HookPoint in Tarmac, try it out, and if it works, I'll create a patch for Bazaar.02:25
=== Kissaki is now known as Kissaki^0ff
rockstarIs there a simple way to add revisions to a branch created with BzrDir.create_branch_convenience ?07:39
BasicOSXAttempting 1.15rc1 release and I keep getting "bzr: ERROR: socket.error: (104, 'Connection reset by peer') " several network, all peered differently, even 1 network from a large hosting provider in the midwest (US). Something wrong with LP tonight?07:44
rockstarBasicOSX, on push?07:45
BasicOSXor branch or pull07:46
rockstarBasicOSX, hm, I haven't had any problems, and I've been using it steadily tonight.07:46
lifelessrockstar: what do you mean by add revisions07:51
lifelessrockstar: is this test code or real code07:51
rockstarlifeless, test code.07:51
lifelessBasicOSX: what aare you getting that from07:51
BasicOSXbzr  branch http://code.launchpad.net/~bzr/bzr/bzr.1.1507:51
BasicOSXgives that to me07:51
lifelessrockstar: and what do you mean by add revisions07:51
rockstarlifeless, basically, I want to test that two branches are merged.  I was planning on going to find the merge tests in bzrlib and see how they work.07:52
rockstarlifeless, if I create two branches with BzrDir.create_branch_convenience and try to merge them, it throws NoCommits (which makes sense)07:52
lifelessA and B are merged if len(heads(a.tip, b.tip)) == 107:52
BasicOSXlifeless:  attempting  ~/projects/bzr/bzr.1.14/bzr  branch http://code.launchpad.net/~bzr/bzr/bzr.1.15 to see if it's a problem(?) in bzr.dev (revision: 4369)07:52
lifelessrockstar: tree1 = self.make_branch_and_tree('1'); tree1.commit(''); tree2 = tree1.branch.push('2')07:53
lifelesstree1.commit('next')07:53
rockstarlifeless, yes, so I want to add some revisions b so that I can actually make a merge (but not necessarily commit)07:53
lifelesstree2.commit('next in 2')07:53
lifelesstree2.merge_from_branch(tree1)07:53
rockstarlifeless, I'm not using the bzr test suite.07:53
lifelessrockstar: oh; any reason preventing you?07:54
BasicOSXbzr: ERROR: Connection error: Couldn't resolve host 'bazaar.launchpad.net' (-2, 'Name or service not known') things keep getting stranger07:54
rockstarlifeless, um, mostly because I'm too lazy to go try it out, and I probably don't need most of it.07:54
BasicOSXI did just recently upgrade to 2.6.24-24-server on my hardy system, but that's the only change07:54
rockstarlifeless, but mostly lazy.  :)07:54
lifelessrockstar: from bzrlib.tests import TestCaseWithTransport07:55
lifelessthats all thats needed :)07:55
rockstarlifeless, I am stealing the Hook/HookPoint stuff though.07:55
rockstarWell, not stealing, but using.07:55
lifelessrockstar: to add revisions you need to do commits or pull/push from another branch07:58
lifelessrockstar: by far the easiest way is using the bzr test harness07:58
rockstarlifeless, okay, that's simple enough.07:58
lifelessBasicOSX: anything I can do, let me know08:02
lifelessBasicOSX: but I think you have some local trouble ;P08:03
BasicOSXI'd like to think so, but 4 different computers on 4 different network on 4 different ISPs?08:03
BasicOSXComcast, UUnet, Qwest, and Sprint all having problems? could be, heck google went down the other day :-)08:04
BasicOSXlifeless:  373455 when from Fix Released to Fix Committed, that normal?08:15
BasicOSXbug 373455 that is08:15
ubottuLaunchpad bug 373455 in bzr "brisbane-core doesn't support stacking but should" [High,Fix committed] https://launchpad.net/bugs/37345508:15
=== sabdfl1 is now known as sabdfl
lifelessBasicOSX: no08:30
lifelessBasicOSX: fix committed means 'it has landed in bzr.dev'08:31
Peng_But bzr uses "Fix Released" for that.08:31
lifelessoh yes, I'm explaining badly08:32
lifelesswhat I mean is, if its not ix released, its not in trunk08:32
lifelessI don't think we've finished fixing stacking08:33
lifelessI could be wrong08:33
=== BasicOSX changed the topic of #bzr to: Bazaar version control system | 1.15rc1 released 15 May, 2009 | http://bazaar-vcs.org | http://irclogs.ubuntu.com/ | http://planet.bazaar-vcs.org/
Peng_Congrats. :)08:46
BasicOSXNow the scary part.. merge back into trunk :-P08:47
=== Kissaki^0ff is now known as Kissaki
=== Spaz is now known as Fapjack
alsurenis there a way to tell bzr to ignore changes in permissions? I just copied everything to a fat32 usb stick, and it's telling me that the entire repo has been changed10:42
lifelessalsuren: the only permission bzr tracks is the executable bit10:43
lifelessalsuren: are you using bzr under windows?10:44
alsurenno, I'm on ubuntu. Problem is that I made *some* changes10:46
alsurenoh, I just read the bit on status-flags. I reckon I could hack something together with grep to work out which files I *actually* modified10:50
alsurenyeah, so parsing the output of status -S is actually really easy. Why isn't this the default?10:58
alsurenactually, I'm quite glad that it's not10:58
alsurenignore me10:58
Peng_:D11:09
alsurenokay, so actually I still need help11:09
alsuren$ bzr revert11:09
alsurenbzr: ERROR: [Errno 1] Operation not permitted11:09
alsurenthere is a bug in launchpad about it11:10
alsurenhttps://bugs.launchpad.net/bzr/+bug/19072511:10
ubottuUbuntu bug 190725 in bzr "Bzr can't init branch on ntfs-3g filesystem" [Medium,Triaged]11:10
alsuren(for reference, I used cp -R proj/.bzr /media/disk to do the copy)11:12
alsurendoes anyone know a way around this, or am I just screwed?11:14
lifelessalsuren: well the bzr metadata should be just fine11:25
lifelessalsuren: you could try branching fresh11:25
alsuren*bets he'll run out of space if he does that, but tries it anyway*11:27
alsurenno. still operation not permitted11:27
alsurenoh, ololol: it's symlink that's throwing11:31
=== Fapjack is now known as Spaz
alsurenokay, so removing the symlinks from the repo makes revert work, but I still need some way to stop bzr from trying to track the execute bit11:36
Peng_Hmm, content filters? :D11:38
alsurenPeng_: https://bugs.launchpad.net/bzr/+bug/190725/comments/8 suggests a plugin. how do I need to change it?11:40
ubottuUbuntu bug 190725 in bzr "Bzr can't init branch on ntfs-3g filesystem" [Medium,Triaged]11:40
alsuren(I'm thinking that the real solution would probably be retro-fitting permissions to FAT at the operating system layer, but we all know that's not going to happen11:42
alsurenhrrrm... I guess I could monkey-patch os.stat to clear the execute bit, but that's *really* horrible11:46
lifelesso11:47
Odd_Blokejelmer: I just hit http://dpaste.com/44691/ when trying to push to Debian SVN.11:47
lifelessso the basic problem is, fat is returning garbage data, and we assume when the platform is unix that all fs's track X reasonably well11:48
lifelesswe have code to work around no X tracking but only activate it on windows11:48
lifelessfile a bug please11:48
lifelessI suggest we add a a config setting/environment variable to force that workaround code on in this sort of situation11:48
Peng_What about explicitly checking if the fs supports it?11:49
Peng_Same way you do the CIFS checks?11:49
lifelessPeng_: what CIFS checks11:49
lifelessPeng_: do you mean the case insensitive ones?11:50
Peng_Yeah.11:50
lifelesswe need either reference data or to write11:50
lifelessits possible in principle11:50
alsurenlifeless: should I paste this conversation to the bottom of my bug report?11:50
alsurenlifeless: where is this no-X-tracking magic, and can I enable it with a plugin in the short-term?11:54
awilkinsOfftopic : Is there an ability in the SFTP protocol to just get a hash or crc of a file, not the file?11:54
awilkinsThinking about it, is tracking x-bit a security risk, and should it be done at all?11:55
alsurenawilkins: where did you get that idea from?11:58
alsurenbzr is used for pushing source code around, which is compiled and executed on the user's system. There are far more dangerous things that you can do than twiddling an X bit11:59
awilkinsalsuren: Yes, put that way it does seem less significant11:59
lifelessalsuren: its mainly in workingtree*.py12:05
lifelessawilkins: don't think so12:05
lifeless[to both SFTP and x-bit security]12:05
lifelessbzr doesn't run the users code12:05
lifelessits why we don't have in-tree plugins, for instance12:05
awilkinsFairy snuff.12:06
lifelessas long as bzr doesn't run code from a branch, there isn't a risk that is bzr's fault ;)12:06
lifelessnow,if bzr tracked owners12:06
lifelessor setuid12:06
luksbzr actually can try to run some python code :)12:06
lifelessthat would be different12:07
lifelessluks: from the users branch?12:07
luksyes12:07
lifelesshow?!12:07
luksvia imports12:07
lifelessthats the system python path12:07
lifelessoutside bzr's control; file a bug on your OS/python install :)12:07
lukssure, but it can happen :)12:07
lifelesssame as bash can run some code from there12:08
luksbut bash is expected to do so12:08
lifelessno12:08
lifelesshaving '.' in your path is widely recognised as a security law12:08
lifeless*flaw*12:08
lifelesssame goes for . in your python path12:08
luksexcept that's the default setting for python12:09
alsurenluks: well if you fancy porting bzr to python3 and using "from . import whatever" all over the place, then go for it12:10
luksI'm not saying anything except that it's possible for bzr to run user's code right now12:12
luksI know about it and I can live with it12:12
alsurenthat's actually something I'd never thought about before.12:14
luksI can't even reproduce it right now, so maybe there was something done to fix it12:16
luksI've seen a few people to have that problem on the ML in the past12:16
alsurenluks: reading the tut, that's not how it works12:18
alsuren"Actually, modules are searched in the list of directories given by the variable sys.path which is initialized from the directory containing the input script (or the current directory)"12:18
alsurenso . isn't actually in your path, only $ dirname `which bzr`12:20
lukscan't really find the posts12:22
lifelessalsuren: that doesn't protect against it :P12:23
jelmerOdd_Bloke: hi12:37
jelmerOdd_Bloke: that's the no 1 bug for bzr-svn, should be fixed before 1.1512:37
Odd_Blokejelmer: Is there any way I can work around it?13:08
jelmerOdd_Bloke: you can comment out the assertion13:12
jelmerit should generally be harmless13:12
Odd_Blokejelmer: Cool, thanks.13:20
alsurenlifeless: if . isn't in your path, then surely you're pretty safe (sorry, went to lunch)13:29
alsurenhttps://bugs.launchpad.net/bzr/+bug/37724313:35
ubottuUbuntu bug 377243 in bzr "bzr (linux) doesn't handle FAT's limitations (X-bit and symlinks) well. Should behave like on windows." [Undecided,New]13:35
alsurenlifeless: can't find the win32 hacks you speak of13:41
knielsenI have a --no-trees shared repo (bzr init --no-trees). Is there an option to `bzr branch` to override the --no-trees, eg. the opposite of `bzr branch --no-tree` ? `bzr brancj --tree` doesn't complain about the not documented --tree option, but it also doesn't create a tree?14:40
knielsen(I know I can just bzr co afterwards, so not big deal, just wondering if I missed the option)14:41
jelmerknielsen: I don't think there is anything like that atm, but I agree it makes sense14:42
knielsenok14:42
knielsenMaybe an oversight, since the --tree option is there somehow but seems to do nothing14:42
knielsenmight be a good starter project to get into the code ;-)14:43
jelmerknielsen: Yeah, this might be a trivial one to fix14:48
=== pst is now known as pst555
pst555i wonder how i could accomplish something like repo1/lib where lib being a link to repo215:20
pst555is a bzr co lib inside repo1 and then a bzr link-tree the right thing to do?15:28
rockyjelmer: care to elaborate on "dpush" ? :)17:02
jelmerrocky: what about it?17:03
rockyjust trying to understand it17:03
jelmerrocky: it just pushes into a foreign vcs (such as svn) losslessly (i.e. what can't be represented in that VCS is lost)17:06
rockyah metadata can be loss17:07
LarstiQhmmmm17:07
* LarstiQ wonders about a /dev/null foreign vcs17:07
Jessegood evening london18:33
Jessehi?18:35
=== Jesse is now known as jesse
=== jesse is now known as jesse_1
jesse_1hi18:48
lukshi18:48
jesse_1is it possible to configure bazaar to use a username for ssh to certain hosts?18:49
jesse_1i tried authenticantion.conf18:49
jesse_1but bzr still uses the $USER value18:49
luksI don't know, but on unix with openssh you can use ~/.ssh/config18:49
jesse_1aha18:50
jesse_1dumb me, i thought everything's configured in bzr18:50
jesse_1i am still confused why authentication.conf didn't work18:50
jesse_1i am using private key for sftp, but am tired of typing my username in the url18:51
jesse_1so i put a section in my auth conf18:51
jesse_1with scheme, user & host18:52
=== krisfree is now known as krisfremen
darkholeHi everybody...21:37
darkholeI need some help, about Eclipse+Bzr21:37
darkhole??21:41

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