Skip to content

Synchronization error when custom photo name string contains space at start of the filename #4022

@RastoHu

Description

@RastoHu

Description
If a space is located in the "middle" of a custom photo name string, the mobile app encounters a synchronization error when trying to sync to the server. This issue occurs when the space is not at the beginning or end of the string, but at the start of the filename.

Environment
Staging

Application (+ app version, build, operating system)

  • Android mobile app, replicable also on iOS devices
  • App build: 687611

Steps to reproduce

  1. Open QGIS with Mergin Maps plugin
  2. Configure custom photo name setting with a string containing a space at the start of the filename, for example:
    'sa ni*tized/' + ' f<i>l?e:n\"a:m|e.ext" ' + '-' || now()
  3. Open Mergin Maps mobile app on a mobile device
  4. Record a feature with a photo using this custom naming configuration
  5. Attempt to synchronize the project to the server

Actual results

  • Synchronization fails when space appears at the start of the filename of the custom photo name string
  • Example failing case: ' f
  • Error occurs during sync process to server

Expected results

  • Custom photo name should be properly sanitized when the file name starts with a space
  • All valid custom photo name configurations should sync successfully

Screenshots or logs

Conclusion
Created by GitHub Copilot and supervised by a human test analyst.

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions