Skip to content
This repository has been archived by the owner on Feb 27, 2023. It is now read-only.

bugfix:modify dfget output #852

Merged
merged 1 commit into from
Aug 23, 2019
Merged

Conversation

yunfeiyanggzq
Copy link
Member

@yunfeiyanggzq yunfeiyanggzq commented Aug 22, 2019

Signed-off-by: yunfeiyangbuaa [email protected]

Ⅰ. Describe what this PR did

make dfget output clear

Ⅱ. Does this pull request fix one issue?

fixes #817

Ⅲ. Why don't you add test cases (unit test/integration test)? (你真的觉得不需要加测试吗?)

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

now the out put is

--2019-08-22 19:28:46--  https://dl.google.com/go/go1.12.7.src.tar.gz
dfget version:
workspace:10156-1566473326.503
sign:10156-1566473326.503
client:127.0.0.1 connected to node:127.0.1.0:8002
start download by dragonfly...
download SUCCESS !
cost:3.333s length:21976647

--2019-08-22 19:28:08--  https://dl.google.com/go/go1.12.7.src.tar.gz
dfget version:
workspace:7650-1566473288.932
sign:7650-1566473288.932
download FAIL(1104)
cost:0.142s length:-1
reason:1001
error:{"Code":1104,"Msg":"download fail and not back source: 1001"}
exit status 80


Copy link
Member

@lowzj lowzj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use pkg/printer instead of fmt

@yunfeiyanggzq yunfeiyanggzq force-pushed the dfget_output branch 2 times, most recently from 069b34a to 9e7e9a9 Compare August 22, 2019 11:34
@codecov-io
Copy link

codecov-io commented Aug 22, 2019

Codecov Report

Merging #852 into master will increase coverage by 0.04%.
The diff coverage is 66.66%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #852      +/-   ##
==========================================
+ Coverage   39.64%   39.68%   +0.04%     
==========================================
  Files         109      109              
  Lines        6430     6431       +1     
==========================================
+ Hits         2549     2552       +3     
+ Misses       3672     3671       -1     
+ Partials      209      208       -1
Impacted Files Coverage Δ
cmd/dfget/app/server.go 60% <0%> (ø) ⬆️
cmd/dfdaemon/app/version.go 69.23% <0%> (ø) ⬆️
cmd/dfget/app/version.go 69.23% <0%> (ø) ⬆️
cmd/supernode/app/version.go 69.23% <0%> (ø) ⬆️
...core/downloader/back_downloader/back_downloader.go 62.26% <100%> (ø) ⬆️
cmd/dfget/app/root.go 65.45% <100%> (+0.21%) ⬆️
dfget/core/core.go 52.63% <80%> (+0.31%) ⬆️
supernode/daemon/mgr/dfgettask/manager.go 47.74% <0%> (-0.47%) ⬇️
supernode/daemon/mgr/scheduler/manager.go 24.81% <0%> (+0.75%) ⬆️
cmd/dfdaemon/app/root.go 63.63% <0%> (+1.29%) ⬆️

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 5e5b511...852a262. Read the comment docs.

@yunfeiyanggzq
Copy link
Member Author

use pkg/printer instead of fmt

I have changed fmt to pkg/printer. @lowzj

cmd/dfget/app/root.go Outdated Show resolved Hide resolved
dfget/core/core.go Outdated Show resolved Hide resolved
Copy link
Member

@lowzj lowzj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • change fmt to pkg/printer in BackDownloader
  • the example in dfget/app/root should be updated

Signed-off-by: yunfeiyangbuaa <[email protected]>
@yunfeiyanggzq
Copy link
Member Author

* change `fmt` to `pkg/printer` in `BackDownloader`

* the example in `dfget/app/root` should be updated

Done @lowzj

@lowzj
Copy link
Member

lowzj commented Aug 23, 2019

LGTM

@lowzj lowzj merged commit db719eb into dragonflyoss:master Aug 23, 2019
starnop pushed a commit to starnop/Dragonfly that referenced this pull request Nov 27, 2019
inoc603 pushed a commit to inoc603/Dragonfly that referenced this pull request Dec 23, 2019
sungjunyoung pushed a commit to sungjunyoung/Dragonfly that referenced this pull request May 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/bug This is bug report for project size/S
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[bug]The dfget cli output is ugly
4 participants