public inbox for gentoo-portage-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-portage-dev] [PATCH] news.py: Check only for major version when parsing
@ 2016-05-18  8:36 Alexander Berntsen
  2016-05-18 15:46 ` Zac Medico
  2016-05-19 10:12 ` [gentoo-portage-dev] [PATCH v2] " Alexander Berntsen
  0 siblings, 2 replies; 9+ messages in thread
From: Alexander Berntsen @ 2016-05-18  8:36 UTC (permalink / raw
  To: gentoo-portage-dev; +Cc: ulm

Only check the major version of news items, as GLEP 42 specifies an
upgrade path for them. Future revisions to news item formats may yield
minor number increments. GLEP 42 further ensures that only
forwards-compatible changes may incur, as incompatible changes demand a
major version increment.

Suggested-by:  Ulrich Müller      <ulm@gentoo.org>
Signed-off-by: Alexander Berntsen <bernalex@gentoo.org>
---
 pym/portage/news.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/pym/portage/news.py b/pym/portage/news.py
index 784ba70..f52d96e 100644
--- a/pym/portage/news.py
+++ b/pym/portage/news.py
@@ -270,7 +270,7 @@ class NewsItem(object):
 			# Optimization to ignore regex matchines on lines that
 			# will never match
 			format_match = _formatRE.match(line)
-			if format_match is not None and format_match.group(1) != '1.0':
+			if format_match is not None and format_match.group(1) != '1.*':
 				invalids.append((i + 1, line.rstrip('\n')))
 				break
 			if not line.startswith('D'):
-- 
2.7.3



^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2016-05-20  9:01 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-05-18  8:36 [gentoo-portage-dev] [PATCH] news.py: Check only for major version when parsing Alexander Berntsen
2016-05-18 15:46 ` Zac Medico
2016-05-18 16:57   ` Alexander Berntsen
2016-05-18 17:04   ` Alexander Berntsen
2016-05-18 19:06     ` Zac Medico
2016-05-18 19:50       ` Alexander Berntsen
2016-05-19 10:12 ` [gentoo-portage-dev] [PATCH v2] " Alexander Berntsen
2016-05-19 14:37   ` Zac Medico
2016-05-20  9:01     ` Alexander Berntsen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox