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

=== Quintasan_ is now known as Quintasan
=== yofel_ is now known as yofel
=== Vorpal_ is now known as Vorpal
=== medberry is now known as med_out
* AuroraBorealis sighs20:08
AuroraBorealisfor some reason when bazaar calls gpg it doesn't call pinentry and it just fails =(20:08
AuroraBorealisit seems that bzr explorer needs to use --no-tty20:13
AuroraBorealisfor the gpg command20:13
jelmerAuroraBorealis: please file a bug :)21:02
AuroraBorealisk21:06
AuroraBorealissubmitted. https://bugs.launchpad.net/bzr-explorer/+bug/84738821:16
ubot5Ubuntu bug 847388 in Bazaar Explorer ""gpg: cannot open `/dev/tty': No such device or address" on Ubuntu when signing commits" [Undecided,New]21:16
jelmerAuroraBorealis: thanks21:17
AuroraBorealisi just commit using the regular terminal command and it works, so i think its just a --no-tty issue21:17
AuroraBorealishowever i dont know where in the code the command gets called so i can't test it xD21:17
jelmerAuroraBorealis: it's in bzrlib/gpg.py21:18
AuroraBorealisit seems that the tty environment variable is not set in ubuntu21:27
AuroraBorealisand thats whats causing it to freak out21:27
AuroraBorealisnot sure if thats bad or not21:28
AuroraBorealisit also appears that --no-tty fixes it, but i'm unsure of how to integrate that :321:39
AuroraBorealisannnnnd i seem to of figured out a solution. but now how to i generate a patch or something :o21:48
jelmerAuroraBorealis: I'd recommend running the gpg related tests and fixing anything that breaks: ./bzr selftest --no-plugins gpg21:49
AuroraBorealisafter i make my changes?21:50
jelmerAuroraBorealis: yep22:02
AuroraBorealiskk22:03
jelmerAuroraBorealis: well, ideally you should fix the tests to expect what you want to happen and then fix bzrlib.gpg22:03
jelmerbut this works too, and makes more sense given you've already changed bzrlib.gpg.22:03
AuroraBorealiswhere are the tests located?22:03
AuroraBorealisand this is kinda hard to test as it requires bazaar explorer22:03
AuroraBorealis(as os.environ("TTY") has to not be set)22:04
jelmerAuroraBorealis: this shouldn't require bzr explorer - I just meant tests that make sure that --no-tty is specified22:04
AuroraBorealisyeah, i'm assuming these are unit tests. but the way to check that --no-tty is only specified correctly is to be using it where the environment variable for tty is not set, like in a GUI22:06
AuroraBorealisunless i'm misunderstanding something22:06
jelmerAuroraBorealis: sure, but in the unit test you can override the environment variable and see if the right parameters are specified22:11
AuroraBorealisah ok.22:11
jelmerAuroraBorealis: see bzrlib.tests.TestCase.overrideEnv22:11
AuroraBorealisi cant seem to run this bazaar branch i checked out from launchpad because it can't import "shlex_split_unicode"22:22
AuroraBorealisany idea how to fix that jelmer so i can run the tests? xD22:26
Noldorin_hi jelmer22:35
jelmerhi Noldorin_22:39
jelmerAuroraBorealis: I'm not sure - that should only be necessary on Windows I think22:39
AuroraBorealiswell the test cases are working i guess22:39
AuroraBorealisso i'm trying to figure how how i borked those :<22:39
Noldorin_jelmer, i am finding many bzr bugs these days...22:46
Noldorin_while researching this issue22:46
jelmerNoldorin_: what exactly?22:47
Noldorin_jelmer, for a start, https://bugs.launchpad.net/bugs/84612222:47
ubot5Ubuntu bug 846122 in Bazaar "bzr thinks working tree is out of date after uncommit" [Undecided,Confirmed]22:47
jelmerNoldorin_: is the history empty after that operation perhaps?22:48
Noldorin_what history?22:48
jelmerNoldorin_: what's the output of "bzr revno"22:48
Noldorin_jelmer, 4622:49
jelmerNoldorin_: that's odd - is this in a bzr-git tree?22:49
Noldorin_nope22:50
jelmerNoldorin_: bound branch?22:50
Noldorin_jelmer, maybe22:51
Noldorin_i forget22:51
AuroraBorealisis there a way to use 'print' when you are using these test cases? it seems that its not actually printing them (and causing other tests to fail)22:57
jelmerAuroraBorealis: I generally use bzrlibtrace.mutter23:03
jelmerAuroraBorealis: I generally use bzrlib.trace.mutter23:03
jelmerAuroraBorealis: that will be printed as part of the test output if a test fails23:04
AuroraBorealisalso another question23:05
AuroraBorealisbzrlib.TestCase.overrideEnv says that the environment variable will be reset after each test23:05
AuroraBorealisis a test the entire class that extends TestCase or are they the individual methods?23:06
lifelessthe method23:06
lifelessthe class is a way to group related tests and (sometimes) test helpers that are specific to that group23:07
AuroraBorealisok. so i guess i have no idea why the environment variable for 'tty' would be none23:07
AuroraBorealisas i thought it would be None if you were running like a user interface, but its none even if you invoke bzr from a command line23:12
AuroraBorealisso i have no idea how to distinguish when you should add the --no-tty switch or not23:12
AuroraBorealiswell, it appears that just adding --no-tty works, so how do i submit this as a patch to the bug report i opened?23:37

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