public inbox for gentoo-portage-dev@lists.gentoo.org
 help / color / mirror / Atom feed
Search results ordered by [date|relevance]  view[summary|nested|Atom feed]
thread overview below | download: 
* [gentoo-portage-dev] [PATCH 2/2] Use portage.const.TIMESTAMP_FORMAT where appropriate
  @ 2013-11-29 18:02 99% ` SebastianLuther
  0 siblings, 0 replies; 1+ results
From: SebastianLuther @ 2013-11-29 18:02 UTC (permalink / raw
  To: gentoo-portage-dev

From: Sebastian Luther <SebastianLuther@gmx.de>

---
 pym/_emerge/actions.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/pym/_emerge/actions.py b/pym/_emerge/actions.py
index 86d67d2..19268cb 100644
--- a/pym/_emerge/actions.py
+++ b/pym/_emerge/actions.py
@@ -40,6 +40,7 @@ from portage import eapi_is_supported, _encodings, _unicode_decode
 from portage.cache.cache_errors import CacheError
 from portage.const import GLOBAL_CONFIG_PATH, VCS_DIRS, _DEPCLEAN_LIB_CHECK_DEFAULT
 from portage.const import SUPPORTED_BINPKG_FORMATS
+from portage.const import TIMESTAMP_FORMAT
 from portage.dbapi.dep_expand import dep_expand
 from portage.dbapi._expand_new_virt import expand_new_virt
 from portage.dep import Atom
@@ -2282,7 +2283,7 @@ def _sync_repo(emerge_config, repo):
 		if content:
 			try:
 				mytimestamp = time.mktime(time.strptime(content[0],
-					"%a, %d %b %Y %H:%M:%S +0000"))
+					TIMESTAMP_FORMAT))
 			except (OverflowError, ValueError):
 				pass
 		del content
@@ -2511,7 +2512,7 @@ def _sync_repo(emerge_config, repo):
 				if content:
 					try:
 						servertimestamp = time.mktime(time.strptime(
-							content[0], "%a, %d %b %Y %H:%M:%S +0000"))
+							content[0], TIMESTAMP_FORMAT))
 					except (OverflowError, ValueError):
 						pass
 				del mycommand, mypids, content
-- 
1.8.1.5



^ permalink raw reply related	[relevance 99%]

Results 1-1 of 1 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2013-11-29 18:02     [gentoo-portage-dev] [PATCH 1/2] egencache: --write-timestamp to create metadata/timestamp.chk SebastianLuther
2013-11-29 18:02 99% ` [gentoo-portage-dev] [PATCH 2/2] Use portage.const.TIMESTAMP_FORMAT where appropriate SebastianLuther

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