AUDIT REPORT Qt5 → Qt6 / QGIS3 → QGIS4
====================================================================================================

1. GLOBAL SUMMARY
----------------------------------------------------------------------------------------------------
Scanned folder              : C:\Users\franc\AppData\Roaming\QGIS\QGIS4\profiles\default\python\plugins\Qgis_PostGIS_Sync
Python files found          : 45
Modified files              : 1
Files with fixes            : 5
Files with findings         : 0
Automatic replacements      : 1
Critical findings (ERROR)   : 0
Warnings (WARNING)          : 0

qt_compat source            : C:\Users\franc\AppData\Roaming\QGIS\QGIS4\profiles\default\python\plugins\scan_qt6_compat\qt_compat.py
qt_compat destination       : C:\Users\franc\AppData\Roaming\QGIS\QGIS4\profiles\default\python\plugins\Qgis_PostGIS_Sync\qt_compat.py
qt_compat status            : copied

2. QT5 → QT6 STATISTICS
----------------------------------------------------------------------------------------------------
2.1 Automatic replacements by category

  - Centralize lupdate helper: 4
  - QStyle.SP_DialogHelpButton: 1

2.2 Detailed fixes by applied rule

  - Add Qt5/Qt6-safe TS generation helper: 4
  - Remove local helper _qt_compat_build_ts_generator_command: 4
  - Enum/token replacement: 1

3. REMAINING FINDINGS SUMMARY
----------------------------------------------------------------------------------------------------
No remaining findings.

4. FILE-BY-FILE AUDIT
----------------------------------------------------------------------------------------------------

FILE: admin_plugin.py
====================================================================================================
Applied fixes       : 1
Findings ERROR      : 0
Findings WARNING    : 0

4.1 Applied fixes

Line: 434
Rule: Enum/token replacement
Before:
    QStyle.SP_DialogHelpButton
After:
    STYLE_SP_DIALOG_HELP

4.2 Remaining findings

No remaining findings.


FILE: classified_browser.py
====================================================================================================
Applied fixes       : 2
Findings ERROR      : 0
Findings WARNING    : 0

4.1 Applied fixes

Line: 1
Rule: Add Qt5/Qt6-safe TS generation helper
Before:
    [missing helper]
After:
    def _qt_compat_build_ts_generator_command(...): ...

Line: 16
Rule: Remove local helper _qt_compat_build_ts_generator_command
Before:
    def _qt_compat_build_ts_generator_command():
        import shutil
        import sys
        from pathlib import Path
        from qgis.PyQt import QtCore
    
        qt_major = int(QtCore.QT_VERSION_STR.split(".")[0])
    
        if qt_major < 6:
            return [sys.executable, "-m", "PyQt5.pylupdate_main"]
    
        for candidate in ("lupdate", "lupdate6"):
    … [29 ligne(s) supplémentaire(s) omise(s)]
After:
    

4.2 Remaining findings

No remaining findings.


FILE: core\carto2_i18n.py
====================================================================================================
Applied fixes       : 2
Findings ERROR      : 0
Findings WARNING    : 0

4.1 Applied fixes

Line: 1
Rule: Add Qt5/Qt6-safe TS generation helper
Before:
    [missing helper]
After:
    def _qt_compat_build_ts_generator_command(...): ...

Line: 4
Rule: Remove local helper _qt_compat_build_ts_generator_command
Before:
    def _qt_compat_build_ts_generator_command():
        import shutil
        import sys
        from pathlib import Path
        from qgis.PyQt import QtCore
    
        qt_major = int(QtCore.QT_VERSION_STR.split(".")[0])
    
        if qt_major < 6:
            return [sys.executable, "-m", "PyQt5.pylupdate_main"]
    
        for candidate in ("lupdate", "lupdate6"):
    … [29 ligne(s) supplémentaire(s) omise(s)]
After:
    

4.2 Remaining findings

No remaining findings.


FILE: core\carto2_translation_sources.py
====================================================================================================
Applied fixes       : 2
Findings ERROR      : 0
Findings WARNING    : 0

4.1 Applied fixes

Line: 1
Rule: Add Qt5/Qt6-safe TS generation helper
Before:
    [missing helper]
After:
    def _qt_compat_build_ts_generator_command(...): ...

Line: 2
Rule: Remove local helper _qt_compat_build_ts_generator_command
Before:
    def _qt_compat_build_ts_generator_command():
        import shutil
        import sys
        from pathlib import Path
        from qgis.PyQt import QtCore
    
        qt_major = int(QtCore.QT_VERSION_STR.split(".")[0])
    
        if qt_major < 6:
            return [sys.executable, "-m", "PyQt5.pylupdate_main"]
    
        for candidate in ("lupdate", "lupdate6"):
    … [29 ligne(s) supplémentaire(s) omise(s)]
After:
    

4.2 Remaining findings

No remaining findings.


FILE: help_content.py
====================================================================================================
Applied fixes       : 2
Findings ERROR      : 0
Findings WARNING    : 0

4.1 Applied fixes

Line: 1
Rule: Add Qt5/Qt6-safe TS generation helper
Before:
    [missing helper]
After:
    def _qt_compat_build_ts_generator_command(...): ...

Line: 5
Rule: Remove local helper _qt_compat_build_ts_generator_command
Before:
    def _qt_compat_build_ts_generator_command():
        import shutil
        import sys
        from pathlib import Path
        from qgis.PyQt import QtCore
    
        qt_major = int(QtCore.QT_VERSION_STR.split(".")[0])
    
        if qt_major < 6:
            return [sys.executable, "-m", "PyQt5.pylupdate_main"]
    
        for candidate in ("lupdate", "lupdate6"):
    … [29 ligne(s) supplémentaire(s) omise(s)]
After:
    

4.2 Remaining findings

No remaining findings.


5. ANNEX - COMPACT REPLACEMENTS SUMMARY
----------------------------------------------------------------------------------------------------

Centralize lupdate helper : 4 -> remove local _qt_compat_build_ts_generator_command
QStyle.SP_DialogHelpButton : 1 -> STYLE_SP_DIALOG_HELP


====================================================================================================
PLUGIN RELOAD
====================================================================================================
Plugin reloaded: Qgis_PostGIS_Sync
Python code was reloaded.
Plugin marked as enabled in QSettings: Qgis_PostGIS_Sync
Plugin manager metadata reloaded. Close and reopen the Plugins window if it is already open.
UI refresh: processEvents OK | Main window refresh OK | Plugin manager interface update failed: 'QgsPluginManagerInterface' object has no attribute 'update'
If the Plugins window is already open, close and reopen it.
A QGIS restart may still be required for some fields in the plugin manager.
