1 |
W dniu nie, 04.02.2018 o godzinie 13∶48 +0000, użytkownik M. J. Everitt |
2 |
napisał: |
3 |
> On 02/02/18 20:42, Michał Górny wrote[excerpted]: |
4 |
> > index 27a2548c0..cb80f6d66 100644 |
5 |
> > --- a/pym/portage/sync/modules/rsync/__init__.py |
6 |
> > +++ b/pym/portage/sync/modules/rsync/__init__.py |
7 |
> > @@ -109,6 +110,20 @@ class RsyncSync(NewBase): |
8 |
> > writemsg_level("!!! sync-rsync-verify-jobs not a positive integer: %s\n" % (self.verify_jobs,), |
9 |
> > level=logging.WARNING, noiselevel=-1) |
10 |
> > self.verify_jobs = None |
11 |
> > + # Support overriding max age. |
12 |
> > + self.max_age = self.repo.module_specific_options.get( |
13 |
> > + 'sync-rsync-verify-max-age', '') |
14 |
> > + if self.max_age: |
15 |
> > + try: |
16 |
> > + self.max_age = int(self.max_age) |
17 |
> > + if self.max_age < 0: |
18 |
> > + raise ValueError(self.max_age) |
19 |
> > + except ValueError: |
20 |
> > + writemsg_level("!!! sync-rsync-max-age not a non-negative integer: %s\n" % (self.max_age,), |
21 |
> |
22 |
> A beautiful double-negative .. but would read better as "not a positive |
23 |
> integer" or "is a negative integer" .. |
24 |
> |
25 |
|
26 |
Except that neither is correct. Zero is not positive but valid. |
27 |
And the error also covers the case when it's not an integer at all. |
28 |
|
29 |
-- |
30 |
Best regards, |
31 |
Michał Górny |