Re: [systemd-devel] python - reading the journal

2013-03-03 Thread David Strauss
I don't want this work to get buried. Where are we on the revisions suggested by Zbyszek? On Sat, Feb 23, 2013 at 7:34 AM, Zbigniew Jędrzejewski-Szmek zbys...@in.waw.pl wrote: On Sat, Feb 23, 2013 at 02:05:27PM +, Steven Hiscocks wrote: On 23/02/13 00:43, Zbigniew Jędrzejewski-Szmek wrote:

Re: [systemd-devel] python - reading the journal

2013-03-03 Thread Zbigniew Jędrzejewski-Szmek
On Sun, Mar 03, 2013 at 07:10:45PM -0800, David Strauss wrote: On Sun, Mar 3, 2013 at 6:59 PM, David Strauss da...@davidstrauss.net wrote: I don't want this work to get buried. Where are we on the revisions suggested by Zbyszek? Hi David, just to wrap this up, I think that the only

Re: [systemd-devel] python - reading the journal

2013-02-23 Thread Steven Hiscocks
On 23/02/13 00:43, Zbigniew Jędrzejewski-Szmek wrote: On Thu, Feb 21, 2013 at 06:46:35PM +, Steven Hiscocks wrote: On 21/02/13 01:49, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 19, 2013 at 09:02:56PM +, Steven Hiscocks wrote: I've pushed a few more commits. I've pushed a few

Re: [systemd-devel] python - reading the journal

2013-02-23 Thread Zbigniew Jędrzejewski-Szmek
On Sat, Feb 23, 2013 at 02:05:27PM +, Steven Hiscocks wrote: On 23/02/13 00:43, Zbigniew Jędrzejewski-Szmek wrote: On Thu, Feb 21, 2013 at 06:46:35PM +, Steven Hiscocks wrote: On 21/02/13 01:49, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 19, 2013 at 09:02:56PM +, Steven

Re: [systemd-devel] python - reading the journal

2013-02-22 Thread Zbigniew Jędrzejewski-Szmek
On Thu, Feb 21, 2013 at 06:46:35PM +, Steven Hiscocks wrote: On 21/02/13 01:49, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 19, 2013 at 09:02:56PM +, Steven Hiscocks wrote: I've pushed a few more commits. I've pushed a few commits to

Re: [systemd-devel] python - reading the journal

2013-02-21 Thread Steven Hiscocks
On 21/02/13 01:49, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 19, 2013 at 09:02:56PM +, Steven Hiscocks wrote: I've pushed a few more commits. I've pushed a few commits to https://github.com/keszybz/systemd/commits/python-systemd-reader This is your tree but rebased onto my id128

Re: [systemd-devel] python - reading the journal

2013-02-20 Thread Zbigniew Jędrzejewski-Szmek
On Tue, Feb 19, 2013 at 09:02:56PM +, Steven Hiscocks wrote: I've pushed a few more commits. I've pushed a few commits to https://github.com/keszybz/systemd/commits/python-systemd-reader This is your tree but rebased onto my id128 stuff, and modified to use it. It also has sphinx-generated

Re: [systemd-devel] python - reading the journal

2013-02-19 Thread Steven Hiscocks
On 19/02/13 07:05, David Strauss wrote: On Mon, Feb 18, 2013 at 11:28 AM, Steven Hiscocks steven-syst...@hiscocks.me.uk wrote: Sounds good. I suppose `log_level` should become `add_loglevel_matches` for consistency. (or actually `add_priority_matches`?) Log level is the Pythonic language;

Re: [systemd-devel] python - reading the journal

2013-02-18 Thread Steven Hiscocks
On 18/02/13 02:17, David Strauss wrote: Great progress! Thanks, and thank you for your feedback. A few more remarks: * Class methods ought to be verbs. this_machine and this_boot are the key ones that come to mind. Maybe add_machine_match and add_boot_match? Sounds good. I suppose

Re: [systemd-devel] python - reading the journal

2013-02-18 Thread David Strauss
On Mon, Feb 18, 2013 at 11:28 AM, Steven Hiscocks steven-syst...@hiscocks.me.uk wrote: Sounds good. I suppose `log_level` should become `add_loglevel_matches` for consistency. (or actually `add_priority_matches`?) Log level is the Pythonic language; please continue using it. The journal itself

Re: [systemd-devel] python - reading the journal

2013-02-17 Thread David Strauss
Great progress! A few more remarks: * Class methods ought to be verbs. this_machine and this_boot are the key ones that come to mind. Maybe add_machine_match and add_boot_match? * In methods like this_machine that have special handling for the None value as myself, the function should use

Re: [systemd-devel] python - reading the journal

2013-02-15 Thread Steven Hiscocks
On 11/02/13 05:49, Zbigniew Jędrzejewski-Szmek wrote: On Fri, Feb 08, 2013 at 10:20:57PM +, Steven Hiscocks wrote: I thought the easiest way was to just inherit the Journal (now _Journal), replacing __new__ with all the python RunString stuff.

Re: [systemd-devel] python - reading the journal

2013-02-12 Thread Lennart Poettering
On Sun, 03.02.13 21:18, Steven Hiscocks (steven-syst...@hiscocks.me.uk) wrote: Hi, I've been developing a python module for accessing the journal, using the journal API. (https://github.com/kwirk/pyjournalctl) One issue I've had is with 'sd_journal_seek_monotonic_usec'. When called,

Re: [systemd-devel] python - reading the journal

2013-02-12 Thread Lennart Poettering
On Mon, 04.02.13 18:30, Steven Hiscocks (steven-syst...@hiscocks.me.uk) wrote: So if I understand correctly, a _BOOT_ID match must be in place for sd_journal_seek_monotonic_usec to function correctly? No really, it should suffice to just pass the valid boot id to _seek_monotonic(). Are you

Re: [systemd-devel] python - reading the journal

2013-02-10 Thread Zbigniew Jędrzejewski-Szmek
On Fri, Feb 08, 2013 at 10:20:57PM +, Steven Hiscocks wrote: I thought the easiest way was to just inherit the Journal (now _Journal), replacing __new__ with all the python RunString stuff. https://github.com/kwirk/systemd/commit/9003fdbc69577840ab6a1501a1c49f7377b6124d Hi Steven,

Re: [systemd-devel] python - reading the journal

2013-02-09 Thread Zbigniew Jędrzejewski-Szmek
On Thu, Feb 07, 2013 at 03:19:03PM -0800, David Strauss wrote: Can we spend some time on IRC prepping the systemd patch? I'd like to get that rolling. Hi David, I pushed an updated version of [1], with uuid.UUID all over. Please have a look. Zbyszek [1]

Re: [systemd-devel] python - reading the journal

2013-02-08 Thread Steven Hiscocks
On 06/02/13 00:55, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 05, 2013 at 11:45:10PM +, Steven Hiscocks wrote: On 05/02/13 23:00, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 05, 2013 at 09:22:46PM +, Steven Hiscocks wrote: On 05/02/13 02:49, Zbigniew Jędrzejewski-Szmek wrote:

Re: [systemd-devel] python - reading the journal

2013-02-08 Thread Zbigniew Jędrzejewski-Szmek
On Fri, Feb 08, 2013 at 07:51:48PM +, Steven Hiscocks wrote: On 06/02/13 00:55, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 05, 2013 at 11:45:10PM +, Steven Hiscocks wrote: On 05/02/13 23:00, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 05, 2013 at 09:22:46PM +, Steven

Re: [systemd-devel] python - reading the journal

2013-02-08 Thread Steven Hiscocks
On 08/02/13 20:51, Zbigniew Jędrzejewski-Szmek wrote: On Fri, Feb 08, 2013 at 07:51:48PM +, Steven Hiscocks wrote: On 06/02/13 00:55, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 05, 2013 at 11:45:10PM +, Steven Hiscocks wrote: On 05/02/13 23:00, Zbigniew Jędrzejewski-Szmek wrote:

Re: [systemd-devel] python - reading the journal

2013-02-05 Thread David Strauss
On Mon, Feb 4, 2013 at 6:49 PM, Zbigniew Jędrzejewski-Szmek zbys...@in.waw.pl wrote: What about renaming Journalctl to Journal? It doesn't really control anything :) Neither does the actual journalctl. :-) But, systemd's naming convention is to call first-tier shell utilities somethingctl and

