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

Update 'Skipping shared folder due to existing name conflict' check for Business Shared Folders #1351

Merged
merged 1 commit into from
Mar 18, 2021

Conversation

abraunegg
Copy link
Owner

@abraunegg abraunegg commented Mar 17, 2021

…or Business Shared Folders

* In looking on how to fix #1345, it appears that for some reason the logic behind syncing shared folders was not working (although it previously was). Update the logic to specifically check the DB for the required driveId & itemId before attempting to get that DB item.
@abraunegg
Copy link
Owner Author

Without PR:

Using 'user' Config Dir: /home/alex/.config/onedrive-business-test/
Using 'system' Config Dir: 
Configuration file successfully loaded
Initializing the OneDrive API ...
Configuring Global Azure AD Endpoints
Opening the item database ...
All operations will be performed in: /home/alex/OneDriveBusinessTest
Application version: v2.4.10-17-g037a6b4
Account Type: business
Default Drive ID: b!bO8V7s9SSk6r7mWHpIjURotN33W1W2tEv3OXV_oFIdQimEdOHR-1So7CqeT1MfHA
Default Root ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Remaining Free Space: 1092356981485
Fetching details for OneDrive Root
OneDrive Root exists in the database
Initializing the Synchronization Engine ...
Syncing changes from OneDrive ...
Applying changes of Path ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Updated Remaining Free Space: 1092356981485
Number of items from OneDrive to process: 0
Attempting to sync OneDrive Business Shared Folders
Syncing this OneDrive Business Shared Folder: Top Folder
OneDrive Business Shared Folder - Shared By:  test user
Applying changes of Path ID: 01TZRSBFB37BC7IMQSQZBLGD62FOC65NYE
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 4 OneDrive items for processing from OneDrive folder
Adding 2 OneDrive items for processing from /Top Folder/asdfasdf
Adding 1 OneDrive items for processing from /Top Folder/testfolder
Processing 9 OneDrive items to ensure consistent local state
Syncing this OneDrive Business Shared Folder: my-library-folder
OneDrive Business Shared Folder - Shared By:  test user (testuser@mynasau3.onmicrosoft.com)
Applying changes of Path ID: 016ZTNKVQSDBSV7CCGIBGJ2PJ5GE5DAUTG
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 1 OneDrive items for processing from OneDrive folder
Number of items from OneDrive to process: 3
Uploading differences of ~/OneDriveBusinessTest
Processing .
The directory has not changed
Processing .
The directory has not changed
Processing Top Folder
The directory has not changed
Processing Top Folder/asdfasdf
The directory has not changed
Processing Top Folder/asdfasdf/Book.xlsx
The file has not changed
Processing Top Folder/asdfasdf/qwerksdjfg.txt
The file has not changed
Processing Top Folder/testfolder
The directory has not changed
Processing Top Folder/testfolder/Remove Ubuntu Package.docx
The file has not changed
Processing Top Folder/asdfasdfs.txt
The file has not changed
Processing Top Folder/Document.docx
The file has not changed
Processing .
The directory has not changed
Processing my-library-folder
The directory has not changed
Processing my-library-folder/Document.docx
The file has not changed
Uploading new items of ~/OneDriveBusinessTest
Applying changes of Path ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Updated Remaining Free Space: 1092356981485
Number of items from OneDrive to process: 0
Attempting to sync OneDrive Business Shared Folders
WARNING: Skipping shared folder due to existing name conflict: Top Folder    <-- No reason logical for this to occur
WARNING: Skipping changes of Path ID: 01TZRSBFB37BC7IMQSQZBLGD62FOC65NYE    <-- No reason logical for this to occur
WARNING: To sync this shared folder, this shared folder needs to be renamed    <-- No reason logical for this to occur
WARNING: Conflict Shared By:          test user    <-- No reason logical for this to occur
Syncing this OneDrive Business Shared Folder: my-library-folder
OneDrive Business Shared Folder - Shared By:  test user (testuser@mynasau3.onmicrosoft.com)
Applying changes of Path ID: 016ZTNKVQSDBSV7CCGIBGJ2PJ5GE5DAUTG
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 1 OneDrive items for processing from OneDrive folder
Number of items from OneDrive to process: 3

With PR:

Using 'user' Config Dir: /home/alex/.config/onedrive-business-test/
Using 'system' Config Dir: 
Configuration file successfully loaded
Initializing the OneDrive API ...
Configuring Global Azure AD Endpoints
Opening the item database ...
All operations will be performed in: /home/alex/OneDriveBusinessTest
Application version: v2.4.10-17-g037a6b4
Account Type: business
Default Drive ID: b!bO8V7s9SSk6r7mWHpIjURotN33W1W2tEv3OXV_oFIdQimEdOHR-1So7CqeT1MfHA
Default Root ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Remaining Free Space: 1092356981485
Fetching details for OneDrive Root
OneDrive Root exists in the database
Initializing the Synchronization Engine ...
Syncing changes from OneDrive ...
Applying changes of Path ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Updated Remaining Free Space: 1092356981485
Number of items from OneDrive to process: 0
Attempting to sync OneDrive Business Shared Folders
Syncing this OneDrive Business Shared Folder: Top Folder
OneDrive Business Shared Folder - Shared By:  test user
Applying changes of Path ID: 01TZRSBFB37BC7IMQSQZBLGD62FOC65NYE
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 4 OneDrive items for processing from OneDrive folder
Adding 2 OneDrive items for processing from /Top Folder/asdfasdf
Adding 1 OneDrive items for processing from /Top Folder/testfolder
Processing 9 OneDrive items to ensure consistent local state
Syncing this OneDrive Business Shared Folder: my-library-folder
OneDrive Business Shared Folder - Shared By:  test user (testuser@mynasau3.onmicrosoft.com)
Applying changes of Path ID: 016ZTNKVQSDBSV7CCGIBGJ2PJ5GE5DAUTG
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 1 OneDrive items for processing from OneDrive folder
Number of items from OneDrive to process: 3
Uploading differences of ~/OneDriveBusinessTest
Processing .
The directory has not changed
Processing .
The directory has not changed
Processing Top Folder
The directory has not changed
Processing Top Folder/asdfasdf
The directory has not changed
Processing Top Folder/asdfasdf/Book.xlsx
The file has not changed
Processing Top Folder/asdfasdf/qwerksdjfg.txt
The file has not changed
Processing Top Folder/testfolder
The directory has not changed
Processing Top Folder/testfolder/Remove Ubuntu Package.docx
The file has not changed
Processing Top Folder/asdfasdfs.txt
The file has not changed
Processing Top Folder/Document.docx
The file has not changed
Processing .
The directory has not changed
Processing my-library-folder
The directory has not changed
Processing my-library-folder/Document.docx
The file has not changed
Uploading new items of ~/OneDriveBusinessTest
Applying changes of Path ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Updated Remaining Free Space: 1092356981485
Number of items from OneDrive to process: 0
Attempting to sync OneDrive Business Shared Folders
Syncing this OneDrive Business Shared Folder: Top Folder
OneDrive Business Shared Folder - Shared By:  test user
Applying changes of Path ID: 01TZRSBFB37BC7IMQSQZBLGD62FOC65NYE
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 4 OneDrive items for processing from OneDrive folder
Adding 2 OneDrive items for processing from /Top Folder/asdfasdf
Adding 1 OneDrive items for processing from /Top Folder/testfolder
Processing 9 OneDrive items to ensure consistent local state
Syncing this OneDrive Business Shared Folder: my-library-folder
OneDrive Business Shared Folder - Shared By:  test user (testuser@mynasau3.onmicrosoft.com)
Applying changes of Path ID: 016ZTNKVQSDBSV7CCGIBGJ2PJ5GE5DAUTG
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 1 OneDrive items for processing from OneDrive folder
Number of items from OneDrive to process: 3

Processing the Shared Folder as required without the warning message

@abraunegg abraunegg added this to the v2.4.11 milestone Mar 17, 2021
@abraunegg abraunegg requested a review from norbusan March 17, 2021 19:40
@abraunegg
Copy link
Owner Author

Even a --resync with 'master' fails to resolve the issue encountered:

./onedrive --confdir '~/.config/onedrive-business-test/' --synchronize --sync-shared-folders --verbose --resync
Using 'user' Config Dir: /home/alex/.config/onedrive-business-test/
Using 'system' Config Dir: 
Configuration file successfully loaded
Deleting the saved status ...
Initializing the OneDrive API ...
Configuring Global Azure AD Endpoints
Opening the item database ...
All operations will be performed in: /home/alex/OneDriveBusinessTest
Application version: v2.4.10-17-g037a6b4
Account Type: business
Default Drive ID: b!bO8V7s9SSk6r7mWHpIjURotN33W1W2tEv3OXV_oFIdQimEdOHR-1So7CqeT1MfHA
Default Root ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Remaining Free Space: 1092356981485
Fetching details for OneDrive Root
OneDrive Root does not exist in the database. We need to add it.
Added OneDrive Root to the local database
Initializing the Synchronization Engine ...
Syncing changes from OneDrive ...
Applying changes of Path ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Updated Remaining Free Space: 1092356981485
Number of items from OneDrive to process: 1
Attempting to sync OneDrive Business Shared Folders
Syncing this OneDrive Business Shared Folder: Top Folder
OneDrive Business Shared Folder - Shared By:  test user
Applying changes of Path ID: 01TZRSBFB37BC7IMQSQZBLGD62FOC65NYE
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 4 OneDrive items for processing from OneDrive folder
Adding 2 OneDrive items for processing from /Top Folder/asdfasdf
Adding 1 OneDrive items for processing from /Top Folder/testfolder
Processing 9 OneDrive items to ensure consistent local state
Syncing this OneDrive Business Shared Folder: my-library-folder
OneDrive Business Shared Folder - Shared By:  test user (testuser@mynasau3.onmicrosoft.com)
Applying changes of Path ID: 016ZTNKVQSDBSV7CCGIBGJ2PJ5GE5DAUTG
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 1 OneDrive items for processing from OneDrive folder
Number of items from OneDrive to process: 3
Uploading differences of ~/OneDriveBusinessTest
Processing .
The directory has not changed
Processing .
The directory has not changed
Processing Top Folder
The directory has not changed
Processing Top Folder/asdfasdf
The directory has not changed
Processing Top Folder/asdfasdf/Book.xlsx
The file has not changed
Processing Top Folder/asdfasdf/qwerksdjfg.txt
The file has not changed
Processing Top Folder/testfolder
The directory has not changed
Processing Top Folder/testfolder/Remove Ubuntu Package.docx
The file has not changed
Processing Top Folder/asdfasdfs.txt
The file has not changed
Processing Top Folder/Document.docx
The file has not changed
Processing .
The directory has not changed
Processing my-library-folder
The directory has not changed
Processing my-library-folder/Document.docx
The file has not changed
Uploading new items of ~/OneDriveBusinessTest
Applying changes of Path ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Updated Remaining Free Space: 1092356981485
Number of items from OneDrive to process: 0
Attempting to sync OneDrive Business Shared Folders
WARNING: Skipping shared folder due to existing name conflict: Top Folder
WARNING: Skipping changes of Path ID: 01TZRSBFB37BC7IMQSQZBLGD62FOC65NYE
WARNING: To sync this shared folder, this shared folder needs to be renamed
WARNING: Conflict Shared By:          test user
Syncing this OneDrive Business Shared Folder: my-library-folder
OneDrive Business Shared Folder - Shared By:  test user (testuser@mynasau3.onmicrosoft.com)
Applying changes of Path ID: 016ZTNKVQSDBSV7CCGIBGJ2PJ5GE5DAUTG
OneDrive quota information is set at zero, as this is not our drive id, ignoring
Adding OneDrive root details for processing
Adding OneDrive folder details for processing
Adding 1 OneDrive items for processing from OneDrive folder
Number of items from OneDrive to process: 3

@abraunegg abraunegg merged commit 0dcc76f into master Mar 18, 2021
@abraunegg abraunegg deleted the fix-syncing-ODB-shared-folders branch March 18, 2021 02:24
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked and limited conversation to collaborators May 27, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants