]> git.ipfire.org Git - location/libloc.git/blobdiff - src/python/location-query.in
python: Correctly set log level for root logger
[location/libloc.git] / src / python / location-query.in
index fb695b0821233138f569a970eb6b4407a0d22063..85d1cbf82ac41414d3d624cc0fd209f816df0ff8 100644 (file)
@@ -204,6 +204,10 @@ class CLI(object):
 
                args = parser.parse_args()
 
+               # Enable debug logging
+               if args.debug:
+                       location.logger.set_level(logging.DEBUG)
+
                # Print usage if no action was given
                if not "func" in args:
                        parser.print_usage()