Templates don't load in Confluence Databases if any of them contain blank/null labels.

XMLWordPrintable

    • Severity 3 - Minor

      Issue Summary

      1. In Confluence Database, we can add/specify templates in the "Field settings" for Page link fields.
      2. If any of the templates in Confluence contain any blank, "", labels, the templates will not load.

      Steps to Reproduce

      1. Create a new Confluence database, with a Page link column.
      2. In the field settings for this, click on the dropdown under Page templates (optional)
      3. Assuming that there are any templates in the site with blank/null labels, this dropdown will fail to load any templates.
      4. This network request will fail with the response below;
        • https://<SITE-NAME>.atlassian.net/wiki/rest/api/template/page?expand=&limit=200
        • {
              "statusCode": 400,
              "message": "java.lang.IllegalArgumentException: Label name cannot be blank"
          }
      5. The issue appears to be with the templates itself, and not with Database, as we won't be able to get a response when visiting this URL directly, if there's any blank/null labels.
        • https://<SITE-NAME>.atlassian.net/wiki/rest/api/template/page
        • This should return a list of templates on the site if we're not hitting into this issue.

      Expected Results

      • Null or blank labels, on any templates should not prevent the templates from being fetched.

      Actual Results

      • This request fails with the error below;
      • https://<SITE-NAME>.atlassian.net/wiki/rest/api/template/page?expand=&limit=200
        • {
              "statusCode": 400,
              "message": "java.lang.IllegalArgumentException: Label name cannot be blank"
          }

      Workaround

      • Currently there is no known workaround for this behavior. A workaround will be added here when available

        1. Field_Settings.png
          50 kB
          Sattesh M

            Assignee:
            Matthew Phua
            Reporter:
            Sattesh M
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: