Skip to content
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

Android bookmarks moved inside a folder doesn't sync well with desktop #2798

Closed
srirambv opened this issue Jan 3, 2019 · 10 comments
Closed

Comments

@srirambv
Copy link
Contributor

srirambv commented Jan 3, 2019

Description

Android bookmarks moved inside a folder doesn't sync well with desktop

Devices

Sync device 1 - Ubuntu running 0.59.14 _ Sync chain creator
Sync device 2 - Samsung Tab running 1.0.72(sync 2) build

Steps to Reproduce

  1. Enable sync on a clean profile(0.59.14)
  2. Import a bookmark html file
  3. Scan QR code using Android build running 1.0.72
  4. Wait for the sync process to start on Android
  5. Rename Imported folder to Imported HTML on Android (doesnt matter how many bookmarks are sync'd), folder gets renamed on both devices
  6. Add 3-4 bookmarks on Android and move them into a folder created on Android itself
  7. Wait till the sync process is complete, some bookmarks from Android remain on bc toolbar (see screenshots)

Actual result:

image

20190103_063401

Expected result:

All bookmarks moved inside a folder on Android should have the same folder structure post sync on desktop browser

Reproduces how often:

I was able to reproduce this 3 times but not with the same bookmarks on the root folder

Brave version (brave://version info)

Brave 0.59.14 Chromium: 72.0.3626.28 (Official Build) beta(64-bit)
Revision 997b1040b63bac324e815797ba52be0cd8f616ed-refs/branch-heads/3626@{#461}
OS Linux

Reproducible on current release:

  • Does it reproduce on brave-browser dev/beta builds?
    Yes on beta

Website problems only:

  • Does the issue resolve itself when disabling Brave Shields?
    N/A
  • Is the issue reproducible on the latest version of Chrome?
    N/A

Additional Information

cc: @brave/legacy_qa @darkdh @AlexeyBarabash
Follow up to #2447

@srirambv srirambv added this to the 1.x Backlog milestone Jan 3, 2019
@LaurenWags
Copy link
Member

Reproduced with macOS/Android sync (1.0.72 (sync1) for Android)

Brave 0.59.14 Chromium: 72.0.3626.28 (Official Build) beta(64-bit)
Revision 997b1040b63bac324e815797ba52be0cd8f616ed-refs/branch-heads/3626@{#461}
OS Mac OS X

@srirambv srirambv added the priority/P2 A bad problem. We might uplift this to the next planned release. label Jan 15, 2019
@srirambv
Copy link
Contributor Author

@bbondy @rebron this one needs to be fixed before the release goes out. Pretty bad as its reproduced on mac and Linux

@AlexeyBarabash
Copy link
Contributor

@srirambv
What folder is to move to on step 6:
6. Add 3-4 bookmarks on Android and move them into a folder created on Android itself
?

@srirambv
Copy link
Contributor Author

@AlexeyBarabash the step is to add 3 bookmarks on Android at root folder and then create a new Bookmark folder and then move those bookmarks into it.

@SergeyZhukovsky
Copy link
Member

@srirambv @LaurenWags have you guys checked the same desktop to desktop? It will help us to determine a problem platform.

@SergeyZhukovsky
Copy link
Member

In such issues it would be very helpful as well to attach a third device at the end of the process. Just to check how really the data stored in the sync chain. It would be really obvious to see what platform replicates it wrong.

@srirambv
Copy link
Contributor Author

@SergeyZhukovsky I couldn't reproduce with desktop-desktop. The bookmarks are put in correct folders. I could however reproduce this on Android-Desktop again. I will try with Desktop-Andriod-Desktop and update here

I think there might be another issue with bookmarks(may be expected) but i'll log it separately.

@AlexeyBarabash
Copy link
Contributor

Cannot reproduce the issie with Android 1.0.72 (sync1) and Brave-core master 0.61.0, but see another issue.
Tried options:

  1. All as specified in ticket, ~1000 bookmarks file, no internet speed restriction - I could not rename Imported=>Imported HTML and create/move 3-4 bookmarks prior sync finished; finally all were as expected;

  2. ~1000 bookmarks file, internet speed restricted to 512kb/s (64kB/s) - I could rename Imported=>Imported HTML prior sync finished, but create/move 3-4 bookmarks after; finally all were as expected;

  3. ~5000 bookmarks file, internet speed restricted to 512kb/s (64kB/s) - I could rename Imported=>Imporetd HTML and create/move 3-4 bookmarks prior sync finished; waited ~20 minutes, some bookmarks appeared on brave-core in a root of bookmarks bar folder, but finally they were moved inside of Android, all were as expected;

  4. ~5000 bookmarks file, internet speed is not restricted - got ANRs while trying to create bookmarks on Android before move into Android folder.

@AlexeyBarabash
Copy link
Contributor

After re-launch Android app, got failed DCHECK at

[23065:23065:0116/150533.729910:FATAL:bookmark_model.cc(611)] Check failed: false. 
#0 0x7eff7f0814dd base::debug::StackTrace::StackTrace()
#1 0x7eff7ed72f6a base::debug::StackTrace::StackTrace()
#2 0x7eff7ede4c4b logging::LogMessage::~LogMessage()
#3 0x55b2c91832e1 bookmarks::BookmarkModel::AddURLWithCreationTimeAndMetaInfo()
#4 0x55b2c91831c9 bookmarks::BookmarkModel::AddURL()
#5 0x55b2c47d1cc7 brave_sync::BookmarkChangeProcessor::ApplyChangesFromSyncModel()
#6 0x55b2c47c1c21 brave_sync::BraveSyncServiceImpl::OnResolvedSyncRecords()
#7 0x55b2c4f45108 extensions::api::BraveSyncResolvedSyncRecordsFunction::Run()
const BookmarkNode* BookmarkModel::AddURLWithCreationTimeAndMetaInfo(
    const BookmarkNode* parent,
    int index,
    const base::string16& title,
    const GURL& url,
    const Time& creation_time,
    const BookmarkNode::MetaInfoMap* meta_info) {
  if (!loaded_ || !url.is_valid() || is_root_node(parent) ||
      !IsValidIndex(parent, index, true)) {
    NOTREACHED();
    return nullptr;
  }
...

because IsValidIndex(parent, index, true) is false .

Also I can see ANRs after each add bookmark action, though these ANRs do not lead to whole app freeze, as pt4 of my prev message.

@AlexeyBarabash
Copy link
Contributor

bookmarks_big_folder_.html.zip
the html for import I had used for ~5000 bookmarks

@rebron rebron removed the priority/P4 Planned work. We expect to get to it "soon". label Jan 16, 2019
@rebron rebron removed this from the 1.x Backlog milestone Feb 7, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Completed
Development

No branches or pull requests

7 participants