From 485ddd74369bab41e2d8a5fb5a040a49415efa9c Mon Sep 17 00:00:00 2001 From: Elias Dorneles Date: Sun, 21 Jun 2015 01:51:23 -0300 Subject: [PATCH] minor py3 compatibility fixes --- shub/login.py | 2 +- shub/tool.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/shub/login.py b/shub/login.py index c570d1bc..55ec73b5 100644 --- a/shub/login.py +++ b/shub/login.py @@ -10,7 +10,7 @@ def cli(context): if key and is_valid_key(key): descriptor = os.open( NETRC_FILE, - os.O_CREAT | os.O_RDWR | os.O_APPEND, 0600) + os.O_CREAT | os.O_RDWR | os.O_APPEND, 0o600) with os.fdopen(descriptor, 'a+') as out: line = 'machine scrapinghub.com login {0} password ""\n'.format(key) out.write(line) diff --git a/shub/tool.py b/shub/tool.py index 443ee79f..31c37a95 100644 --- a/shub/tool.py +++ b/shub/tool.py @@ -26,7 +26,7 @@ def cli(): "version": [], } -for command, modules in module_deps.iteritems(): +for command, modules in module_deps.items(): m = missing_modules(*modules) if m: cli.add_command(missingmod_cmd(m), command)