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

Use correct driveId value to query for changes when using --single-directory (Issue #1234) #1235

Merged
merged 1 commit into from Jan 22, 2021

Conversation

abraunegg
Copy link
Owner

  • Use the driveId value rather than defaultDriveId when looking for changes when using --single-directory

…rectory

* Use the driveId value rather than defaultDriveId when looking for changes when using --single-directory
@abraunegg
Copy link
Owner Author

abraunegg commented Jan 20, 2021

Environment:

.
├── 50k_random_files -> /home/alex/50k_random_files
├── random_files -> /home/alex/OneDrive/random_files
├── random_images -> /home/alex/OneDrive/random_images
├── random_videos -> /home/alex/OneDrive/random_videos
└── Top\ Folder  <--- This is a OneDrive Business Shared folder which is in-sync with OneDrive / local file system
    ├── asdfasdf
    │   └── qwerksdjfg.txt
    └── asdfasdfs.txt

6 directories, 2 files
./onedrive --confdir '~/.config/onedrive-business/' --list-shared-folders
Configuration file successfully loaded
Configuring Global Azure AD Endpoints
Initializing the Synchronization Engine ...

Listing available OneDrive Business Shared Folders:
---------------------------------------
Shared Folder:   Top Folder
Shared By:       test user
---------------------------------------
Shared Folder:   Sub Folder 2
Shared By:       test user (testuser@<redacted>)

Without PR:

./onedrive --confdir '~/.config/onedrive-business/' --synchronize --sync-shared-folders --download-only --verbose --single-directory 'Top Folder/asdfasdf/'
Using 'user' Config Dir: /home/alex/.config/onedrive-business/
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/OneDriveBusiness
Application version: v2.4.9-9-g6b0b6a6
Account Type: business
Default Drive ID: b!bO8V7s9SSk6r7mWHpIjURotN33W1W2tEv3OXV_oFIdQimEdOHR-1So7CqeT1MfHA
Default Root ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Remaining Free Space: 1097723481835
Fetching details for OneDrive Root
OneDrive Root exists in the database
Initializing the Synchronization Engine ...
Syncing changes from this selected path: Top Folder/asdfasdf/
Syncing changes from selected OneDrive path ...
Attempting to sync OneDrive Business Shared Folders
Getting path details from OneDrive ...
Applying changes of Path ID: 01TZRSBFFDOHNDGGFYAJAI5XHEGC2KCLDY
Updated Remaining Free Space: 1097723481835
No details returned for given Path ID

With PR:

./onedrive --confdir '~/.config/onedrive-business/' --synchronize --sync-shared-folders --download-only --verbose --single-directory 'Top Folder/asdfasdf/'
Using 'user' Config Dir: /home/alex/.config/onedrive-business/
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/OneDriveBusiness
Application version: v2.4.9-10-g0bbf162
Account Type: business
Default Drive ID: b!bO8V7s9SSk6r7mWHpIjURotN33W1W2tEv3OXV_oFIdQimEdOHR-1So7CqeT1MfHA
Default Root ID: 01WIXGO5V6Y2GOVW7725BZO354PWSELRRZ
Remaining Free Space: 1097723481835
Fetching details for OneDrive Root
OneDrive Root exists in the database
Initializing the Synchronization Engine ...
Syncing changes from this selected path: Top Folder/asdfasdf/
Syncing changes from selected OneDrive path ...
Attempting to sync OneDrive Business Shared Folders
Getting path details from OneDrive ...
Applying changes of Path ID: 01TZRSBFFDOHNDGGFYAJAI5XHEGC2KCLDY
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 added this to the v2.4.10 milestone Jan 20, 2021
@abraunegg abraunegg merged commit 3b87602 into master Jan 22, 2021
@abraunegg abraunegg deleted the fix-issue-1234 branch January 22, 2021 03:38
@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.

Can't download from Business Shared Folder when using --download-only & --single-directory
1 participant