-
Notifications
You must be signed in to change notification settings - Fork 9
Push v2 integration #262
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
base: master
Are you sure you want to change the base?
Push v2 integration #262
Conversation
- attempts of failing chunks =- init for sync_project
- fixing update chunks for files with the same checksum - added minimal version of sync command
Introduce mapping based on chunk_id (generated by client) and server_chunk_id generated by server.
- +v1 is raising error just from push start (push_project_async), because there are not chunks caches
max 10GB of non versioned files max 5GB of versioned files
…r chunks cache on v1 supported server (#276)
- change version of python in tests
- final commit probably
Upload changes limits
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.
Looks very good 🚀
mergin/client_push.py
Outdated
mc.post( | ||
f"/v2/projects/{project_id}/versions", | ||
{**data, "check_only": True}, | ||
{"Content-Type": "application/json"}, |
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.
do we need to set these headers here, as they are most of the time json?
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.
yes, this is how the post is created
if headers.get("Content-Type", None) == "application/json":
data = json.dumps(data, cls=DateTimeEncoder).encode("utf-8")
But I can move it to some const
from .utils import is_versioned_file | ||
from .common import MAX_UPLOAD_MEDIA_SIZE, MAX_UPLOAD_VERSIONED_SIZE | ||
|
||
MAX_UPLOAD_CHANGES = 100 |
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.
maybe move next to others?
Added ➕
Updated tests:
❗
Chunks cache
Logging following to logs
Retry of sync_project
Workflow
