Uploaded image for project: 'Hue'
  1. Hue
  2. HUE-5509

[notebook] Properly handle unicode characters in log output in jdbc connector

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.11.0
    • Fix Version/s: 4.0.0
    • Component/s: app.editor
    • Labels:
      None

      Description

      This bug is similar with https://issues.cloudera.org/browse/HUE-4815.
      The error which is "'ascii' codec can't encode characters in position XXX: ordinal not in range(128)" is raised in the notebook using JDBC configuration.

      BTW, I solved this issue by adding "from desktop.lib.i18n import smart_str" and modifying "message = force_unicode(str(e))" to "message = force_unicode(smart_str(e))" in the jdbc.py(/usr/local/hue/desktop/libs/notebook/src/notebook/connectors/jdbc.py) file.

        Attachments

          Activity

            People

            • Assignee:
              adrianyavorskyy Adrian Yavorskyy
              Reporter:
              mungeol Mungeol Heo
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: