public inbox for cygwin-apps-cvs@sourceware.org
help / color / mirror / Atom feed
* [calm - Cygwin server-side packaging maintenance script] branch master, updated. 20171008-10-gbb18b84
@ 2017-11-06 14:08 jturney
0 siblings, 0 replies; only message in thread
From: jturney @ 2017-11-06 14:08 UTC (permalink / raw)
To: cygwin-apps-cvs
https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=bb18b8449ae04431c1b88e53e08a3491c031e67a
commit bb18b8449ae04431c1b88e53e08a3491c031e67a
Author: Jon Turney <jon.turney@dronecode.org.uk>
Date: Sun Nov 5 20:07:10 2017 +0000
Fix test: stability level not being set correctly, when less than curr:
When using a test: label in version hints (rather than specifying a test:
version in override.hint), the test: stability level wasn't being assigned
correctly, if it was a lower version than curr:
https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=f24cdc3b76929626ea2e6dfe3b8c94744672ab0a
commit f24cdc3b76929626ea2e6dfe3b8c94744672ab0a
Author: Jon Turney <jon.turney@dronecode.org.uk>
Date: Sun Nov 5 19:43:31 2017 +0000
Remove some unneeded parts of previous commit
Diff:
---
calm/package.py | 12 ++++++++++--
1 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/calm/package.py b/calm/package.py
index 610671a..fc0d7f4 100755
--- a/calm/package.py
+++ b/calm/package.py
@@ -25,7 +25,7 @@
# utilities for working with a package database
#
-from collections import defaultdict, OrderedDict
+from collections import defaultdict
import copy
import difflib
import hashlib
@@ -551,6 +551,14 @@ def validate_packages(args, packages):
if packages[p].override_hints[l] is not None:
packages[p].stability[l] = packages[p].override_hints[l]
+ l = 'test'
+ if l not in packages[p].stability:
+ for v in sorted(packages[p].vermap.keys(), key=lambda v: SetupVersion(v), reverse=True):
+ if 'test' in packages[p].version_hints[v]:
+ packages[p].stability[l] = v
+ packages[p].version_hints[v][l] = ''
+ break
+
# the package must have some versions
if not packages[p].stability:
logging.error("no versions at any stability level for package '%s'" % (p))
@@ -797,7 +805,7 @@ def write_setup_ini(args, packages, arch):
# next put any other versions
#
# these [prev] or [test] sections are superseded by the final ones.
- for i, version in enumerate(sorted(packages[p].vermap.keys(), key=lambda v: SetupVersion(v), reverse=True)):
+ for version in sorted(packages[p].vermap.keys(), key=lambda v: SetupVersion(v), reverse=True):
# ignore versions which should have been removed by stale
# package removal
if not (set(['install', 'source']) & set(packages[p].vermap[version])):
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-11-06 14:08 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-11-06 14:08 [calm - Cygwin server-side packaging maintenance script] branch master, updated. 20171008-10-gbb18b84 jturney
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).