Uploaded image for project: 'Qt for Python'
  1. Qt for Python
  2. PYSIDE-1361

pyside2-uic.exe generated incorrectly encoded .py file

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Out of scope
    • Not Evaluated
    • None
    • None
    • PySide
    • None

    Description

      I keep copy of pyside2-uic.exe in my ./tools folder and .ui file in ./res as you can see below

      .\tools\pyside2-uic.exe .\res\layout.ui > .\res\layout.py

      First line of generated file is

      # -*- coding: utf-8 -*-

      But created file is UTF-16 LE and this is because i used PowerShell. After manually saving as UTF-8 everything works fine.

      My suggestion is - if this program specifies encoding in the output string it certainly would be better to force it by creating output file (with path specified as an argument) instead of using ">" pipe for saving the output.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            crmaurei Cristian Maureira-Fredes
            tomaszu97 Tomasz Jakubowski
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes