[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechani
From: |
Maxime Petazzoni |
Subject: |
Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism |
Date: |
Wed, 13 Jan 2010 16:36:52 +0100 |
User-agent: |
Mutt/1.5.20 (2009-06-14) |
Hi,
* David MENTRE <address@hidden> [2010-01-13 16:24:49]:
> 2010/1/13 Maxime Petazzoni <address@hidden>:
> > def is_done(self):
> > - return self.status == 2
> > + return self.status >= 2
>
> You are changing the semantics of is_done (which was previously "done
> with files"). Anyway, even if you decide to change the semantics of
> is_done, I would rather write:
> self.status == 2 || self.status == 3
> In the sake of prevention against further changes.
I don't think I'm really changing the semantics of is_done. The job is
still done when status == 3. I agree that self.status == 2 ||
self.status == 3 might be better, but it doesn't make a big difference
right now and we can fix it later when adding other statuses.
I'll submit a patch later with that specific change.
> > def is_done_ok(self):
> > return self.is_done() and self.resultmsg == "ok"
>
> In that case, we could have a job is_done==True, resultmsg=="ok" but
> no file (if status == 3).
Yes, as I said I'm not changing the semantics of is_done. If status ==
3, the job is still done, and is_done_ok can still be a successfully
completed job, but its files were removed later.
- Maxime
--
Maxime Petazzoni <http://www.bulix.org>
``One by one, the penguins took away my sanity.''
Linux kernel and software developer at MontaVista Software
signature.asc
Description: Digital signature
- [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, Maxime Petazzoni, 2010/01/13
- Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, David MENTRE, 2010/01/13
- Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, Maxime Petazzoni, 2010/01/13
- Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, David MENTRE, 2010/01/13
- [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, Maxime Petazzoni, 2010/01/13
- Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, David MENTRE, 2010/01/13
- Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, David MENTRE, 2010/01/13
- Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, Maxime Petazzoni, 2010/01/13
- Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism,
Maxime Petazzoni <=
Re: [Maposmatic-dev] [PATCH maposmatic] Improve the file cleanup mechanism, David MENTRE, 2010/01/13