Try/remote post hash#5
Open
Deco354 wants to merge 9 commits intofeature/conflict-resolution-dialogfrom
Open
Conversation
If we check if the post has a revision first the yellow revision color will be applied.
This is to persistently save a hash of the last remote update received in order to tell when an update has new content.
The logic previously here was extract to a separate class so other objects can utilize the hashing logic previously within this AbstractPost extension.
diegoreymendez
suggested changes
Oct 28, 2020
There was a problem hiding this comment.
Hey @Deco354. Right now this PR doesn't let me test the changes without first merging the changes in WordPressKit from your other PR.
Can you adjust the podfile so this PR can be tested using the modifications of WordPressKit before merging them?
Thanks!
These can now be found within SHAHasher.m
diegoreymendez
suggested changes
Oct 30, 2020
diegoreymendez
left a comment
There was a problem hiding this comment.
@Deco354 - I just tried running the first test case, but I'm getting a crash. From what I could see it's related to one of the changes in this PR.
Can you check it out?
Owner
Author
Owner
Author
|
Ah thank you nice catch. |
This file contains hidden or 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
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.

Part of Conflict Resolution Dialog Issue
DO NOT MERGE
Blocked awaiting WordPressKit PR enabling RemotePost hashing.
Description
At present we check whether a remote post has been updated by checking its
dateModifiedproperty. This isn't a fool proof method of checking this so the hashing logic withinAbstractPosthas been extracted so it can be used byRemotePostwithin WordPressKit.This PR
lastRemoteUpdateHashlastRemoteUpdateHashlastRemoteUpdateHashAbstractPostto use the newSHAHasherclass within WordPressKitBasic Test cases
1. Local Autosave Draft vs Remote Update
Reproduction Steps
Desired outcomes:
2. Local Autosave Publication vs Remote Update
Reproduction Steps
Desired Outcome
3. Remote autosave vs Local Autosave Draft
Reproduction Steps
Desired Outcome
PR submission checklist:
RELEASE-NOTES.txtif necessary.