opengisch / QField

A simplified touch optimized interface for QGIS
http://www.qfield.org
GNU General Public License v2.0
809 stars 224 forks source link

Contstraint-checking-behaviour between QGIS and QFIELD sometimes different #5110

Closed koenigherford closed 6 months ago

koenigherford commented 6 months ago

Describe the issue

Contstraint-checking-behaviour between QGIS and QFIELD sometimes different.

It's not easy to reproduce. Some constraints are working. Some are not....

In my example project you can see a constraint violation in QFIELD but not in QGIS although data / project is the same grafik

During export-process you can see a Stacktrace-warning before there is a "export-success" notice on qgis-desktop:

"Ein Fehler trat bei der Ausführung von Python-Code auf: 

IndexError: list index out of range 
Traceback (most recent call last):
  File "C:\Users\B2306704\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\qfieldsync\libqfieldsync.whl\libqfieldsync\offline_converter.py", line 568, in _on_offline_editing_next_layer
    layer_name=self.__offline_layer_names[layer_index - 1]
IndexError: list index out of range

Python-Version: 3.9.18 (heads/master:5eba59e, Feb  1 2024, 20:02:10) [MSC v.1929 64 bit (AMD64)] 
QGIS-Version: 3.36.0-Maidenhead Maidenhead, 09951dc0 

Python-Pfad:
C:/OSGeo4W/apps/qgis/./python
C:/Users/B2306704/AppData/Roaming/QGIS/QGIS3\profiles\default/python
C:/Users/B2306704/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins
C:/OSGeo4W/apps/qgis/./python/plugins
C:\OSGeo4W\apps\grass\grass83\etc\python
C:\Windows\system32
C:\OSGeo4W\bin\python39.zip
C:\OSGeo4W\apps\Python39\DLLs
C:\OSGeo4W\apps\Python39\lib
C:\OSGeo4W\bin
C:\OSGeo4W\apps\Python39
C:\OSGeo4W\apps\Python39\lib\site-packages
C:\OSGeo4W\apps\Python39\lib\site-packages\win32
C:\OSGeo4W\apps\Python39\lib\site-packages\win32\lib
C:\OSGeo4W\apps\Python39\lib\site-packages\Pythonwin
C:/Users/B2306704/AppData/Roaming/QGIS/QGIS3\profiles\default/python
C:\Users\B2306704\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins\qfieldsync\libqfieldsync.whl
C:\Users\B2306704\AppData\Roaming\QGIS\QGIS3\profiles\default\python\plugins
C:/Users/B2306704/AppData/Roaming/QGIS/QGIS3/profiles/default/python/plugins/DataDrivenInputMask
C:/Users/B2306704/AppData/Local/Temp/tmpsaa9ei6m"

Reproduction steps

Steps to reproduce the behavior: test with sample projekt on qgis qfield

Expected behavior

same behavior on every platform

Observed behavior

different constraint check-results between qgis / qfield

Screenshots and GIFs

grafik

[Please also attach additional files if a specific project/dataset is useful to investigate the problem.] test_array_qfield_3.zip

Desktop (please complete the following information)

Mobile (please complete the following information)

nirvn commented 6 months ago

@koenigherford , thanks for the report. The issue has been addressed in this PR (https://github.com/opengisch/QField/pull/5113) and should be released in a forthcoming point release as soon as possible.