/srv/irclogs.ubuntu.com/2014/01/15/#bzr.txt

ochosihi everyone16:37
ochosisorry if what follows sounds like a rant, but i'm also trying to solve a problem16:37
ochosia collegue pushed a new rev to trunk without pulling before, so everything newer than his local status got thrown together in a single "merge-commit" and history was rewritten16:38
ochosibasically 2 commits incl. commit-messages were lost that way16:38
ochosiso first question: how can i resolve that? can i revert those commits somehow in the remote repo?16:39
ochosi2nd question: why is it even possible for someone else to rewrite history that easily? theoretically you can destroy all commits by going to a very early revision, changing something and then pushing it (cause everything that came after will be squeezed in one merge-commit)16:39
Doomtroni'm new with bzr, but from man bzr: bzr revert [FILE...]       Reverse all changes since the last commit.16:57
Doomtronochosi:16:57
ochosidoes that also affect the remote repo?16:58
mgzochosi: so, he didn't lose or change any history, just changed how the graph appears16:58
ochosimgz: well, the commit messages are lost, and since one commit (formerly known as rev182) fixed a specific bug, it's not very nice imo16:59
mgzochosi: you can prevent accidents like this by setting a config 'append_revisions_only' on your master branhc17:00
mgzochosi: they are not lost17:00
ochosithanks, that sounds useful17:00
mgzochosi: to see, do `bzr log -n0 REMOTE` where REMOTE is your master branch17:00
ochosican i revert that stuff somehow?17:00
mgzand fixing this is easy, do17:00
mgzwell two options17:01
mgzthe non-history rewriting way is:17:01
mgz`bzr branch -r-2 REMOTE fixup_mainline; cd fixup_mainline` # get the last good mainline rev before the mistake17:02
mgz`bzr merge REMOTE; bzr commit -m "Merge so and so's changes with the mainline set correctly"; bzr push`17:02
mgzyou can also just take the last good rev, merge his base branch properly, and push --overwrite it17:03
mgzochosi: hope that helps17:03
ochosimgz: so going back to the last good commit and doing "bzr push :parent --overwrite" will do away with whatever followed?17:04
ochosi(just to be sure, i dont wanna mess things up more than they already are)17:04
mgzyes, but that's the big hammer method, and you don't really need it17:04
mgzjust flip the mainline back to the right thing17:04
mgzby getting the last mainline rev you want, and merging current tip into it and pushing17:05
ochosiyeah, i can grab the commit that's there (before the merge), commit it locally and then push all that17:06
ochosithanks a lot mgz17:06
ochosilast question, how do i quickly set the append_revision_only setting?17:06
ochosi(sorry, usually using git, so i'm a bit new to bzr...)17:07
mgzochosi: `bzr config -d REMOTE --scope=branch append_revisions_only=True` and test it by then doing `bzr uncommit REMOTE` which should complain at you17:08
ochosiwill do that, thanks a bunch for the super-fast and terrific support!17:08
ochosimgz: all sorted out, thanks again!17:14
jelmerhey mgz :)17:14
mgzjelmer! :)17:15
mgzseem zygmynt's funny plan?17:16
mgz*seen17:16
=== BasicMBP is now known as BasicOSX
zygamgz: hmm?18:33
mgzzyga: wondered is jelmer had seen your announcement, as it's one of the things we discussed with vila before xmas18:34
mgz(python 3)18:35
zygamgz: oh, what do you think about that then?18:35
zygamgz: I haven't touched bzr since weekend but I'm slowly inclined to go through 2.7 cleanup phase were I drop the level of flake8 noise before running 2to3 en-masse18:35
zyga(I had like three different attempts so far)18:36
mgzI think you worded it a little strongly initially, dropping python 2 and the whole test suite sounded silly, but there's no reason to treat this as a fork rather than bzr 3 I don't think18:36
mgzzyga: that does seem like a reasonable plan18:36
zygaI don't intend to drop the test suite, I certainly didn't meant that :)18:36
mgzright, you did clarify that :)18:36
zygaI meant that if I get to write new code I won't really go to that level of testing as bzr has now, because it's going to take even more time and I want to see if this idea can work or not faster than that18:37
zygaI do intend to keep the test suite :)18:37
zygathat would be pretty nutty to remove it18:37
zygamgz: so what were your ideas for python3?18:38
mgzjust slog through it, and don't try to maintain compat after a major release18:38
zyga2.x compat?18:38
mgzthere are old major releases for python 2 support18:39
zygayeah, I think thats reasonable, python3 was around for a long time now18:39
zygaand it's far easier to remove various fallbacks and maybe, just maybe, use newer features18:39
zygaone thing I was thinking about later was launchpad18:39
zygabut since I explicitly forked launchpad can stayon bzr forever18:39
zygaI don't even imagine how big launchpad porting effort would be18:40
rozzinzyga: sorry, what about launchpad?18:58
zygarozzin: if bzr trunk and subsequent releases moved to 3.x, dropping 2.x support, lauchpad would be locked out19:36
rozzinzyga: Ah. You meant "bzr" as opposed to "bzr3".19:36
jelmermgz: yeah, I did see the announcement!19:39
zygarozzin: yeah19:39
zygarozzin: looking at to what mgz mentioned, if bzr itself moved to python319:40
jelmermgz, zyga: I think dropping support for older formats is a good idea19:40
jelmernot really convinced of the usefulness of porting to python3 at this point19:40
zygajelmer: right, since they are obsolete and 2.6 can convert all the way to 2a19:40
zygajelmer: it's for fun really, there's is some usefulness but more for what I need19:41
jelmerzyga: ah, fair enough19:41
zygalooking at the code I think it's also reasonable to drop some transports19:42
zygabzr really needs, local, http and ssh19:42
jelmerzyga: it really depends on what your eventual goal is19:42
zygathe rest are probably dead as users anyway19:42
zygajelmer: not sure yet, I have a pipe dream of git format as native bzr format19:43
zygajelmer: immediate goal is bzrlib in python3 for my scripts / tools19:43
jelmerzyga: If you're aiming for this to be a long-term project rather than an incidental hobby project, then I have other reservations too (-:19:43
zygajelmer: shoot :)19:43
zygajelmer: you never know19:43
jelmerzyga: since moving it to a separate launchpad project (and dropping python2.x) would effectively split the already small community19:44
zygajelmer: I see what you mean, I'm not saying no, right now there is no community for bzr3 that isn't the existing bzr community, if this works out I'll rethink how to continue, now I need to find a moment to work on the code19:53
jelmerzyga: fair enough19:55
rozzinjelmer: It seems like moving to python3 may be useful as a sort of social signal, even if that's all it is: people look at bzr/python2 and think "the project isn't even being kept up to date with the current Python", which supports "bzr is a dying/dead project".20:58
LeoNerdjelmer: Ah, hi there ;) LTNS21:29
=== lfaraone_ is now known as lfaraone

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