mapfish-print icon indicating copy to clipboard operation
mapfish-print copied to clipboard

Get Capabilities `pretty=true` flag encoding issue

Open ltshb opened this issue 1 year ago • 0 comments

Context

MapFish print docker image version: camptocamp/mapfish_print:3195

Describe the bug

When requesting the capabilities with the pretty=true query parameter, the json answer is not correctly encoded in utf-8 as specified in the Content-Type header but in some other encoding. This can be reproduced if the capabilities have a special character, like for example having an attribute copyright with a ©

templates:
#===========================================================================
  "1. A4 landscape": !template
#===========================================================================
    pdfConfig: !pdfConfig &pdfConfig
      title: "A4 Landscape"
      keywords: ["map.geoadmin.ch"]
    reportTemplate: A4_landscape_template.jrxml
    attributes:
      url: !string {}
      copyright: !string &copyright
          default: '© swisstopo'

Without the pretty flag it works fine

ltshb avatar Apr 18 '24 08:04 ltshb