-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tracking setup for mobile application #489
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tomasMizera
reviewed
Apr 26, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @alexbruy 🎉
I have few suggestions:
- let's set
fid
field to be hidden - let's have only 2 decimal places in the
total_distance
I also found this issue:
- make basic project through plugin
- add tracking
- add new feature to tracking layer (in plugin)
- after saving the layer, this feature is not visible on map
- I do not even see it in attribute table (maybe missing commit to layer?)
then, I could not sync the project because of
2023-04-26T16:13:38 WARNING Traceback (most recent call last):
File "/Users/tomasmizera/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/Mergin/plugin.py", line 411, in current_project_sync
self.manager.project_status(self.mergin_proj_dir)
File "/Users/tomasmizera/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/Mergin/projects_manager.py", line 168, in project_status
pull_changes, push_changes, push_changes_summary = self.mc.project_status(project_dir)
File "/Users/tomasmizera/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/Mergin/mergin/client.py", line 826, in project_status
push_changes = mp.get_push_changes()
File "/Users/tomasmizera/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/Mergin/mergin/merginproject.py", line 327, in get_push_changes
size, checksum = do_sqlite_checkpoint(self.fpath(file["path"]), self.log)
File "/Users/tomasmizera/Library/Application Support/QGIS/QGIS3/profiles/default/python/plugins/Mergin/mergin/utils.py", line 93, in do_sqlite_checkpoint
cursor.execute("PRAGMA wal_checkpoint=FULL")
sqlite3.OperationalError: disk I/O error
I could use it in MM mobile though :)
User can enable or disable tracking as well as choose desired tracking precision. On the first activation plugin will automatically create a new GPKG with the tracking layer and add it to the project.
This reverts commit c627ed6.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add a new group to the Mergin project properties widget to setup tracking. User can activate/deactivate tracking and select desired tracking precision.
![image](https://user-images.githubusercontent.com/776954/229108002-6ba3dc1a-60ca-46a0-90c8-c4f8243e42d1.png)
Tracking configuration then saved in the QGIS project file and will be used by mobile application.
If this is a first activation of tracking a new GPKG file called
tracking_layer.gpkg
with aLineStringZM
layer will be created in the Mergin project folder and added to the project. Note, we require project to be saved before enabling tracking as otherwise we can not determine where to put GPKG file.