Re: [systemd-devel] python - reading the journal

2013-02-05 Thread Steven Hiscocks
On 05/02/13 02:49, Zbigniew Jędrzejewski-Szmek wrote: Hi, On Mon, Feb 04, 2013 at 10:42:02PM +, Steven Hiscocks wrote: I've made the suggested changes and pushed it to github. Feedback welcomed :) Thanks! Some more thoughts on the API below. Some of those are probably stupid, but I want

Re: [systemd-devel] python - reading the journal

2013-02-05 Thread Zbigniew Jędrzejewski-Szmek
On Tue, Feb 05, 2013 at 09:22:46PM +, Steven Hiscocks wrote: On 05/02/13 02:49, Zbigniew Jędrzejewski-Szmek wrote: Hi, On Mon, Feb 04, 2013 at 10:42:02PM +, Steven Hiscocks wrote: I've made the suggested changes and pushed it to github. Feedback welcomed :) Thanks! Some more

Re: [systemd-devel] python - reading the journal

2013-02-05 Thread Steven Hiscocks
On 05/02/13 23:00, Zbigniew Jędrzejewski-Szmek wrote: On Tue, Feb 05, 2013 at 09:22:46PM +, Steven Hiscocks wrote: On 05/02/13 02:49, Zbigniew Jędrzejewski-Szmek wrote: Hi, On Mon, Feb 04, 2013 at 10:42:02PM +, Steven Hiscocks wrote: I've made the suggested changes and pushed it to

Re: [systemd-devel] python - reading the journal

2013-02-04 Thread Steven Hiscocks
On 04/02/13 05:13, David Strauss wrote: I second the interest in committing this to the existing Python support once polished. On Sun, Feb 3, 2013 at 6:07 PM, Zbigniew Jędrzejewski-Szmek zbys...@in.waw.pl wrote: On Sun, Feb 03, 2013 at 09:18:28PM +, Steven Hiscocks wrote: Hi, I've been

Re: [systemd-devel] python - reading the journal

2013-02-04 Thread Steven Hiscocks
On 04/02/13 18:30, Steven Hiscocks wrote: On 04/02/13 05:13, David Strauss wrote: I second the interest in committing this to the existing Python support once polished. On Sun, Feb 3, 2013 at 6:07 PM, Zbigniew Jędrzejewski-Szmek zbys...@in.waw.pl wrote: On Sun, Feb 03, 2013 at 09:18:28PM

Re: [systemd-devel] python - reading the journal

2013-02-04 Thread Zbigniew Jędrzejewski-Szmek
Hi, On Mon, Feb 04, 2013 at 10:42:02PM +, Steven Hiscocks wrote: I've made the suggested changes and pushed it to github. Feedback welcomed :) Thanks! Some more thoughts on the API below. Some of those are probably stupid, but I want to throw them out in the open, for your feedback.

[systemd-devel] python - reading the journal

2013-02-03 Thread Steven Hiscocks
Hi, I've been developing a python module for accessing the journal, using the journal API. (https://github.com/kwirk/pyjournalctl) One issue I've had is with 'sd_journal_seek_monotonic_usec'. When called, followed by call to 'sd_journal_next', I end up at the start of the journal. If I set

Re: [systemd-devel] python - reading the journal

2013-02-03 Thread Zbigniew Jędrzejewski-Szmek
On Sun, Feb 03, 2013 at 09:18:28PM +, Steven Hiscocks wrote: Hi, I've been developing a python module for accessing the journal, using the journal API. (https://github.com/kwirk/pyjournalctl) Great! Have you thought about including it in the systemd repo, once interface nad implementation

Re: [systemd-devel] python - reading the journal

2013-02-03 Thread David Strauss
I second the interest in committing this to the existing Python support once polished. On Sun, Feb 3, 2013 at 6:07 PM, Zbigniew Jędrzejewski-Szmek zbys...@in.waw.pl wrote: On Sun, Feb 03, 2013 at 09:18:28PM +, Steven Hiscocks wrote: Hi, I've been developing a python module for accessing