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

NXDRIVE-2607: Handle invalid data returned by the server when asking for a batchId #2630

Merged
merged 1 commit into from Apr 22, 2021

Conversation

rom1win
Copy link
Contributor

@rom1win rom1win commented Apr 22, 2021

Co-authored-by: Romain Grasland rgrasland@nuxeo.com

…for a batchId

Co-authored-by: Romain Grasland <rgrasland@nuxeo.com>
@rom1win rom1win added the bugfix label Apr 22, 2021
@nuxeojenkins
Copy link
Contributor

View issue in JIRA: NXDRIVE-2607: Handle invalid data returned by the server when asking for a batchId

@rom1win rom1win requested a review from BoboTiG April 22, 2021 14:31
@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Apr 22, 2021

Sourcery Code Quality Report

❌  Merging this PR will decrease code quality in the affected files by 0.06%.

Quality metrics Before After Change
Complexity 1.05 ⭐ 1.05 ⭐ 0.00
Method Length 69.32 🙂 70.71 🙂 1.39 👎
Working memory 8.97 🙂 8.97 🙂 0.00
Quality 68.35% 🙂 68.29% 🙂 -0.06% 👎
Other metrics Before After Change
Lines 1032 1073 41
Changed files Quality Before Quality After Quality Change
nxdrive/client/uploader/init.py 88.26% ⭐ 88.03% ⭐ -0.23% 👎
tests/old_functional/test_transfer.py 68.19% 🙂 68.13% 🙂 -0.06% 👎

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
tests/old_functional/test_transfer.py TestDownload.test_pause_download_manually 4 ⭐ 173 😞 14 😞 50.06% 🙂 Try splitting into smaller methods. Extract out complex expressions
tests/old_functional/test_transfer.py TestUpload.test_server_error_but_upload_ok_idempotent_call 0 ⭐ 211 ⛔ 13 😞 52.41% 🙂 Try splitting into smaller methods. Extract out complex expressions
tests/old_functional/test_transfer.py TestUpload.test_chunk_upload_error_then_server_error_at_linking 2 ⭐ 275 ⛔ 9 🙂 54.19% 🙂 Try splitting into smaller methods
tests/old_functional/test_transfer.py TestDownload.test_modifying_paused_download 4 ⭐ 147 😞 12 😞 55.63% 🙂 Try splitting into smaller methods. Extract out complex expressions
tests/old_functional/test_transfer.py TestDownload.test_deleting_paused_download 2 ⭐ 134 😞 12 😞 59.07% 🙂 Try splitting into smaller methods. Extract out complex expressions

Legend and Explanation

The emojis denote the absolute quality of the code:

  • ⭐ excellent
  • 🙂 good
  • 😞 poor
  • ⛔ very poor

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Let us know what you think of it by mentioning @sourcery-ai in a comment.

@codecov
Copy link

codecov bot commented Apr 22, 2021

Codecov Report

Merging #2630 (d5f4cdf) into master (9582582) will decrease coverage by 12.20%.
The diff coverage is 14.28%.

Impacted file tree graph

@@             Coverage Diff             @@
##           master    #2630       +/-   ##
===========================================
- Coverage   43.52%   31.32%   -12.21%     
===========================================
  Files          77       77               
  Lines       14630    14636        +6     
===========================================
- Hits         6367     4584     -1783     
- Misses       8263    10052     +1789     
Flag Coverage Δ
functional ?
integration ?
unit 31.32% <14.28%> (-3.00%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
nxdrive/client/uploader/__init__.py 21.39% <14.28%> (-0.16%) ⬇️
nxdrive/client/local/windows.py 0.00% <0.00%> (-91.35%) ⬇️
nxdrive/client/local/darwin.py 0.00% <0.00%> (-90.42%) ⬇️
nxdrive/osi/windows/files.py 0.00% <0.00%> (-82.36%) ⬇️
nxdrive/osi/windows/registry.py 1.42% <0.00%> (-80.00%) ⬇️
nxdrive/osi/windows/windows.py 0.00% <0.00%> (-69.68%) ⬇️
nxdrive/updater/windows.py 0.00% <0.00%> (-66.67%) ⬇️
nxdrive/osi/darwin/extension.py 0.00% <0.00%> (-65.00%) ⬇️
nxdrive/osi/windows/extension.py 0.00% <0.00%> (-63.27%) ⬇️
nxdrive/osi/darwin/darwin.py 0.00% <0.00%> (-52.64%) ⬇️
... and 31 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9582582...d5f4cdf. Read the comment docs.

@BoboTiG BoboTiG merged commit 9530649 into master Apr 22, 2021
@BoboTiG BoboTiG deleted the wip-NXDRIVE-2607-invalid-batchId-response branch April 22, 2021 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants