[gnome-builder] flatpak: Print error when parsing manifest fails



commit 8e4ea70ebd6f99897a8406a7233a1f7493cd5fff
Author: Matthew Leeds <mleeds redhat com>
Date:   Wed Feb 15 18:36:16 2017 -0600

    flatpak: Print error when parsing manifest fails
    
    When checking source trees for flatpak manifests, if there's a parsing
    error we should print a warning to make it easier for people to debug
    (at least if they run Builder from the command line).

 .../flatpak/gbp-flatpak-configuration-provider.c   |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/plugins/flatpak/gbp-flatpak-configuration-provider.c 
b/plugins/flatpak/gbp-flatpak-configuration-provider.c
index 32d7c78..ec84441 100644
--- a/plugins/flatpak/gbp-flatpak-configuration-provider.c
+++ b/plugins/flatpak/gbp-flatpak-configuration-provider.c
@@ -749,7 +749,10 @@ check_dir_for_manifests (GFile         *directory,
       parser = json_parser_new ();
       json_parser_load_from_file (parser, path, &local_error);
       if (local_error != NULL)
-        continue;
+        {
+          g_warning ("Error parsing potential flatpak manifest %s: %s", path, local_error->message);
+          continue;
+        }
 
       root_node = json_parser_get_root (parser);
       if (!JSON_NODE_HOLDS_OBJECT (root_node))


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]