blahdeblahHi. Is there a way to do partial commits a-la "git commit -p"?  The best I've been able to find so far is to "bzr shelve" the bits I don't want, selectively keep the bits I want to commit, commit them, then unshelve, rinse, and repeat, which is a bit tedious; "bzr shelve" also doesn't allow splitting of diffs like "git add -p" does.  Any better ideas?02:57
=== abentley_ is now known as abentley
riderircanybody awake?22:05
riderircDoes anyone actually respond to bugs reported on launchpad?22:07
LeoNerdAbout 70% of the planet, most likely22:07
riderircI have a rather severe problem (bzr check crashes), and nobody's responded to a bug posted in the beginning of December 2014.22:07
mgrandilink to the bug report22:07
ubot5Launchpad bug 1399773 in Bazaar "'bzr check' crashing" [Undecided,New]22:07
riderircIt's like fsck crashing - shouldn't happen, and you're screwed when it does...  :-)22:08
mgrandiyeah, i think thats exactly the case22:08
mgrandibzr: ERROR: bzrlib.errors.NoSuchRevision: CHKInventoryRepository('file:///root/ww/.bzr/repository/') has no revision username@domain.com-20120314181329-cpt4dhp0ou1b66k222:08
riderircI need to some way to make the repo consistent (and usable) again, even if I lose certain revisions22:08
mgrandiSo its obviously missing a revision and ....therefore fails the check22:08
riderircbut I don't want to discard the entire revision history22:09
mgrandido you have any other copies of the repo?22:09
riderircunfortunately, no.22:09
mgrandiand that username is weird...username@domain.com ? lol22:09
riderircI replaced my actual email addr with that placeholder.22:09
mgrandiif you check in the /root/ww/.bzr/ folder, do you have a 'obsolete packs'?22:09
riderircI was beginning to wonder if bzr devel had just gone completely dead...22:10
riderirclet me check22:10
mgrandicanonical seems to of shifted...to other things at the moment22:10
mgrandibut bzr is more or less in a good state, software can always be improved, etcetc22:11
riderircI've been resisting switching to git, but you know, this kind of thing makes me question my choice.22:11
mgrandilol, git has this problem to22:11
riderircyeah, but honestly it's still pretty buggy...22:11
riderircfor sure, but the git dev team is pretty quick to respond22:11
mgrandiread about how KDE almost lost _all_ of their git repos cause git does 'mirrors' without checking pack files?22:11
mgrandiyeah, git does have the benefit of the entire kernel team behind it pretty much22:11
riderircthus its primary attraction, I think...22:12
riderirc /root/ww/.bzr/repository/obsolete_packs/ has 61 files in it22:12
mgrandiwell the thing is bzr is telling you whats wrong, it cant find the revision, so it doesn't know what else to do, other then magic22:12
mgrandii wonder if that revision is in there, one sec22:12
mgrandijelmer: do you know of a way to make bzr look in obsolete_packs for missing revisions to fix a repo?22:13
mgrandiI have been messing around with the bzr pack format but i dont have anything yet that can just 'insert' a revision in the right spot22:13
mgrandilet me find my script that lists the revisions at least22:13
mgrandigit loves its simplicity and the revisions are just text files haha22:14
riderircbtw I appreciate your help; I've been checking in here regularly for weeks but nobody's generally awake  :-)22:14
mgrandiyeah, they are all eurofolk22:14
fullermdYou could setup a strawman copy of the repo with the "obsolete" packs in the main location.22:14
mgrandiim not a core developer but i like bazaar so i hang out here when i can22:14
mgrandithe mailing list would probably be better too, since a lot of people get that, even if they are not on irc all the time (like me lol)22:14
riderircFWIW: here's the pack layout: http://pastebin.com/75QbcHWz22:19
riderirc.{r,s,t,c,i}ix files omitted from the obsolete listing.22:19
mgrandiwell, here is my script that i had, i modified it so it can work on * files22:25
mgranditry calling it like "python2.7 print_out_index_keys.py <REPO_FOLDER>/.bzr/repository/obsolete_packs/*.rix22:26
mgrandiand then search that file for the revision that bazaar says its missing in your bug report22:26
mgrandiwith the filled in email =P22:27
mgrandiif you find it in there then hopefully its in one of the .pack files in obsolete_packs22:28
riderircI ran it, but I'm going to have to have a quick look at the script as it crashed...22:39
riderirc  File "print_out_index_keys.py", line 56, in printOutIndexKeys22:39
riderirc    print("noderef: {}, keyelements: {}, len: {}, rowlength: {}".format(noderef_val, keyelements_val, len_val, rowlength_val))22:39
riderircValueError: zero length field name in format22:39
mgrandilol guess python2.6 doesn't like the {}22:42
mgranditry that maybe22:42
mgrandijust added indexes to make it happy22:43
riderircyeah, I actually don't use "".format() in 2.x, rather I use ""%(tuple,)  :-)22:44
mgrandiyeahh, im a python 3 guy22:45
riderircI suppose I really should change one of these days...  too many of the 2-3 changes seem pedantic rather than reality based though22:46
riderircit annoys me, so I stick with 2.x22:46
fullermdThey all seem nuts to me, so I stick with 5.x  ;p22:47
riderircanyway, I gave field numbers to each {} for format and it happily spit out data.  I'm going to check for the missing revisionu22:47
riderircif the revision is in the pack file, how the heck can it be 'missing' unless it's a bzr bug that failed to actually put it in there?22:48
riderircit's not as if someone rm'ed a discrete file.22:48
fullermdbzr doesn't look at obsolete_packs22:48
fullermdCould happen via FS corruption, as one offhand guess.  A bit flip somewhere could make it seem like a different id.22:49
fullermdI'd expect internal checks to notice that; you could just check the md5's of the pack files.22:50
mgrandiIt _should_ look in obsolete_packs22:50
riderircat any rate, the output from your script doesn't appear to include the missing rev.  (your_script > output_file ; grep 20120328004955 output_file)22:50
fullermdBut if it happened in memory, it wouldn't be found at that level.22:50
fullermd(of course, that couldn't happen, or you'd have gotten an ECC error message.  Right?)22:50
riderircthere's nothing from the year 2012 showing up at all in the output22:51
mgrandihow new is that revision22:51
riderircfuller: one would hope22:51
mgrandiso there have been commits since then? like a decent number?22:51
riderircand the issue just showed up recently22:51
riderircprobably not a gigantic number22:51
mgrandicause stuff gets put into obsolete_packs after bzr runs a 'pack', but if you commited something, and it gets lost before it repacks, then there is no 'backup' in obsolete_packs22:52
mgrandiand did you make sure to run it against *.rix ? aka the astrik22:52
mgrandinot just one .rix file22:52
riderircyes, it # grep checking.file rixcheck  | wc -l22:55
riderircit checked 11 of them22:55
mgrandiso what are the dates in the backup files? like 2014/2015?22:55
mgrandithat the output gives you22:56
riderircso what actual gets put in the obsolete packs anyway (when bzr pack is run) ?22:56
mgrandiits sort like git, when you commit stuff they get placed in different packs, and information about them (rix, six, tix, etc)22:56
mgrandiwhen you repack, it consolidates all the different ones  in 'repository', and places them all into one, and moves the old ones back into obsolete_packs22:57
riderirc38 revisions, ranging from 20130118054022 to 2014122301233322:57
mgrandisorta how git does it. git has basically a 'file' for every commit, but it can also repack them into one giant file so it doesn't have to search 8000 files to find the right thing22:57
riderirc( grep @ rixcheck  | awk -F- '{print $2}'|sort )22:57
mgrandiso im confused on how you have commits from 2013 but nothing earlier in the backup? is this imported from svn or something?22:58
mgrandidunno how that revision is just not there22:58
riderircno, it's been bzr since day 022:58
riderirchmm, let me check something22:58
blahdeblahRepeating yesterday's question: Is there a way to do partial commits a-la "git commit -p"?  The best I've been able to find so far is to "bzr shelve" the bits I don't want, selectively keep the bits I want to commit, commit them, then unshelve, rinse, and repeat, which is a bit tedious; "bzr shelve" also doesn't allow splitting of diffs like "git add -p" does.  Any better ideas?22:58
mgrandiyou can always try cding into the directory where the repo is (normally), and run 'bzr revision-history'22:58
mgrandithat prints out just revision ids, does that print out the 2012 date?22:59
mgrandiI think git shelve is the only thing, its a bit easier with the GUI version of shelve (qshelve)22:59
mgrandierr bzr shelve22:59
blahdeblahmgrandi: OK - thanks23:00
fullermdSomebody once wrote a 'record' plugin, mirroring darcs record, which allows similar things.23:00
riderirclooks like someone pivoted out the old directory...23:00
fullermd(darcs records does, I mean; I don't know for sure whether the bzr record did, but I assume so, since that's kinda the point)23:00
riderircpython print_out_index_keys.py /root/oldww/ww/.bzr/repository/obsolete_packs/*.rix > rixcheck-old23:00
fullermdI suspect it's lost in the mists of time and compatibility by now, though.23:00
mgrandiwait, so someone copied the repo to another folder?23:01
riderirclooks like they pivoted the /root/ww directory out23:01
mgrandi(and git -p is basically doing a magical shelve -> unshelve thing after commit anyway behind the scenes)23:01
riderircthat's what happens when you let monkeys in the kitchen23:01
mgrandiso does that repo work?23:01
mgrandias in bzr check doesn't complain? =P23:01
mgrandicause i can't find an easy way to insert that revision into the pack file, bzrlib is big =P23:03
riderircbzr: ERROR: No WorkingTree exists for "file:///root/oldww/ww/.bzr/checkout/".23:03
riderircso, it's rather messed up looking23:03
mgrandithink you can just run 'bzr checkout'23:04
mgrandiit has the history but no actual checkout23:04
fullermdIf you can get it working in another branch, you could just pull both into the same repository.  Or possibly use 'reconcile'.23:05
mgrandiunrelated: commit.Commit().commit()23:05
riderircbut it's not a branch, so I can't perform a checkout23:05
riderircit's evidently a repository23:05
mgrandiwell create a directory, run 'bzr branch <repo_folder>'23:06
fullermdCan't branch a repo.23:07
fullermdBut you can 'init' an empty branch in it, and then 'pull' a revid you know is in the repo into it.  Creepy, but valid.23:07
mgrandiwait so its just a repo with no branches in it?23:07
riderircyes, some bozo evidently moved out the .bzr repository directory23:08
fullermdEven betterer and creepier, you might could 'branch' the b0rked branch into that repo, and assuming it has all the revs the b0rked one is missing, it would cleanly pull in all the new ones, and leave you with a full history.23:08
riderircthe worst thing is that there are some large files that were checked in, so bzr check takes ages to run.  I'll fiddle with it a little bit.   At least I have a better idea of what's going on.23:10
riderircAre you guys on regularly?23:10
fullermdOn?  Pretty much always.  Responsive?  That varies a lot...23:10
mgrandiwait cna you not list the branches that are in a repo if it has no active branches?23:11
fullermdML might be a better option, especially with stuff like this that has a lot of state to communicate.23:11
fullermdList branches with no branches?  Stop smoking coffee grounds   ;p23:11
fullermdYou can list heads, anyway.23:11
mgrandirun 'bzr heads --all'23:12
riderircI may be back with another question about a damaged branch that 'bzr split' exploded23:12
mgrandithat lists all the heads, and then you can branch one of those right?23:12
fullermdNot sure.  You can certainly init an empty branch and pull it.  Dunno whether you can branch it from an empty.23:13
riderircthere is no bzr heads unless that's a plugin23:13
fullermdIt's in bzrtools23:13
riderircthat sounds familiar23:14
mgrandimight be a separate package, but its included in every install i've done23:14
mgrandibut yeah, you can create a folder, 'bzr init .' to init an empty branch, then 'bzr pull -r <REVISION_ID>' and it will basically recreate the branch23:15
mgrandiand you get revision_id from 'bzr heads --all', cause it wont list dead branches by default23:15
mgrandiand then once you do fix it, be sure to 'bzr branch' it to somewhere else so this doesn't happen again lol23:16
riderircbzr heads is doing something; we'll see what it spits out.23:17
riderircwell, it's too slow; I'll check on it tomorrow morning.23:26
riderircThanks again for the help...23:26
mgrandiok, good luck, post on the ML if you have more questions23:29

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