Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Problem with QT Creator
Qt 6.11 is out! See what's new in the release blog

Problem with QT Creator

Scheduled Pinned Locked Moved Unsolved General and Desktop
1 Posts 1 Posters 314 Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • JM baubetJ Offline
    JM baubetJ Offline
    JM baubet
    wrote on last edited by
    #1

    Hello,
    I am using MAC OS 13.2.1 and Qt Creator 9.0.1
    I have a problem with Qt Creator, and an application in Python and Pyside6. When I launch the application I get the following message:

    09:26:09: Running steps for project AIMLog_2...
    09:26:09: Starting: "/Users/jean-marcbaubet/DevLocal/test/Qt6/bin/pyside6-project" build
    Error parsing /Volumes/Externe/Dev/Qt6/QtQuick/AIMLog_2/main.py: 'Constant' object has no attribute 'id'
    Traceback (most recent call last):
      File "/Users/jean-marcbaubet/DevLocal/test/Qt6/lib/python3.9/site-packages/PySide6/scripts/metaobjectdump.py", line 389, in <module>
        json_data = parse_file(file, context, args.suppress_file)
      File "/Users/jean-marcbaubet/DevLocal/test/Qt6/lib/python3.9/site-packages/PySide6/scripts/metaobjectdump.py", line 349, in parse_file
        visitor.visit(ast_tree)
      File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/ast.py", line 407, in visit
        return visitor(node)
      File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/ast.py", line 415, in generic_visit
        self.visit(item)
      File "/Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/ast.py", line 407, in visit
        return visitor(node)
      File "/Users/jean-marcbaubet/DevLocal/test/Qt6/lib/python3.9/site-packages/PySide6/scripts/metaobjectdump.py", line 181, in visit_ClassDef
        self._parse_class_variable(b)
      File "/Users/jean-marcbaubet/DevLocal/test/Qt6/lib/python3.9/site-packages/PySide6/scripts/metaobjectdump.py", line 296, in _parse_class_variable
        par_type = _python_to_cpp_type(_name(arg))
      File "/Users/jean-marcbaubet/DevLocal/test/Qt6/lib/python3.9/site-packages/PySide6/scripts/metaobjectdump.py", line 59, in _name
        return node.id
    AttributeError: 'Constant' object has no attribute 'id'
    JSONDecodeError: running pyside6-metaobjectdump on /Volumes/Externe/Dev/Qt6/QtQuick/AIMLog_2/main.py: Expecting value: line 1 column 1 (char 0)
    09:26:09: The process "/Users/jean-marcbaubet/DevLocal/test/Qt6/bin/pyside6-project" exited with code 1.
    Error while building/deploying project AIMLog_2 (kit: Qt 6.4.2 for macOS)
    When executing step "Run PySide6 project tool"
    09:26:09: Elapsed time: 00:00.
    

    If I launch the application with the command python3 main.py everything is fine.

    I don't understand what's going on. I have of course edited and saved the main.py file.
    I also checked its content with a hex editor. it start with :

    23 20 54 68 69 73 20 50 79 74 68 6F 6E 20 66 69 6C 65 20 75 73 65 73 20 74 68 65 20 66 6F 6C 6C 6F 77 69 6E 67 20 65 6E 63 6F 64 69 6E 67 3A 20 75 74 66 2D 38 0A 69 6D 70 6F 72 74 20 73 79 73 20 20 23 20 69 6D 70 6F 72 74 20 6F 73 0A 66 72 6F 6D 20 70 61 74 68 6C 69 62 20 69 6D 70 6F 72 74 20 50 61 74 68 0A 0A 66 72 6F 6D 20 50 79 53 69 64 65 36 2E 51 74 47 75 69 20 69 6D 70 6F 72...
    

    Which corresponds to

    # This Python file uses the following encoding: utf-8
    import sys  # import os
    from pathlib import Path
    
    from PySide6.QtGui impor...
    
    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved