From 190378b48f0e9b5d946789a71aa57d23d509db69 Mon Sep 17 00:00:00 2001 From: Roy Portas Date: Tue, 7 Mar 2017 16:29:41 +1000 Subject: [PATCH 1/3] Disabled configuration saving in configuration files --- code/tutorlib/config/configuration.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/code/tutorlib/config/configuration.py b/code/tutorlib/config/configuration.py index 92723fb..24164e0 100644 --- a/code/tutorlib/config/configuration.py +++ b/code/tutorlib/config/configuration.py @@ -100,6 +100,9 @@ def load_config(): } for section, options in cfg_dict.items() } + # Overwrite the store credentials + cfg_dict['online']['store_credentials'] = '0' + return Namespace(**cfg_dict) From 2b8abccde0624b424a6af226ba46b19a1c70b642 Mon Sep 17 00:00:00 2001 From: Roy Portas Date: Tue, 7 Mar 2017 17:06:20 +1000 Subject: [PATCH 2/3] Fixed config --- code/tutorlib/config/configuration.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/tutorlib/config/configuration.py b/code/tutorlib/config/configuration.py index 24164e0..72f411d 100644 --- a/code/tutorlib/config/configuration.py +++ b/code/tutorlib/config/configuration.py @@ -101,7 +101,7 @@ def load_config(): } # Overwrite the store credentials - cfg_dict['online']['store_credentials'] = '0' + cfg_dict['online']['store_credentials'] = False return Namespace(**cfg_dict) From c1d18aac293e9c7a0edcccffadc25eba528c42ed Mon Sep 17 00:00:00 2001 From: Roy Portas Date: Wed, 8 Mar 2017 12:09:07 +1000 Subject: [PATCH 3/3] Removed auth checking from installer --- code/MyPyTutor.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/code/MyPyTutor.py b/code/MyPyTutor.py index c29c89e..c4d94d2 100644 --- a/code/MyPyTutor.py +++ b/code/MyPyTutor.py @@ -3,7 +3,7 @@ import sys from argparse import ArgumentParser -ALLOWED_VERSIONS = [(3,6)] #[(3, 5), (3, 4)] +ALLOWED_VERSIONS = [(3, 6)] # [(3, 5), (3, 4)] if sys.version_info.major == 3: from getpass import getpass @@ -16,7 +16,7 @@ DEFAULT_CONFIG = { 'online': { - 'store_credentials': True, + 'store_credentials': False, 'username': '', }, 'tutorials': { @@ -726,11 +726,14 @@ def main(): update_default_tutorial_package(force_update=args.force_update_tutorials) # try to log the user in automatically + """ username, password = try_get_credentials() if username is not None: web_api = try_login(username, password) else: web_api = None + """ + web_api = None if web_api is not None: synchronise_problems(web_api)