aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--quarg/main.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/quarg/main.py b/quarg/main.py
index 5e0aaf8..36e6f92 100644
--- a/quarg/main.py
+++ b/quarg/main.py
@@ -120,14 +120,14 @@ def time_query(query):
return rows, end - start
def main():
+ args = cli.parse_args()
+ check_args(args)
+
config = get_config()
if not config.has_option('Database', 'url'):
errx('No database URL set in config file.')
- args = cli.parse_args()
- check_args(args)
-
engine = create_engine(config.get('Database', 'url'), echo=args.debug)
session = Session(bind=engine)