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

Received unexpected status code 400 #8

Closed
wavemoroc001 opened this issue Sep 15, 2022 · 10 comments
Closed

Received unexpected status code 400 #8

wavemoroc001 opened this issue Sep 15, 2022 · 10 comments
Labels
bug Something isn't working

Comments

@wavemoroc001
Copy link

wavemoroc001 commented Sep 15, 2022

I have tried to upload file to one drive but it throw Could not upload file: received unexpected status code 400

How can i fix this error ?
@virtualzone

@virtualzone
Copy link
Owner

Hi @wavemoroc001, can you provide a bit more information?

  • Are you logged in?
  • Does listing files work?
  • Does creating directories work?
  • Does the error only happen with specific files (i.e. size, file type) or with all the files you've tried?

@virtualzone virtualzone added the bug Something isn't working label Sep 17, 2022
@wavemoroc001
Copy link
Author

wavemoroc001 commented Sep 17, 2022

@virtualzone

  1. Are you logged in?
    I don't sure is my login is successfully ?? (as my screenshot)
    but on console log login successful and got secret.json file

Screen Shot 2565-09-18 at 01 07 28

  1. Does listing files work?
    No, it also throw same error Could not list: received unexpected status code 400

  2. Does creating directories work?
    Nope it throw error Could not list: received unexpected status code 400

  3. Does the error only happen with specific files (i.e. size, file type) or with all the files you've tried?
    In my case, I try to upload image (jpg) that size is less than 1 MB and it blow up with status 400

@virtualzone
Copy link
Owner

@wavemoroc001 Thanks for your response. I've just released version 0.4.5 which includes an improved error handling (especially more verbose error messages).

Could you try again with v0.4.5 and post the output? Please also run with the "-v" (verbose) flag.

@wavemoroc001
Copy link
Author

wavemoroc001 commented Sep 18, 2022

@virtualzone
I upgrade to version 0.4.5 and still get error.
This is my log

Screen Shot 2565-09-19 at 00 35 16

For more detail

config in app registration
Screen Shot 2565-09-18 at 22 37 10

config.json
Screen Shot 2565-09-19 at 00 53 31

@virtualzone
Copy link
Owner

Hi @wavemoroc001 ,

please review your "root" path setting in the config.json. It sets the root path within your OneDrive, not your local drive. Thus, it should usually be set to "/drive/root".

Secondly, please use "/" instead of "." when specifying paths in your OneDrive. So, instead of "ls ." use "ls /" (which is relative to the specified root path, see above).

Please check the README for more information.

@wavemoroc001
Copy link
Author

Hi @virtualzone
I tried follow your advices but it still get status 400

following this configuration

This is step i use app

Screen Shot 2565-09-23 at 11 34 37

config.json

Screen Shot 2565-09-23 at 11 36 38

This is root dir which i have mapped

Screen Shot 2565-09-23 at 11 33 52

@virtualzone
Copy link
Owner

Hi @wavemoroc001,
I hope to have fixed the Dynamic Path Segment Error in Version 0.4.7. Could you try the new version?
However, your "root" path setting is still incorrect. Please use "/drive/root" (nothing to replace here - just copy & paste).

@wavemoroc001
Copy link
Author

@virtualzone

Oh, thank you so much
I have try till it work.

Screen Shot 2565-09-25 at 01 40 08

@wavemoroc001
Copy link
Author

@virtualzone Cloud you improve ui screen eg. add estimate time or progress bar ? when i upload large file it look like it freezing

@virtualzone
Copy link
Owner

@wavemoroc001 I'm glad it's working now. Thanks for your idea on adding a progress bar/estimated time remaining. I've created a new issue for that (see above).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants