[12:13] sabdfl: Hm...I know we spent a while discussing this, so it might seem like a crazy idea, but I almost wonder if it's cheaper (less time, less cost) to simply forget about merging assignments into one table, leave them as is, and do bare SQL to speed up the bug listing when needed. That's really the one and only problematic screen by having them in two separate tables. [12:13] there is another big advantage to the consolidation [12:13] we can potentially allow people to refer directly to the id of the BugAssignment table [12:13] upload package foo1.1.1-1 fixes assignment#3134532 [12:13] sabdfl: we can do that now [12:13] no we can't [12:13] we'd just combine bug id + ass id [12:13] yuck [12:13] 1-12 [12:13] 1-13 [12:13] no? [12:13] 3536563-345365633632 [12:13] ? [12:13] heh [12:13] will the second number refer to a packageassignment or productassignment? [12:13] what if the numbers don't match? [12:13] sabdfl: er, yeah, hmph [12:13] i.e. [12:14] ok [12:14] ok, i'll keep paring down this pg_dump output [12:14] so there is the idea of the "bug number" and the "work number" [12:14] yeah [12:14] it's not ideal, because people *will* get confused between them [12:14] "but i closed bug #23234234" [12:14] "no you didn't you closed the *assignment* #..." [12:15] but malone has that extra layer, not much we can do about it [12:15] *potentially* we could make the assignment #'s much more visible, so that they are the only numbers people think of [12:15] yeah. but once we have the cross-distro patching, they'll love us. [12:15] yeah [12:15] a number then correclates to a specific piece of work for a specific bug [12:16] and if you really want to refer to a bug, you can give it a name and use that [12:17] i have a working patch for products-without-projects [12:17] daf: good work on the page-template-title test idea [12:17] sabdfl: thanks! [12:17] good thnking: spot the systemic problem, add a verbose check for it, initially in bleat mode [12:18] thank YOU! [12:18] :) [12:21] carlos: i'm seeing the POExportTestCase failure here === mdz [~mdz@69-167-148-207.vnnyca.adelphia.net] has joined #launchpad [12:51] sabdfl: as I said, ./test_on_merge.py canonical pass [12:51] there should be something wrong with make check === spiv [~andrew@adsl-66-203.swiftdsl.com.au] has joined #launchpad [01:10] Merge to rocketfuel@canonical.com/launchpad--devel--0: add SQL patch to merge *BugAssignment tables into one BugAssignment table (patch-924) [01:10] g'night === elmo_away is now known as elmo === stub [~stub@dsl-246.248.240.220.dsl.comindico.com.au] has joined #launchpad [01:48] spiv: ping [01:48] spiv: here is better [01:48] :-D === daf workraves [01:55] carlos: pong [01:55] spiv: we are having problems with initzopeless and cached values [01:55] we have a daemon script that runs outside launchpad [01:56] that process a queue of po files to import [01:56] and when we add new files from launchpad to the queue, the daemon does not see them anymore [01:56] /s/anymore/ever/ [01:56] SteveA suggested to use: sqlos.connection.connCache.clear() [01:56] after the commit [01:57] but it does not changes anything [01:57] our importer calls calls initZopeless when it's instantiated [01:57] and commits transactions as it goes [01:57] carlos: correct? [01:57] daf: yes [01:58] and the problem is fixed if it calls initZopeless for each transaction [01:58] but of course, that's not really a good solution (we don't think) [01:58] daf: No, I don't think so either :) [01:58] am I right in thinking that initZopeless returns something called a transaction manager? [01:59] carlos: That specification of how to reproduce sounds remarkably close to something that could be turned into a test case... ;) [01:59] daf: I think so, and we use it for the commits [01:59] daf: Yep. [01:59] spiv: excuse me? [02:00] carlos: What if you do a rollback immediately after a commit? [02:00] carlos: spiv wants you to write a test case for him :) [02:00] (As a dodgy way to try resync the connection to the database) [02:00] spiv: the connection is working [02:00] spiv: the postgres log shows new transactions [02:01] the start and end with the commit [02:01] and I get data instead of an error [02:01] are these transactions subtransactions? [02:01] Oh, I misread the description. [02:01] daf: don't think so [02:01] ok [02:01] daf: all them have a start and an end [02:01] before the other starts [02:02] sure I could write a test case [02:02] spiv: where should It be stored? [02:02] carlos: The test case? [02:02] yes [02:03] If it depends on rosetta bits, initially I'd put it in rosetta, and aim to reduce it to something more minimal and move it to canonical.database later (when we know exactly what's going on). [02:03] (And obviously give it a comment saying so) [02:03] ok === carlos opens a bug report [02:04] spiv: any suggestion to fix it? :-D [02:04] in theory, the same problem will happen with any table, not just Rosetta-specific ones [02:05] One thing I don't understand is that the Postgres log shows some queries [02:05] so it's not caching everything [02:07] weird [02:07] some queries, but not all? [02:09] carlos: Not yet. :/ === kiko_bz is now known as kiko [02:10] carlos: I think you are seeing transaction isolation in action. [02:10] Ok, there's two possibilities: [02:10] 1. sqlobject is caching objects [02:10] 2. the transaction is isolated, as stub just said. [02:10] carlos: If you close and reopen your connecction, you should see the changes launchpad has made. [02:10] I've been assuming 2 was likely, so I think we've been talking a cross-purposes slightly. [02:11] carlos: If you want to avoid this (there is no real overhead doing it, as psycopg caches connections I believe), you can explicitly set the isolation level. [02:11] Don't know if it's related... [02:11] 2004-12-02 01:45:23 [19630] LOG: statement: BEGIN; SET TRANSACTION ISOLATION LEVEL SERIALIZABLE [02:12] carlos: just to confirm, you've seen launchpad commit its transaction? [02:12] spiv: yes [02:12] carlos: hmm, that looks suspicious to me :) [02:12] That is psycopg starting the transaction and setting the default isolation level, so it won't see any changes made to postgres until it is committed or rolledback [02:12] and launchpad sees the changes from the script without restarting [02:13] stub: that's ok [02:13] but it does not sees the changes after the commit [02:13] stub: oh, so it shouldn't be causing this problem, then [02:13] So, hypothesis: [02:14] statement: END [02:14] it will if I open a psycopg connection, I won't see database changes until *my connection* has been committed or rolled back. [02:14] Actually, hmm. [02:14] stub: I know transactions are committed/rolled back -- I didn't know that connections are [02:15] connections get implicit transactions, as per the DB-API [02:16] oh, I see [02:16] but we cache connections, don't we? [02:16] (The implcit transaction is probably done when you execute the first bit of SQL on it, or when you create a curor. It isn't defined) [02:17] so if you reuse an old connection, it might be in the middle of an old transaction that is hiding new data === spiv hates the implicit-transactions aspect of DB-API [02:17] daf: psycopg caches connections, but handles this stuff for you so you don't have to worry. If you have higher level caches, you end up with trouble (which is why we nuke the SQLOS connection cache every request) === spiv sometimes even finds himself wishing he could use MS's ADODB API! [02:18] spiv: gosh -- it's that bad? :) [02:19] from the logs, seems like all queries are executed into postgres, so it should get fresh data... [02:19] spiv: nobody has ever successfully provided a rational as to why it is bad to the DB-SIG, and it won't change unless somebody bothers to. I know I have no problem with it and think it is fine. [02:20] stub: No-one has ever explained to me why it's good, either ;) [02:21] spiv: Because requiring con.begin_transaction() would be a dead chicken [02:21] implicitly-created transactions are convenient [02:21] spiv: And not all database backends support the notion [02:21] Unless you didn't want to run the statement in a transaction... [02:22] spiv: Which is strongly discouraged by everyone except MySQL users [02:23] Heh. At the time I was an MS SQL Server user :P [02:23] (Well.. actually it causes me some grief since I sometimes run wierd postgresql commands like 'create database' that can't be executed inside a transaction....) [02:23] New Malone bug #113: "Write a test case for the cache problem with initzopeless", submitted by Carlos Perell Marn [02:23] https://dogfood.ubuntu.com/malone/bugs/113 [02:25] Kiko: we were in the middle of a conversation when my ADSL dropped out. [02:25] stub, oh. I thought you reckoned it wasn't a pleasant and just pulled the plug! [02:25] kiko: You were bitchi^h^h^h^h^h^hdiscussing plpythonu usage [02:25] I assume too much, it appears. [02:26] well. [02:26] here's the issue [02:26] daf: malone does not likes you, the person search does not see you... [02:26] is the plpythonu cr^hode going as far as requiring zope and launchpad? [02:26] if so, I need to budget some hours for server work [02:27] stub: so, do you think that creating a new connection with initZopeLess is a good solution? [02:27] No. Anything I import will be dead simple, only requiring stuff like re [02:27] stub, it would be nice if you could skip True/False for the time being, then. or give us a workaround [02:28] I know that sounds horrible. [02:28] carlos: Sure. Connections are cheap for us. [02:28] spiv: test case filed in malone, will do it tomorrow [02:28] ok [02:28] daf: do you agree? [02:28] carlos: Thank you :) [02:28] could I commit that change? [02:28] but level with me -- I run a debian woody server. we have only one server with disks. 15ish people use it every day. I don't want to break people's work. [02:28] carlos: agree? what? [02:28] kiko: No problem. I assume you need python2.1 compatibility for any plpythonu code until further notice? [02:28] right. [02:29] daf: to use your workaround calling initZopeLess with every transaction [02:29] I can upgrade the server, but it's an effort that if avoided makes everybody happy [02:29] if you can do that, stub, well, I'm adding to that eternal debt i'm running with you [02:30] now [02:30] stub, there's yet *another* matter [02:30] it is now impossible to initialize a postgresql server remotely [02:31] it used to be possible using PG_HOST or -h [02:31] but now because you require some sql-fu for the fulltext indexing, I believe, it's no worky [02:31] carlos: It is because the system searches on 'words', and daf's name is dafydd in the database. We would need customize our stemmer to make the full text stuff match 'dafydd' if you query for 'daf'. [02:31] but it worked some days ago [02:31] but who would want to do that?! [02:32] and dafydd is not working [02:32] in the popup window [02:32] kiko: ok. That was me being lazy - I had assumed developers were running with their databases on localhost. [02:32] the form accepts it directly [02:32] but the search popup fails to search "daf" or "dafydd" [02:32] stub, I realize; we have an "office" setup here, which is ironically unusual here ;) [02:32] carlos: oh - the form also does a substring search on person.name, so that should work... [02:33] Kiko: I used to work in an office where we developed on our laptops with not a server in sight ;) [02:33] that's not real work! [02:33] you need a coffee machine and a server room [02:34] kiko: We had the coffee machine, and lack of server let us justify kick arse laptops :-) [02:34] carlos: oh, sure [02:34] daf: thanks ;-) [02:35] stub, I really appreciate any help you can provide to make my life easier. [02:35] maintaining this whole crapola is a serious effort! [02:40] good night [02:40] Malone bug #77 fixed for product The Rosetta Translation Portal: Implement a potemplate form handler [02:40] https://dogfood.ubuntu.com/malone/bugs/77 [02:49] Merge to rocketfuel@canonical.com/launchpad--devel--0: Fixed the cache problem with the import daemon as daf and stub suggested (patch-925) [02:53] time to run off [02:54] Merge to rocketfuel@canonical.com/launchpad--devel--0: Python 2.1 compatibility in plpythonu for Team Brazil's antique system (patch-926) === spiv [~andrew@adsl-66-203.swiftdsl.com.au] has joined #launchpad === ChanServ [ChanServ@services.] has joined #launchpad === warthylog [~warthylog@port49.ds1-van.adsl.cybercity.dk] has joined #launchpad === Topic for #launchpad: lunchpad: home of the sandwich artists | fogo na bomba | "qorking along happily, with SteveA egging us on" === Topic (#launchpad): set by sabdfl at Tue Oct 19 11:05:38 2004 === lifeless_ is now known as lifeless === ddaa [~ddaa@host217-37-231-28.in-addr.btopenworld.com] has joined #launchpad [10:17] Merge to thelove@canonical.com/bazaar--devo--1.1: relax source defaults and add tags and cscope to precious - closing #3112 (patch-7) [10:17] bob2: lifeless: so, what is going to be the name the new project to put all the little products in? [10:18] spiv: ping === lulu [~lu@host217-37-231-28.in-addr.btopenworld.com] has joined #launchpad === Kinnison [~dsilvers@host81-153-126-219.range81-153.btcentralplus.com] has joined #launchpad [10:34] Morning [10:41] stub: pong [10:42] psycopg.ProgrammingError: ERROR: could not find tsearch config by locale [10:42] :-/ [10:43] daf: aha, same problem as Kinnison had [10:43] did Kinnison manage to fix it? [10:43] you're obviously using a deviant locale on your machine... maybe CY [10:43] I tried changing that === Kinnison did === Kinnison was magical [10:43] stub and I fixed it [10:43] Merge to thelove@canonical.com/bazaar--devo--1.1: Removing extraneous file-diffs command in help (patch-8) [10:43] but it did involve reinitialising the database from scratch [10:43] perhaps I need to explicitly set the locale to C in the configuration file [10:44] oh [10:44] daf: It's not that easy :-) [10:44] grumble [10:44] wow -- I'm not wearing my glasses and I read that as "ritualising the database" [10:44] dead chickens anyone? [10:44] daf: Do you have data you can't bear to lose or can you reinit your entire pg database? === Kinnison wraps the rubber chicken around stevea's head [10:45] actually, no, resetting the DB is ok right now [10:45] okay, is stub around, or shall I walk you through i? [10:45] s/i.$/it?/ [10:45] Since I need to do it on my laptop too [10:45] dude, don't rubber chicken me. I am "the management". [10:46] SteveA: Not even 'da management' can save you from the rubber chicken === SteveA holds the chicken in the air and waits for the deckchair to arrive === Kinnison shoves it up stevea's nose [10:47] better stop there. a bit cold to bury all my clothes. [10:47] Heh [10:48] stub: ping? === SteveA is now known as Keith [10:48] hi, I'm keith === Keith is now known as SteveA [10:48] stop pretending [10:49] spiv: tell me about how the shipit demo is going [10:56] SteveA: I sent a mail to the admins a while ago about getting apache to point to it, otherwise it should be ready. [10:57] morning all [10:57] stub: have a patch for ya [10:57] Kinnison: what exactly did you do to fix your DB? [10:58] Yo [10:58] daf: can you wait until I've finished this upgrade? Install postgresql-contrib for now if you haven't already and set up the search path as per stub's mail [10:59] Kinnison: done that [10:59] anybody else seeing a test failure on POExportTestCase? [10:59] daf: right. given that stub appears to not be around, here goes [10:59] daf: stop postgresql [11:00] ok [11:00] spiv: What do I pass to the authservers createUser method as the loginID? [11:00] daf: cd into /var/lib/postgres [11:00] daf: mv data data.before-kinni-fucked-it-up [11:00] spiv: can you cc me into the mail to admins next time? that allows me to see that things have progressed, but are waiting for the admins to act, without needing to remember to ask you about it. === daf senses magic [11:00] SteveA: Oops, yes, good idea. [11:01] Kinnison: ok [11:01] sudo -u postgres initdb --locale=C --debian-conffile --encoding=UNICODE [11:01] hrm: "sudo: initdb: command not found" [11:02] sudo su - postgres [11:02] stub: an email address. I should rename that parameter I guess... [11:02] initdb --l...... [11:02] You must identify the directory where the data for this database system [11:02] will reside. Do this with either the invocation option -D or the [11:02] environment variable PGDATA. [11:03] add -D /var/lib/postgres/data [11:03] to the cmdline [11:03] right === Kinnison is about to try [11:03] /usr/lib/postgresql/bin/initdb: line 648: /etc/postgresql/6328: Permission denied [11:03] :_/ [11:03] s/_/-/ [11:04] erm, blergh [11:04] hold on, my upgrade has almost finished then I'll try === daf can wait :) [11:06] daf: Your -D option didn't take effect - it is trying to create the database in /etc/postgresql [11:06] oh [11:06] curious [11:06] it's having some effect, because it's no longer complaining about the missing option [11:06] Oh... hmm.. [11:08] Do it again without the --debian-conffile option [11:08] then cd into /var/lib/postgres/data [11:09] ln -sf /etc/postgresql/postgresql.conf [11:09] then back as root, run /etc/init.d/postgresql start [11:09] and then try a 'make' in database/schema [11:11] daf: Oh yeah, su back to postgres and create yourself first [11:11] yeah, just tripped over that :) [11:12] :) === Kinnison wonders if 'make check' on batteries is such a good plan === Kinnison hunts around for a power socket [11:12] ok, make -C database/schema: [11:12] psycopg.ProgrammingError: ERROR: relation "pg_ts_cfg" does not exist [11:16] Did you make the symlink as I said? Did you update postgresql.conf as per stub's mail like I asked? [11:16] the symlink is there [11:16] I modified postgresql.conf when I installed postgresql-contrib [11:17] I just didn't realise at the time that I'd have to totally nuke all my postgres data [11:17] you wouldn't have if your system locale when postgres was installed had been 'C' [11:18] I didn't know that it would be a problem when I installed it last year :-/ [11:18] I'd assumed all the Ubuntu and Debian installs would have had the C locale === Kinnison grins [11:18] stub: poor assumption :-) [11:19] perhaps the priority of that debconf question is lower now [11:19] daf: It seems to come up regularly on the mailing lists [11:19] daf: psql -d launchpad_dev -c show\ search_path [11:19] search_path [11:19] -------------- [11:19] $user,public [11:20] The search path hasn't been updated [11:20] but my postgresql.conf says [11:20] search_path = '$user,public,ts2' [11:20] and /var/lib/postgres/data/postgresql.conf is a symlink to /etc/postgresql/postgresql.conf ? [11:20] yes [11:21] restart postgres once more [11:21] done, search path is still the same === Kinnison boggles === Kinnison did exactly as we just went through and it worked for him [11:22] Add 'this is a syntax error' to your postgresql.conf [11:22] And bounce [11:22] (The postgresql server, not you) [11:22] oop! [11:22] s! [11:24] daf: ? [11:25] symlinked into /var/lib/postgres rather than /var/lib/postgres/data [11:25] things seem fine now [11:25] So simple even a programmer can do it === Kinnison grins stub [11:26] stub: See, I even remembered the process :0) [11:26] thanks! [11:30] so nobody else is seeing the test failure on POExportTestCase [11:31] sabdfl: I'm just updating to check === Kinnison waits for baz to merge 69 new patchlogs [11:34] Merge to thelove@canonical.com/bazaar--devo--1.1: use the current project tree archive by default in archive-mirror fixes bug #4115 (patch-9) === kiko [~kiko@200-206-134-238.async.com.br] has joined #launchpad [11:40] stub, you are a riot [11:41] as fast as baz can be, goddamn it takes ages to star-merge a week's changes [11:41] want a t-shirt? === stub got a t-shirt last time === stub likes his t-shirt [11:44] the new t-shirt should say MAKE BAZ FAST [11:44] but I refrained from political issues this time around [11:44] to be fair on baz, it is being squeeeeeeezed through a tiny tiny pipe right now thanks to Kamion chewwing all his available bandwidth [11:44] can't he ease up on the pr0n just for your star-merge? [11:45] What do you think he is star merging? [11:47] Preparing the artwork for the HumanNG theme ;) [11:49] Merge to rocketfuel@canonical.com/launchpad--devel--0: user creation and authentication tests (patch-928) [11:51] um, i think you mean "testing the artwork for the HumanNG theme" [11:53] how would one test that artwork 8) [11:54] Kinnison: try star-merge -t for three-way merges, MUCH faster on my machine [11:54] sabdfl: -t ? [11:54] three way merge [11:54] I was doing a fairly clean merge anyway I think, but I'll bear that in mind [11:54] sabdfl: what was taking the time was downloading 69 changesets over a choked link [11:55] ah [11:55] It only took ca. 30 seconds to star-merge once it had the patches [11:58] Merge to thelove@canonical.com/bazaar--devo--1.1: Quieter deltas (patch-10) [11:58] Librarian meeting time? [11:58] it is almost time for us to talk about the librarian [11:59] and I am here [11:59] but first, SteveA, debonzi and I have a question [11:59] can I steal a few minutes of your time === Kinnison goes to make coffee first then [11:59] say yes [12:00] okay [12:00] Merge to thelove@canonical.com/bazaar--devo--1.1: do not allow newlines in archive locations passed to make-archive and register-archive (bug #3590) (patch-11) [12:01] hrmph [12:01] why do I see: [12:01] /home/daf/src/canonical/dists/launchpad/lib/canonical/database/sqlbase.py:90: UserWarning: Something tried to set a _connection. Ignored. [12:01] ? [12:01] (this is when using scripts which use initZopeless) [12:01] who changed the layout of the project / product search page? [12:02] daf: maybe you used initZopeless twice [12:02] spiv: ? [12:02] i've seen that too [12:02] SteveA: don't think so [12:02] daf: can you reproduce it? [12:02] it seems to happen every time I run such a script [12:02] that's great. email me about it and I'll find out what is going on. [12:03] kiko: what's the question? [12:03] SteveA: what additional information can I give you? [12:03] tell me exactly how to do what you did [12:03] SteveA, the question is in what cases are classmethods an acceptable way to obtain a collection of objects? [12:03] daf: It's a warning because I wasn't sure if it would happen, and if it did, I wasn't sure if it would necessarily be a real problem or not. Probably making it a warning is too conservative, because it looks like it happens harmlessly inside SQLObject. [12:04] SteveA, I use the rule of thumb, if there's no container, a classmethod on the class itself is acceptable [12:04] I might be able to detect a harmless occurance, actually, in which case I could suppress the spurious warnings. Hmm... [12:04] spiv: ah [12:04] "LP_DBNAME=launchpad_dev python lib/canonical/rosetta/scripts/show-projects.py" is enough to replicate it here [12:04] kiko: class methods are a pain in the arse for security. I'd rather avoid them where possible. [12:05] SteveA, fair enough. How do I get a collection of sourcepackages? [12:05] Yeah, virtually any script with initZopeless is. I figured it was better to have the warning than not, at least initially :) [12:05] they make for confusing code, because you can get to them from an instance or from the class. [12:05] kiko: write a SourcePackageSet class, I suggest. [12:06] Kinnison: please say when you have your coffee [12:06] and how do I get an instance of SourcePackageSet? [12:06] SteveA: the machine is gurgling enthusiastically [12:06] SteveA, if you can answer that then I think we are gold [12:07] kiko: getUtility(ISourcePackageSet). register it as a utility. [12:08] or, from a script, directly import it and use it, seeing as scripts don't register utilities yet [12:08] use it how? sps = SourcePackageSet() [12:08] sps.getPackages("XXX") [12:08] this way, collections of database things are a lot like other database things [12:08] or sps = SourcePackageSet("XXX") [12:08] we have the implementation class, and the interface [12:08] sps.getPackages() [12:09] sps = getUtility(ISourcePackageSet) [12:09] sps.getPackage() [12:09] sps.getPackagesMatching('foo') [12:09] or whatever you need [12:09] SteveA: I now have coffee as black as night, as strong as a hero and as kick-arse-wakeup-goddamnit as a bunch of over-excited geeks at a free-hardware convention [12:10] so, you're ready to talk librarian. [12:10] let's talk about the librarian. [12:10] yesterday, we talked about thel librarian-wrapper thing [12:11] for making a bunch of files appear as a package layout for serving by apache [12:11] it is not clear to everyone why such a wrapper is needed [12:11] also, we talked about how the librarian is to be deployed [12:11] you've conflated two concepts right there [12:11] The wrapper is nothing to do with laying out packages [12:11] :-) [12:11] whether it serves the outside-world directly, or whether it is served via apache [12:12] ok, that's my inaccurate introduction done ;-) [12:12] go ahead, Kinnison [12:12] Okay, so cprov has been working on something called the librarian-wrapper which is to be used by lucille [12:12] It's purpose is to provide a way to optimise disk-usage and network consumption for archives [12:12] Basically it's a local-cache of files uploaded to the librarian. Which can be blown away if needed [12:13] The idea is that it should speed up publishing and provide us with a good basis for using hardlinks to optimise disk consumption when we have piles of derivative distributions [12:13] Why isn't it called librarian-cache then? [12:13] Because the cache is only one bit of its functionality as far as lucille is concerned [12:14] I don't understand "local-cache". To understand this, I need to understand how this stuff is deployed. [12:14] I think that particular explanation will be best performed in a room with everyone present and a whiteboard [12:14] Merge to thelove@canonical.com/bazaar--devo--1.1: Quieter deltas (patch-12) [12:14] it's very hard to draw diagrams and arrows on IRC [12:15] indeed [12:15] Kinnison, just give us a use case for this demon === spiv "me toos" Steve... librarian currently only stores a given file once, no manner how many times it's uploaded, so I don't quite understand the how it will optimise disk-usage. [12:15] spiv: you can't rsync the librarian [12:16] why would you need to? [12:16] because of archives [12:16] Ok. Perhaps we should start by discussing archives? [12:16] the issue here is more that the launchpad team don't understand debian on-disk archives [12:16] Good plan [12:16] go [12:16] elmo: stop me if I get any of this wrong === kiko starts to worry [12:16] There are two major portions to each archive [12:16] the pool and the dists tree [12:17] the pool contains all the source packages and binary packages in the distributions [12:17] s/s$// [12:17] the dists tree contains the Packages/Sources/Release files for each distroarchrelease/distrorelease in the distribution [12:17] A single distribution is in a single archive [12:17] so ubuntu has one dists/ tree and one pool/ [12:18] let's give this discussion 10 more minutes. if it isn't clear by then, we'll defer until we meet in person around a whiteboard. [12:18] Are you all reasonably happy about this so far? [12:18] I think so. Effectively, the dists tree has references to files in the pool? [12:19] indeed [12:19] so far no news [12:19] but if two distroreleases contain the same package (version) then they both point at the same file in the pool [12:19] Now, in terms of mirroring etc, this is a very good situation [12:19] So we want to present on-disk archives in this format for http, ftp, rsync access [12:20] This is what all the lucille publishing stuff is for [12:20] Merge to thelove@canonical.com/bazaar--devo--1.1: Forgot to commit extra file-diffs in cmds.c before merging (patch-13) [12:20] Now. When we have 100 derivative distributions; all of which share most of the same stuff with ubuntu, you'd imagine that the simplest thing to do would be to give each one their own pool/ and dists/ [12:21] and that is exactly what we want to do [12:21] so, you need something that takes information from the database, plus files from the librarian, and puts them out into files and directories ? [12:21] SteveA: yes. That's what canonical.lucille.Publisher does [12:21] okay [12:21] what part of this does librarian-wrapper do? === silbs [~sbsm0084@host217-37-231-28.in-addr.btopenworld.com] has joined #launchpad [12:22] SteveA: The librarian-wrapper's job is to make sure that when we publish ubuntu, kubuntu, gnubuntu, magix, wibblix and fooble-linux, they continue to share on-disk files which are identical. [12:22] This is done by hardlinks === Kinnison micro-workraves, brb in 20 [12:22] Do you see why this is needed? [12:23] Ok, I think I see. [12:23] I still don't get the "cache" part, but I think I'm close [12:23] kiko: The cache works as follows [12:23] In theory, the librarian could be taught to serve files over http in the layout expected for this. But that doesn't help with the requirements of serving ftp and rsync as well. [12:23] kiko: I upload a foo 1.0-1 [12:24] kiko: lucille uploads the files to the librarian [12:24] kiko: it also caches a copy locally on the archive machine [12:24] So a cache of real files on disk makes sense, so we can use the usual (and well-tested) tools for those jobs. [12:24] kiko: when it comes to publishing, it doesn't have to re-download the file from the librarian again [12:24] kiko: and considering the size of archives, this is well worth it [12:25] hmmm [12:25] would be nicer if the librarian offered a mountable filesystem UI [12:25] i.e. with real filesystem semantics [12:25] I think I see. it is a wapper that is used only by lucille's publisher, of the librarian's interface to our software. [12:26] kiko: I don't think that's a viable target [12:26] SteveA: yes [12:26] SteveA: hence it's canonical.lucille.LibrarianWrapper [12:26] I'd have to ask why not [12:26] kiko: when was the last time you wrote a filesystem? [12:27] Kinnison: There's actually a fairly nice python library to do that, I think. [12:27] Possibly worth investigating. [12:27] Kinnison, http://www.freenet.org.nz/python/lufs-python/ [12:27] spiv: that exposes for rsync too? [12:27] it's not really that hard [12:27] ok, I'm happy that I understand what I need to understand right now. The rest, we can leave until mataro. === ddaa [~ddaa@host217-37-231-28.in-addr.btopenworld.com] has left #launchpad [] === Kinnison nods SteveA === ddaa [~ddaa@host217-37-231-28.in-addr.btopenworld.com] has joined #launchpad [12:27] Kinnison: can you write up a few notes from this to the lucille part of the wiki? [12:27] SteveA: I will do [12:28] thanks Kinnison [12:28] the thing I missed yesterday was that this was a wrapper only for use by lucille [12:28] Kinnison, also sort out that crazy mess that is the lucille part of the wiki? 8-))) [12:28] kiko: crazy mess? === kiko bats eyebrows at kinni [12:28] Kinnison: I was referring to a library to write a filesystem in python -- it binds to user-space filesystem kernel module, iirc. So it'd be a "real" filesystem, hence rsync would work. [12:28] B-) === Kinnison bats kiko === sabdfl wonders how to get the dark glasses too [12:28] Whether that sort of thing is mature enough to use for this, I don't know :) [12:28] that is one scary wikipage dude [12:28] spiv: ergh [12:29] Kinnison, it's the lufs-python thing I said, and it's damned cool [12:29] a guy wrote a gmail filesystem using it [12:29] kiko: Have you used it? I haven't had a chance to play with it yet. [12:29] yeah, it's pants [12:29] SteveA: actually; can I leave updating the wiki until we chat about this in mataro? [12:29] B-) [12:29] |3-) [12:29] B-) [12:29] [12:29] kiko: Good pants or dirty smelly underpants? :) === kiko senses Kinnison looked at the wiki page and said "oh-oh" [12:29] spiv, good smelly pants [12:29] Awesome. [12:30] seriously [12:30] gmailfs is bizarre crack, but it works [12:30] Kinnison: okay. I'll write up the essentials of this meeting. [12:30] I hoped it was, but it's one of those things that sounds too good to be true :) [12:30] http://richard.jones.name/google-hacks/gmail-filesystem/gmail-filesystem.html [12:30] except it uses fuse, not lufs [12:30] http://fuse.sourceforge.net/ [12:31] I support the lucille team keeping things simple, in the sense of making something complex out of simple well-known parts. [12:31] SteveA: thanks dude. [12:31] SteveA: are the lists still on rince? [12:31] kiko: No, I thought about it and decided that the right idea was to wait until we could distill the information into something people would find useful to read [12:31] This may well be more resiliant than making one complex thing to do a complex job. === Kinnison glares at kiko [12:31] sabdfl: um... were last I used the admin interface to them. === kiko pats Kinnison [12:32] I only meant to tease my precioussss [12:33] sabdfl: think we should move them onto a canonical machine? [12:33] SteveA: at some time, yes === Kinnison refuses to sniff kiko's ring [12:33] Meanies! Nobody pinged me :-( === stub pouts [12:33] stub, dude, you made me wake up at 7am [12:35] I didn't mean it that way! === kiko cringes [12:35] ah, well, time to do something productive === kiko is now known as kiko_bz === stub [~stub@dsl-246.248.240.220.dsl.comindico.com.au] has joined #launchpad [12:36] stub: I take it my pinging you broke things? [12:36] Kinnison: You crashed gaim [12:36] stub: r0xx0r [12:36] stub: I was pinging you with http://users.pepperfish.net/dsilvers/mp-ping.wav [12:37] evil [12:37] re: librarian filesystems, the web server needs to remain lean and mean - I suspect any virtual filesystem stuff would be the real of other daemons (like this librarian-cache thingy in fact) === cprov [~cprov@c9066416.virtua.com.br] has joined #launchpad [12:39] SteveA: we need a malone user mailing list [12:39] Kinnison: this is served with a content type of text/plain [12:39] why not just use the existing private malone list, but make it open? [12:39] SteveA: it is? eww === Kinnison goes to fix [12:40] alternatively, we could create a malone-users list [12:40] as for rosetta [12:40] when do we need this by? we could create a new list, in the place where we want lists to live on a canonical server. [12:41] no, let's leave the list admin and movement stuff to elmo et al [12:41] i'll create a malone-users list in the current location [12:41] by "we" I meant "ask elmo etc. to do it" [12:42] SteveA: updated to audio/x-wav === Kinnison gets workraved [12:43] erk, it's not loving me [12:45] what isn't? === carlos [~carlos@69.Red-80-33-181.pooles.rima-tde.net] has joined #launchpad [12:47] morning === salgado [~salgado@200-206-134-238.async.com.br] has joined #launchpad [01:29] Merge to thelove@canonical.com/bazaar--devo--1.1: Fix #3555. (patch-14) [01:42] Merge to thelove@canonical.com/bazaar--devo--1.1: allow test suites to synthesis a test uid, in case one is not set - bug #3107 (patch-15) === lulu [~lu@host217-37-231-28.in-addr.btopenworld.com] has joined #launchpad [01:53] SteveA, stub? [01:54] Yo [01:54] stub, salgado and I have a question about subscribers [01:54] we would consider using it for karma events [01:54] but there's something we are fuzzy about [01:55] Its probably the best approach, but go on [01:55] we'd like each callsite that triggers a karma event specify an argument (how much karma to give) [01:55] I'm not sure if that is possible [01:55] ( BradB did the event stuff for Malone emails, so probably knows more than me btw ) [01:56] or alternatively if we could use a mapping from event to karma points that would be used [01:56] If I remember correctly, events are just objects that implement a particular interface - stick in data to your hearts content. [01:58] (this is all from memory from a while ago). I think you just implement an IKarmaEvent inheriting from the relevant interfaces that defines whatever extra info you need. The code then publishes that event and zope shuffles it off to your subscriber. [01:59] salgado, sound doable? [02:00] yep === cprov [~cprov@c9066416.virtua.com.br] has joined #launchpad [02:03] Brad has created ISQLObjectModifiedEvent which should give you an example - grep should get you started if you just want to see the code. [02:05] stub, i've seen the code yesterday. it looks pretty simple to register new subscribers. [02:05] goodie [02:08] kiko_bz: That plpythonu code happier now? I haven't got a Python2.1/PostgreSQL server to test it on. [02:08] stub, another question... what do you think of distributing tsearch2.sql inside (maybe) database/schema? [02:08] salgado, check out stub's merge on anthem for us when you have a moment [02:08] thanks stub [02:08] I'll check [02:09] salgado: I believe tsearch2.sql creates a load of external C server side functions - won't work unless you have the library installed too, and in the location that tsearch2.sql says it is at. [02:12] stub, the problem is when we're creating the database remotely (via PGHOST), and don't have postgres-contrib installed. [02:12] we don't have it locally, but it's installed on the server [02:12] so, we only need the tsearch2.sql file localy, cause we can't read it from the server [02:14] ok. So you copy tsearch2.sql from your server to the location that fti.py expects to find it. I wouldn't want to put it in database/schema because your tsearch2.sql may not be the same as other peoples. [02:15] Which reminds me of the other problem kiko mentioned - that I neglected to allow people to specify the port. [02:15] erm - hostname === stub checks [02:17] Nope - it should allow specification of a remote host, but has not been tested. [02:17] I think it's easyer if we just use PGHOST. is there any problem with this approach? [02:21] The script uses canonical.lp.dbhost and canonical.lp.dbname to connect to the database. canonical.lp.dbname uses LP_DBNAME and LP_DBHOST environment variables to override the default (which is what the makefile does) [02:22] (Although I just noticed the makefile is only setting the LP_DBNAME environment variable to pass to fti.py - not the LP_DBHOST one. That should be a quick fix) [02:24] 'env LP_DBHOST=myserver make' should propogate it through right now and work === cprov [~cprov@c9066416.virtua.com.br] has joined #launchpad [02:25] stub, it should work when creating the database, but not when running lp. [02:26] when running lp, we need to change package-includes/launchpad-configure-normal.zcml. [02:26] if we use PGHOST, then we don't have to change anything else [02:27] A better way is to create a file override-includes/+mydbsetup.zcml with all the configuration, which will override the defaults (using ZCML magic stuff designed for this) === lulu [~lu@host217-37-231-28.in-addr.btopenworld.com] has joined #launchpad [02:28] SteveA wants us to break all this junk out into a single configuration file, which will make rollout to production servers simpler and safer. === Kinnison [~dsilvers@host81-153-126-219.range81-153.btcentralplus.com] has joined #launchpad [02:29] re [02:29] But using the override-includes method works now, and you could add a new rule to the makefile so 'make async-run' or whatever copies that file into the directory and runs [02:30] make async-run is so sweet [02:32] https://wiki.canonical.com/LaunchpadProcessConfig [02:32] can you take a look at that list, and add anything else which needs to be configured per-process ? [02:32] that is, configuration for running the server, not configuration of the software itself [02:33] when it is implemented, that page will change to a guide on how to use this configuration [02:33] make async-run; run-async, run! [02:47] BradB: got a minute? [02:48] Kinnison: got a minute? [02:48] yep [02:48] I'm filling in the monthly report to the canonical directors [02:48] what significant happened on lucille over the last month or so? [02:49] Gosh [02:49] Give me a sec to summarise [02:49] okay [02:49] not looking for much depth [02:49] just an idea of where we're at in the big picture of getting lucille integrated and deployed and used === Kinnison nods [02:50] Most of the side processes are done. I.E. the publishing stuff, the domination stuff. The database has been through loads of changes to bring it up to scratch [02:50] I've dedicated a hell of a lot of my time to getting gina working well too. Perhaps almost 50% of the last month of work for me [02:51] We're aiming to have lucille tracking katie as well as we can by the end of es-conf [02:52] Where 'We' is myself and cprov (and probably lamont for the buildd stuff) [02:52] what does that give us? [02:52] this is basically lucille and katie running in parallel? === cprov_ [~cprov@c9066416.virtua.com.br] has joined #launchpad [02:54] yes [02:55] there will be things we need to add to lucille and the most effective way to find them out is to try to get lucille to shadow katie [02:57] what's a succinct definition of "publishing" and "domination" ? [02:57] lucille is into P+D [02:58] (I did just check the wiki pages) [02:58] The ProjectGlossary carries short definitions of P & D [02:58] Are they insufficient? [02:59] a bit technical. seems to me that publishing is making a coherent set of packages available that an operating system can install. [02:59] domination is clear [03:00] Okay, yes that's a reasonable less-technical summary of P [03:00] Will you drop it into the glossary? [03:01] done [03:01] will we be using lucille with the real live katie next month? [03:01] lucille will be tracking katie [03:01] when we do an actual deployment of soyuz to the golden servers / databases [03:02] I'm not sure [03:02] I imagine that can only be answered by sabdfl and only after we see where we are at the end of es-conf [03:02] okay [03:03] thanks Kinnison [03:25] morning all [03:26] SteveA: gina needs some tweaks so that it can run both debian and hoary simultaneously [03:27] then we can bring it up in production [03:27] i hope during mataro [03:27] carlos: i am still eeing the poexport test failure, it's preventing a commit to rf for me === lulu [~lu@host217-37-231-28.in-addr.btopenworld.com] has joined #launchpad [03:28] Error in test testPoExportAdapter (canonical.rosetta.ftests.test_poexport.POExportTestCase) [03:28] Traceback (most recent call last): [03:28] File "/home/mark/projects/ubuntu/launchpad/lib/canonical/rosetta/ftests/test_poexport.py", line 156, in testPoExportAdapter [03:28] project = Project.selectBy(name = 'gnome')[0] [03:28] File "../../lib/sqlobject/main.py", line 1238, in __getitem__ [03:28] File "../../lib/sqlobject/main.py", line 1242, in __iter__ [03:28] File "../../lib/sqlobject/dbconnection.py", line 520, in iterSelect [03:28] File "../../lib/sqlobject/dbconnection.py", line 448, in __init__ [03:28] File "/home/mark/projects/ubuntu/launchpad/sourcecode/zope/src/zope/app/rdb/__init__.py", line 308, in cursor [03:28] return ZopeCursor(self.conn.cursor(), self) [03:28] InterfaceError: already closed [03:28] any suggestions? [03:28] do you get the same error if you run just that test? [03:28] spiv, carlos, SteveA, any pointers where i can look for a solution to this? [03:28] python test.py -f canonical.rosetta.ftests [03:29] if you get the same error, that's good because the test is isolated enough so that it fails when run on its own [03:30] mark@hagrid:~/projects/ubuntu/launchpad$ PYTHONPATH=./lib/ python lib/canonical/rosetta/ftests/test_poexport.py [03:30] . [03:30] ---------------------------------------------------------------------- [03:30] Ran 1 test in 14.238s [03:30] OK [03:30] Exception exceptions.TypeError: in > ignored [03:30] if you do not, it means that some transaction context is not being cleaned up properly from a previous test [03:30] the __del__ thing isn't important. just some bogosity in how sqlobject does something. [03:31] sabdfl: what do you run to get the problem? just make check? [03:33] sabdfl: if make check fails but test_on_merge.py works, don't worry, pqm will accept your commit [03:33] I think that it's a problem with other tests that are executed with make check but are not executed with test_on_merge.py [03:33] the problem is that you can't check things yourself properly before sending to pqm [03:34] SteveA: I do it with test_on_merge.py canonical [03:34] if the problem doesn't occur for sabdfl for running 'python test_on_merge.py canonical', then that is interesting [03:36] I'm getting rather cold at home, so I'm going to go and work from a cafe for a while, shortly. [03:38] SteveA: Do you have any priority task for Rosetta before Matar? [03:38] I'm going to work fixing the statistics so they are useful and also improving the import code to handle errors better [03:38] any other task I should look at as a priority? [03:40] SteveA: i do get the problem with test_on_merge [03:41] sabdfl: could you send me the output of test_on_merge.py canonical 2>&1 > test-log.txt? [03:42] sabdfl: and disable the test (again) [03:44] sabdfl: disable the test. I think I'll have to add some extra checking to the test runner to detect what the problem is. === salgado is now known as salgado-lunch [03:45] carlos: you have the emails from daf. He's been going through the workflow of "I'm demonstrating rosetta to an audience of thousands", which happens to be very similar to the workflow that a regular translator would use. [03:45] go through the same workflow, maybe with different pot / po files. [03:46] check for links that appear, but don't actually work as advertised [03:46] yeah, my tasks are to improve that process [03:46] check for confusing text or not enough text or too much text [03:46] make sure each page says clearly what it expects of the user, or what it is showing the user [03:47] ok [03:47] sabdfl: can I borrow you for a second, as a "regular launchpad programmer"? Did you read my email about page titles? [03:48] I want to know whether you find it better to include the page title as filling in a metal:fill-slot in each page, [03:48] erm... i've just spent a bit of time adding them to malone pages... and no, not yet [03:48] or if you'd rather use zcml in the browser:page directive to give them [03:48] in some cases the title is easy, for example the addforms [03:48] "Add a New Product" [03:49] but even there, it would be nice sometimes to be able to customise the title [03:49] for="canonical.launchpad.interfaces.IBug" [03:49] name="+frobnicate" [03:49] permission="launchpad.Edit" [03:49] template="../templates/bug-frobnicate.pt" [03:49] title="Frobnicate bug ${context/name}" [03:49] /> [03:49] "Add a Project to the Mozilla Project" [03:49] my proposal is to allow simple tales string: expressions in a "title" attribute in your zcml [03:49] ok, if you can ${context/foo} then that might be fine [03:49] so, this can be a plain string [03:50] what about l10n [03:50] I'm wondering more about whether zcml is the right place to put these things in [03:50] we can handle i18n in this case [03:51] that just becomes a standard thing to be replaced [03:51] personally, I don't mind using metal:this-and-that in pages [03:51] but I think it does complicate things a bit [03:51] using more than one slot all the time [03:57] hmm... a page's title is somewhat like its name in a URL. that is, you'd expect them to be related. === SteveA goes out [04:08] def ProductBugAssignmentFactory(context, **kw): [04:08] return ProductBugAssignment(bug=context.context.bug, **kw) [04:08] bradb: around? [04:08] yes [04:09] if you don't specify a class (viewclass) on an addform, how is the content_factory called? [04:09] i'm trying to make sense of the above code and decide if I want to follow that patter or do something different [04:09] sabdfl: By the default AddView class [04:09] and the default AddView passes the context like that? [04:10] yes [04:11] seems to me that a database-class Factory should not be aware of "context" issues [04:11] There was a time at which I understood the context.context part...it's failing to come to mind at the moment. /me thinks. [04:11] malone/bugs/CONTEXT/productassignments/+new [04:11] sabdfl: The context could be something like a container though, I think, so that's why it should know. [04:11] context.context.bug... [04:12] seems to me i want to be able to use a ProductFactory to create a product with or without a project [04:12] if i'm doing it in a project, then use it, if not, don't [04:12] oh! i think context is a view actually. [04:12] context.context... would break under different usage patters [04:13] it make the db stuff view-sensitive [04:13] yuck... a context that is a view? that's nice and readable [04:13] sounds like z3 breakage [04:13] that's why it has a context attrib. === BradB takes a quick look at AddView to be reminded of the details [04:14] i think addview / editview / form could be turned into something simpler and more generic [04:14] sabdfl: yep, i filed a bug on that a long time ago. [04:15] sabdfl: stevea's going to do something about it in mataro i think/hope [04:15] because until it's genericized, it's slowing us down. [04:16] we want a browser:form directive, where you can provide a thing as input and then do something with the submitted values. [04:17] yeah, the factory is bound to the view with self._factory(*args, **kw) in AddView.create, I believe. [04:23] hmm... there must be a better way [04:23] sabdfl: Hm, skimming through Z3 sources, they seem to use classes as the content_factory [04:24] i think i'm going to write a custom view, then call the factory directly [04:25] sabdfl: you can use keyword_arguments in your addform too [04:26] the be explicit about what gets passed for the kw args to your factory [04:26] I'd prefer an approach that avoids writing code, so that we don't have to maintain it. === salgado-lunch is now known as salgado [04:27] sabdfl: Or you could write your own content_factory if you're creating the content in that much of a different way. Writing a new view is a fair bit of effort (relatively speaking, i.e. thinking of if we consistently added new views in this way, we'd have a ton of extra code to maintain.) [04:30] the existing machinery is fine if you are adding or editing a class that maps directly and exclusively to a table [04:30] and if everything in that page can be made into a nice widget [04:30] sabdfl: BugFactory does something that doesn't map onto a table. [04:30] we stretch that with "owner" where we want a field to be derived from the request/principal info [04:31] then we stretch it really HARD when we want to add something and also touch a bunch of other tables [04:32] BradB: to use BugFactory to "add a bug to an existing product" I had to create a custom View class [04:32] sabdfl: Hitting the request directly in a content_factory is nasty. Hitting more than one table is fine though, I think. There's no explicit or implied relationship between content_factory and (only one) table. [04:32] sabdfl: at worst, you would have had to create a new content_factory. [04:32] that View class knows the principal, and knows the Product, so it can call the content fctory with the correct parameters [04:33] i would prefer to have one factory and multiple views, than one view and multiple factories [04:33] and if you think about it, that's what you've wanted too [04:33] that's why you kept urging me to make my code use the BugFactory, which i did [04:33] that way, all the notification logici is in one place [04:34] basically, the View is by definition sensitive to the specific setting of that request [04:34] If you want something built in a different way, you send it to a different factory to be built. [04:34] no you don't [04:34] you call the factory in a different way [04:34] which means a custom view class [04:34] sabdfl: You can do that in ZCML though [04:34] not very well [04:34] sabdfl: no! you can do that in ZCML. [04:35] dude, get context.context.bug OUT of a database factory class, then we can talk [04:36] sabdfl: you're doing the same type of thing though, but instead writing a whole new view to achieve that. [04:36] sabdfl: We need to get at a newly created bug's id somehow. [04:36] And that's not yet available in the request. [04:37] "a whole new view" [04:37] a view should be as simple as: [04:37] sabdfl: a content_factory is a simple little function [04:38] class ProjectAddProductView(AddView): [04:38] def addmethod(self, **kw): [04:38] return factory(**kw) [04:39] nothing more [04:39] of course, you can add some other processing in the addmethof [04:39] Merge to thelove@canonical.com/bazaar--devo--1.1: cmd-delta is much smarter/looser now. You can now pass ., revision, version or package (patch-16) [04:39] to set things up right for the factory [04:40] sabdfl: okay, maybe i'm being retarded, but BugFactory doesn't do context.context.bug. [04:41] (15:08:29) sabdfl: def ProductBugAssignmentFactory(context, **kw): [04:41] (15:08:29) sabdfl: return ProductBugAssignment(bug=context.context.bug, **kw) === cprov_ [~cprov@c9066416.virtua.com.br] has joined #launchpad [04:43] sabdfl: let's face it though, that 3 line class you show above reaks of boiler plate. surely there's a way to do it in zcml. [04:44] sabdfl: i dunno, we shouldn't spend too too much time on this. if you want to do it your way, go ahead. if i figure out a better way (i.e. no code), i'll fix it and tell you what i did. [04:45] s/reaks/reeks/ [04:49] Overriding the constructors of the relevant content classes would also be a useful thing, and reduce the number of places to find out how a Foo is constructed to just one: Foo.__init__. [04:50] (override to perhaps take optional args and create other db objects closely related to the thing being created when it makes sense to do so: e.g. default Cc'er on a bug, spname/distro assignment, etc.) === BradB has to step out for a bit to do some pre-Spain banking === BradB is now known as BradB|out === cprov_ [~cprov@c9066416.virtua.com.br] has joined #launchpad [05:03] New Malone bug #114: ""See the bugs assigned to you" doesn't work correctly", submitted by Andrew Bennetts [05:03] https://dogfood.ubuntu.com/malone/bugs/114 [05:08] New Malone bug #115: ""my todo list" page generates broken links to bugs", submitted by Andrew Bennetts [05:08] https://dogfood.ubuntu.com/malone/bugs/115 [05:12] Merge to thelove@canonical.com/bazaar--devo--1.1: Copyright fix. (patch-17) === Kinnison [~dsilvers@haddenham.pepperfish.net] has joined #launchpad === cprov_ [~cprov@200.99.130.18] has joined #launchpad === cprov_ [~cprov@c9066416.virtua.com.br] has joined #launchpad === cprov_ [~cprov@200.99.130.18] has joined #launchpad [06:32] Merge to thelove@canonical.com/bazaar--devo--1.1: Really dont get pristines on get if specified (patch-18) [06:34] Merge to thelove@canonical.com/bazaar--devo--1.1: Handle register-archive with urls with % in them (patch-19) [06:38] Merge to thelove@canonical.com/bazaar--devo--1.1: fix lock-revision to generate txn ids, and to work when passed a version - bug #3747 (patch-20) === SteveA [~steve@adsl-213-190-44-43.takas.lt] has joined #launchpad [06:51] Merge to thelove@canonical.com/bazaar--devo--1.1: Fixed a print to stdout instead of stderr in make-archive (patch-21) [07:10] BradB|out: yes, the three-liner was boilerplate, if that's all you are doing then you would use zcml [07:11] but if you want to fiddle with the form results, THEN call the factory, this is the way to do it === BradB|out is now known as BradB [07:15] Merge to thelove@canonical.com/bazaar--devo--1.1: cmd-apply-delta now smart enough to hunt out the tree root (patch-22) [07:17] Merge to rocketfuel@canonical.com/pyarch--production--1.5: fixes for baz format archives (patch-1) === lulu [~lu@host217-37-231-28.in-addr.btopenworld.com] has left #launchpad [] [07:38] BradB, we don't have a notify() for a comment added event, right? [07:47] salgado: notify is always there, and yes, there's definitely one for a comment. [07:48] I'm adding a bunch more subscribers today for bug activity tracking. [07:50] BradB, I don't see the registered subscriber ( notify_bug_comment_added) being called when a new comment is added. [07:53] Ah, I think it's because of Mark's refactoring of bug message. [07:53] it's registered like: [07:53] for="canonical.launchpad.interfaces.IBugMessage [07:53] zope.app.event.interfaces.IObjectCreatedEvent" [07:53] factory="canonical.launchpad.mailnotification.notify_bug_comment_added" /> [07:53] Maybe the thing that gets created is different now (and thus that subscription doesn't get notified.) I'm not sure of the details offhand though. [07:54] I have a feeling that if it were reg'd for IMessage it would work again. [07:54] sabdfl: Sound about right? :) === BradB fixes it [07:56] eh, it's not obvious though, hm, I'll wait === silbs [~sbsm0084@host217-37-231-28.in-addr.btopenworld.com] has left #launchpad [] [08:14] BradB: yes, i think that would be about right [08:14] i'm not sure if the message on its own is enough though [08:15] Nope, that's where the "not obvious though" part comes in. [08:15] you probably want to catch the BugMessage, so you can notify people of the creation of a specific message for a specififc bug [08:15] notify() has to be called with the correct object [08:15] stevea: am getting an odd permission problem traceback [08:15] It must now be being called with an IMessage [08:15] TypeError: ('Not enough context information to get parent', ) [08:16] BradB: but creating the Message doesn't tell you what it's been created *for* [08:16] it's the BugMessage that gives it context [08:16] for example, without the BugMessage, you would have no idea who to notify ;-) [08:17] sabdfl: that's why I'm saying it has to be called with the IBugMessage. Currently, it must be being called with an IMessage. [08:17] "it" being notify(), of course [08:19] BradB, do you see any problems in passing the request to SQLObjectModifiedEvent? [08:21] salgado: It's cleaner to avoid depending on it in the subscribers. Why do you want the request in a subscriber? [08:23] BradB, I'm subscribing functions to assign karma for people that change bugassignments, and I want to know who changed it [08:24] can I get this information from somewhere else? [08:26] salgado: I think you should be able to create your own event type, IKarmaEvent, that stores the person who's earned the karma. Your subscriber would then subscribe to the object type, SQLObjectModifiedEvent and IKarmaEvent. === Kinnison waves [08:27] cheers [08:27] c'y'all tomorrow [08:28] sabdfl: I took a chunk of this afternoon to do an emergency IP switch. I'll make it up by doing work while travelling to Mataro if that's okay with you [08:28] salgado: Or IKarmaEarnedEvent, or whatever seems like a good name for it. === carlos [~carlos@69.Red-80-33-181.pooles.rima-tde.net] has joined #launchpad [08:31] I think I'll create a canonical.launchpad.subscribers hierarchy, because we're starting to accumlate subscribers and it'd be nice to be able to point a newbie to one place to find out everything they need to know about who's listening. [08:31] s/hierarchy/namespace/ [08:32] hi [08:32] BradB, looks good, but I don't see how to store the logged in user in IKarmaWhateverEvent [08:32] salgado: In the view, you'd grab it from the request. [08:32] salgado: An event can be any Python object remember. [08:33] BradB, ok, but then I'll have to change all callsites to notify() for my event? [08:34] salgado: Anywhere that generates karma, yep. [08:34] salgado: In doing so, you'll communicate a lot better to the maintainer of the code. [08:35] If an event modifies an sqlobject and generates karma, I want to see notify(sqlobject_modified, karma_earned) in the code. [08:38] BradB, good point. I'll do this [08:39] cool [08:42] I'm merging the namespace now, just so you have it. [08:43] Kinnison: not great, wrok-while-travel isn't optimal but if that's the best case situation then thanks for letting me know [08:47] Merge to rocketfuel@canonical.com/launchpad--devel--0: add a canonical.launchpad.subscribers Python package, in which everything that listens for event notifications should be put (patch-929) [09:32] BradB, now that I looked closer to the problem, there's one thing I want to point out. [09:33] when you call notify(SomeEvent), you're not able to tell what will be the consequences of that event (as you don't know that the SQLObjectModifiedEvent will trigger a mail notification) [09:34] to know what is triggered by any event, you must look to that event subscribers. [09:34] salgado: Yeah, that's the point. :) [09:35] and also, don't look sane to me having a KarmaEvent, cause the assignment of a Karma is the consequence of an event. [09:37] salgado: when something modifies an sql object, an ISQLObjectModifiedEvent is generated. When something generates karma, an IKarmaEvent is generated. [09:37] not all sqlobject mods gen karma, not all karma is tied to modifying an sql object [09:40] the same is true for mail notification, and we don't have a IMailNotificationEvent, cause it's a consequence of the real event. you see my point? [09:41] BradB, I'm not really in favor of having salgado mess with callsites to add karma [09:42] we already have the event system set up [09:42] why not take advantage of it? [09:42] salgado: Yeah, you could avoid it I guess. [09:43] cool! [09:44] salgado: but then you return to the not-having-the-principal problem [09:45] Maybe you have to add a bit of fu to an ISQLObjectModifiedEvent. [09:45] leave that to us! :) [09:45] fu is my middle name [09:45] kiko fu bar [09:45] kiko_bz: As long as you don't pass the request to the subscribers! [09:47] we'll see we'll see [09:49] BradB, can you explain why storing the request in the event would be evil? SteveA, do you have an opinion? [09:50] it depends [09:52] SteveA: have you tried this permissions voodoo? [09:53] on phone, brb [09:53] i got a variety of colourful errors and then reverted to launchpad.AnyPerson (a.k.a. wikimode) [09:56] salgado: I can't give you a specific reason off the top of my head, other than that coupling the request with that event type seems evil, when all you really want to store is the principal. (e.g. what if you then come along and write code in event handlers that starts pulling other things out of the request? and then other event handlers want those same values, but are getting called in places where they're gotten from somewhere [09:56] /other/ than the request?) [09:57] If you store exactly what you need as attributes of the event, that works everywhere, because I can read the Interface of that Event and know exactly what I have access to when it's fired off. [09:59] BradB, what if I store only principal in the SQLObjectModifiedEvent? [10:00] salgado: yeah, that was the "bit of fu" I mentioned earlier. :) that would be a reasonable thing to include with a modified event, I think. [10:01] SteveA: Has there ever been any discussion about how we could use the factory subdirective to help us survive mass-refactorings? [10:03] right... [10:03] storing the request in an event is not really all that good, unless the event is a UI event [10:03] storing the principal, or the "current person" is a better idea [10:04] as it is being specific, and giving just the information that is pertinent to the event [10:04] otherwise, it becomes a bit like using a global all the time -- hard to see what's going on; what the interrelationships are [10:04] ...and can't be (accurately) documented in an interface :) [10:05] pay attention to the semantics of events: there is no problems with making one event fire off another event [10:05] it is quite natural to have a FooAddedEvent, and have that (under certain circumstances) cause a KarmaReceivedEvent [10:05] keep the events semantically distinct [10:05] that was my first suggestion :) [10:06] BradB: I've never particularly found a use for the factory subdirective. I've found utilities more useful. However, if you have some ideas about it, it's something we should talk about in spain. [10:07] sabdfl: can I see more of the traceback, or get a patch that would reproduce it for me? [10:07] I'm a bit confused by the part you pasted above, and I think I need a bit more context. [10:07] SteveA: try refueling, and checking if you have checkPermission on database.Product [10:08] then try set the permission on the product/+edit page to launchpad.Edit [10:08] and you'll see it [10:08] the problem is that it appears to think the connection is Anonymous [10:08] okay. refueling. [10:08] SteveA: In brief: if we provide factories with IDs, we can get at them via the zope api, instead of directly importing the content classes. Then when we shuffle the content classes around, creating objects doesn't break. But yeah, Spain perhaps. [10:09] BradB: I understand that, but I'm not sure the indirection is worth the effort. definitely something to chat about in spain, though. [10:09] Merge to rocketfuel@canonical.com/launchpad--devel--0: projectless products and slicker project/product add/edit forms (patch-930) [10:09] ok [10:14] however... the factories can be made smart about events and permissions [10:14] so, it might be a good trade-off [10:14] need to sketch it out better to see, though [10:15] sabdfl: I did actually use the permissions stuff. So, I'm surprised that this is giving an error. Not sure what's different about this case yet. [10:16] if self.id == principal.id: [10:16] return True [10:16] else: return False [10:17] evil syntax [10:17] the return should be indented on the line under the else: [10:18] right [10:24] sabdfl: I can see what is going on now. I'm logged in, but I'm not the product's owner, so I don't have rights to edit the product. So, the system is trying to prompt me for HTTP Basic Authentication, as I might have another login that would work in this case. (This is the normal web behaviour). However, prompting for basic auth is failing, because it only works in launchpad when you are anonymous. [10:24] ok [10:25] The reason it only works when you're anonymous is down to a slightly odd bogosity in the part of zope3 that is doing this. Basically, I'll naed to make LaunchpadPrincipals conform to an undocumented API. [10:25] I'll do this shortly, and then it will work as it should do. [10:26] I'll also need to add this to my list of slightly-off things I need to chase up in zope3. [10:28] we'll need to consider how to present this when we do more advanced permissions stuff. [10:28] it may be a reasonable assumption that each person has just one login to launchpad [10:29] so, you're either logged in, or you're not. [10:29] there is no sense in which you'd want to log in as someone else to do a particular action. [10:30] so, when you view the product page as anonymous, you should see an "[Log in to] edit" link. (the [Log in to] might be an icon, indicating that this link may be available if you log in) [10:30] when you view the product page logged in, but as someone who can't edit, there's no point offering them to edit it, or to log in to edit it. [10:31] when you view the product page, and you are logged in as the right person to edit it, then you obviously want a link to edit it. [10:32] would it be possible to do a tal:condition="context/permission/Edit" ? [10:32] How do I commit just one *new* file with baz? baz commit -s "blah" -- thefile gives me: make-changeset-files: file missing from ORIG tree (database/schema/pending/bradb-allow-bugactivity-nulls.sql) [10:33] BradB: best ping lifeless on that [10:33] ok [10:33] BradB, I think it's commit -s "foo bar" -- file1 file2 [10:34] oops [10:34] argh, ctags -R . doesn't work in the "launchpad" directory [10:34] didn't read the whole line [10:34] sabdfl: it will be possible to do basically that, yes [10:35] BradB: did you baz add that file first? [10:36] sabdfl: yep: [10:36] bradb@oxygen:~/launchpad $ baz tree-lint [10:36] bradb@oxygen:~/launchpad $ [10:37] it shows up A'd in baz changes [10:37] I've committed just one file or two before, but I don't remember if I've ever done that op with brand new files before. [10:37] and i don't think i've tried that op in anyway with baz [10:38] BradB, this don't work for new files, it's in tla docs. [10:38] salgado: I'm not using tla. :) [10:38] but this is something baz inherited from tla [10:39] salgado: Where is it in the tla docs though? It's certainly well-hidden, wherever it is. [10:39] BradB, http://www.gnu.org/software/gnu-arch/tutorial/selected-files-commits.html#Selected_Files_Commit [10:39] BradB: if this isn't fixed yet in baz, I'm pretty certain it is on the "to fix" list. Don't know if there is a bug on it though. [10:40] fwiw, both the bugs I submitted for baz were fixed today. definitely more responsive than under the tla regime. [10:41] you can also type: baz archive-mirror to mirror the current tree. [10:42] sabdfl: fixed in my tree. merge request sent to pqm === BradB does a little shifting around to brute force this [10:43] you can also say "baz lint" now instead of "baz tree-lint" [10:44] SteveA: Yeah, I saw that. I didn't update though. [10:45] I'm really happy that the do proper unlocks on incorrect GPG p/w's now. :) [10:45] s,the do,they do, [10:45] yeah, me too [10:45] I've got bash complete going, so there's no diff between baz tree-lint and baz lint :) [10:46] I'm almost sure they removed tree-lint [10:47] Yeah, I think so, but I'm just saying it doesn't really save me any typing. [10:49] it is a small difference in how much I have to think about it [10:49] I want to lint. So I needed to think "oh, that's tree-lint". And backwards too, when reading a baz/tla command. [10:50] oh, maybe I want sock-lint instead today [10:50] how many kinds of lint were planned for in tla? [10:50] hey dilys? [10:51] talk to me dylis [10:51] Merge to rocketfuel@canonical.com/launchpad--devel--0: Fix bug in launchpad auth system where there would be an error if you're asked to re-authorize when you are logged in already. Also, made product/+edit page require launchpad.Edit permission. (patch-931) [10:51] thanks babe [10:51] heh [10:52] ok, must get some food now. I'll check in a tales permission-checky-helper tomorrow. [10:53] hmm.. should have included "sabdfl" in the message to pqm, so that mark's "kibo alarm" would sound. [10:54] SteveA: thankee muchly [10:54] so, now we need a good answer to the "launchpad.Admin" team [10:54] better, clearly than my "hardcode a list in python somewhere" plan ;-) [10:57] Merge to rocketfuel@canonical.com/launchpad--devel--0: add a small db patch to allow nulls on oldvalue/newvalue for BugActivity since, logically, the old or newvalue of something that changed might be null (patch-932) [10:58] sabdfl: should I move code as I update it from rosetta/browser.py to launchpad/browser/foo.py? [10:58] carlos: yes please! [10:58] you asked me to wait for the zcml cleanup you were doing [10:58] ok [10:59] carlos: zcml cleanup should all be committed now [10:59] check out rosetta/*.zcml ;-) [10:59] sabdfl: I know ;-) [11:00] carlos: i've got a db patch which allows a product to be free, and have no project [11:00] i will setup rosetta so that rosetta/products/$Product.name/ goes straight to the product, if i haven't already done so [11:00] hmm, that could break rosetta... [11:00] yes, it will [11:01] i will do a little testing but there isn't much sample data to work with in rosetta [11:01] if i have a potemplate and a pofile handy, can i test out the new upload / import process? [11:01] sabdfl: but we said that we could have two products with the same name, how will you handle it? [11:01] sabdfl: sure [11:01] sabdfl: daf did it already [11:01] pending/mark-project-refactor.sql ;-) [11:02] is it obvious how to do that? [11:02] and i'm improving the process now [11:02] sabdfl: more or less [11:02] you create a new project [11:02] then a new product [11:02] sabdfl, debonzi's almost got soyuz under control tonight but collapsed under load, will finish up tomorrow -- nice patch [11:02] then you have a chance to create a template [11:02] and also a link to upload files [11:02] sabdfl, and I just saw salgado's karma displayed on the person view, woot [11:02] sabdfl: I could forward you all steps daf did [11:03] sabdfl: you have them in your inbox now [11:07] nice! [11:07] congrats salgado [11:14] Did you saw the "funny" UI bug we have in our forms? every time you click over a button, the page content expands itself using the spare space [11:23] SteveA: ping? === BradB is now known as BradB|brb [11:38] Merge to rocketfuel@canonical.com/launchpad--devel--0: Subscribers for Bug events to do karma-gathering. (patch-933) [11:48] anyone knows how works the file upload feature in Zope3/launchpad? === BradB|brb is now known as BradB [11:54] carlos: Are there places near BCN that I can pick up Cisco wireless cards? [11:54] BradB: I suppose it [11:54] BradB: http://informatica.elcorteingles.es or http://www.fnac.es [11:55] if you see it there, you will be able to buy it at Barcelona [11:55] hmm [11:55] lifeless: are you adding the products at the moment? someone is adding them without descriptions, please put good descriptions in, copy from their home pages if needed [11:55] also, need home pages :-) [11:55] I'm not sure if they have an english version... let me check it for you :-) [11:55] carlos: yes, that bug is driving me nuts [11:56] sabdfl: I saw a way to expand it as much as I want without submit the form :-P [11:56] a kind of eastern egg :-) [11:58] carlos, visit www.lecto.com.br and type foobar into the text entry [11:58] *that's* an easter egg :) [11:59] lifeless: i'm not going to approve items like gstream and gst-plugins that have such terse summary and description. make them count! [11:59] kiko_bz: X-) [12:00] BradB: don't see it there but I have seen cisco wireless card in Spain, so it should not be a problem