Releases: vbauerster/getparty
Releases Β· vbauerster/getparty
v1.22.4
v1.22.3
Changelog
- c8fbe23 *mpb.Progress wrapper
- d4fc2e0 FixedIntervalTimeNormalizer for ewma eta only
- 9801649 Revert "proper p.isDone func"
- 2129dbb add choice 2 for buf size
- abcad67 buf size description with hint
- 6e627f8 buffer size option
- c34b26e call makeStateHandler right before for loop
- 0737272 call time.Now once
- 377c41b default buf size 8 KiB
- a46c43f define buf once
- 49582bc define bufLen once
- 1506dfd go get -u
- 2d9a984 isDone: no need to check total
- 1b12908 limit opt.Timeout by maxTimeout
- 3d42009 makeStateHandler: complete top and total bars in new goroutine
- c2551ec max timeout 60s
- e29c989 override user agent of restored session
- ff3a565 proper bufLen calc
- 1c3ba22 refactoring: makeStateHandler
- e442a9b refactoring: nopBar to topBar
- 6fd98c5 refactoring: override progress.Wait
- 43718f7 refactoring: p to progress
- e0bf4db refactoring: progress as session methods
- 3b56758 refactoring: written on progress struct
- 381d5a3 reset timeout after at least one successful timer.Reset
- f75a6fa send to start before return
- a3d1be0 set start time after either status 200 or 206
- a7a81dc set/unset CheckRedirect in cmd.getState
- 1d1e644 state handler fix: Fprintln
- d034706 tiemout description edit
- 471b21e update chrome and firefox user agent string
v1.22.2
Changelog
- 0dc8b09 Output Options
- 7d0396a Revert "overwriteIfConfirmed: check for ErrCanceledByUser before removing"
- 5d02fa0 TestParseContentDisposition
- ac31034 TestParseContentDisposition as unit test
- f64fc92 TestParseContentDisposition: edge test cases
- e25ec2c complete parts need a logger
- c6e6382 debug part is done unconditionally
- b52f53c defer cancel statusOK ctx inside eg func
- 246031b defer p.statusOK.cancel()
- 9a00689 do not try to restore cookies from headers
- 1b97a4b follow is expected to have non nil client.CheckRedirect
- edfb45e go get -u
- 650d0e4 go get -u
- a0dc387 make head request for best mirror evaluation
- 78b50ea no need to bar.Wait()
- 6793a0e no need to declare start conditionally
- 0f38bb1 no need to serialize elapsed
- 5a0a772 no need to store elapsed on Part struct
- 6930004 options output group
- cdea0d4 overwriteIfConfirmed: fmt.Scanf with %s verb
- 7bc8bc6 overwriteIfConfirmed: return Ctx.Err() if it's not ErrCanceledByUser
- e028f3e parseContentDisposition: use FindStringSubmatch
- 6ba646c proper p.isDone func
- f6c3865 recover returns any so v is better name
- 7f6cd24 refactoring parseContentDisposition
- d65b299 refactoring: Output.Method to Output.PathFirst
- f7138f3 refactoring: baseName to outputBase
- 27e61a0 refactoring: concatenateParts as func
- e5e0e31 refactoring: debugWriter to debugOut
- fc95252 refactoring: getState
- 45e981c refactoring: getState
- 3117b34 refactoring: no need for httpStatus200 var
- 0805dc6 refactoring: total bar at bottom
- 3a99586 runTotalBar: no need to call DecoratorAverageAdjust
- 641bcfe session.totalWritten data race fix
- 9562d3a switch to ewma eta
- 38b00f9 sync dst after concat
- d913d6f truncate mirror duration by microsecond
- 655a2a2 use-path description edit
- 7dd57ce use-path is better name
v1.22.1
Changelog
- 68d1a9d aur wiki link
- 0823d16 cap aur
- 502cb53 check for sleepCtx != nil
- d4850a2 default user-agent: getparty/ver
- c335723 define getR outside of loop
- 827d54b don't create sleep bg contex
- d0f0cd7 don't minus sleep from total elapsed
- baaab73 fpart.Sync before bar.Wait
- eae5e90 fuse io.ErrUnexpectedEOF
- 269e856 go get -u
- 5845617 incr &curTry in defer on retry only
- 3947b8e increase timeout either on !timer.Reset or !timer.Stop
- 3ff3a4b log debug: total elapsed and slpet
- 9e7a9f9 log debug: total written
- f3d7beb log debug: waiting for bar
- 62f0af9 makeReqPatcher if session.restored
- aaa5290 no need to log error in defer
- 2921de2 offload writing to p.progress
- f095e59 print quoted url
- cb9d01d refactoring: Cmd.options to Cmd.opt
- 75d176c refactoring: options struct doesn't have to be public
- d6d9bb0 reset timer before ReadFull loop
- 9e739ab return ErrCanceledByUser if it's cause of eg.Wait()
- 517c4e3 speed-limit from 1 to 5 and multiply by 60
v1.22.0
Changelog
- 3d109c3 (Cmd).follow: debug failed client.Do(req)
- 5ef0ca5 (Cmd).runTotalBar help func
- 6219a89 ReadFull loop exit condition n != bufLen
- 6074d25 ReadFull loop: EOF check is redundant n == 0 implies it's EOF
- d309e14 Show HTTP response headers in DEBUG output
- 0e42da2 a bit more appealing max retry err message
- 00a6ff1 abort bar if cannot retry because of BasHttpStatus
- d0408d1 alow infinite redirections
- e3b0b28 always bar.Wait() on retry false
- bce7d12 always debug retry and error status
- 97ba26c always quit signal listener goroutine
- 592be21 assign CheckRedirect func at client construction
- 122527f assign short -u for user-agent
- e22f618 backoff.RetryWithContext: refactoring defer
- 80b0931 bar.Abort in defer only
- 4f328bd bar.Abort outside of defer
- 1dc2a44 better handling of non resumable
- c21ed40 check flags.Error condition outside of getState
- 5ad3d8e check for ErrCanceledByUser after successful term.ReadPassword(0)
- 1fb72c6 check for io.ErrUnexpectedEOF in for condition
- 0b459c7 check httpStatus200 before any session op
- 1aa7f3a cmd.options.UserAgent is always preffered over restored.HeaderMap[hUserAgentKey]
- 2a9aa96 concatenateParts conditions in one if statement
- bc1ed9e const umask = 0644
- cb09a48 debug which part get status 200
- 163c462 decrement &globTry first
- 08a26b2 defer stateHandler uncoditionally
- 94ea174 defer: debug retry log last
- 7c9e741 define *http.Client on Part struct
- f547538 delete key we don't want to cancel
- 3b4cc2e don't call p.incrTotalBar(wn) if wn is zero
- 787c46d don't reset cmd.Out
- 23efd4c dont' nil cmd.parser
- 36fad69 drop redundant assertion
- 5e3d373 drop redundant p.isDone() check
- 3c25096 drop unnecessary cmd.Ctx.Err() check
- 239f1f1 edit description of some options
- d910ecf errors.Wrap is more appropriate here
- c039fe6 exit folow loop on ErrMaxRedirect
- 96f61c9 extra fields on *Part
- 57225da follow: debug all http responses
- dbf76c6 follow: get log template=GET:R%02d
- 356656f getState: invert if os.Stat statement for better readability
- dd22dfa getState: no need for args param
- 616b934 go get -u
- cada1ec golangci-lint
- 0c91acc handle ContentLength=0 correctly
- 25a1671 handle error of resp.Body.Close()
- 2bc1031 https options group
- c23c5c3 if err isn't one of EOF after part is done return it
- 89d5f59 if session isn't resumable debug it as well
- 677a298 include timeout in get debug log
- 7eb0a04 log debug GET messages as well
- cc8e8f3 log err.Error() if err is non nil
- 19aabf5 make short user-agent flag capital
- 1e8ee25 make sure read's n is not shadowed
- 284f533 map cancel funcs for further processing
- 75b1fec max-redirect option
- df8ac7a never override cmd.Err
- 88ed0d7 no need for httpStatusOK in Part struct
- 7dc76de no need to debug ContentLength
- 129bb2c no need to store cancel on Part struct
- ae87b72 one debug msg in case of timeout
- ecd50ea override log prefix
- 7578028 overwriteIfConfirmed: always debug removing
- 88e2fd1 overwriteIfConfirmed: check for ErrCanceledByUser before removing
- 56d51bd prefer p.FileName
- 4f973d4 prefer println without '%s' where possible
- 880c819 prefix req headers as resp does
- 54360f9 prefix timeout message with p.name
- d604386 print err to p.progress on each retry
- 6ef1c6f print retry err to p.progress in defer
- 6495652 print wrapped ErrMaxRetry
- 4e9f83e proper file name handling for single part
- 21097f9 read friendly debug
- a979059 refactoring (Session).summary
- 0a0d50e refactoring cookie debug
- 22ddc2e refactoring newRoundTripperBuilder
- 63f3b3b refactoring: (Cmd).initTotalBar
- 4f2dcb8 refactoring: (Session).summary prefer switch to if
- 45aee25 refactoring: Part.openAsDst
- d2cc7c4 refactoring: Part.writeTo
- b4f49e8 refactoring: best mirror
- 97f320f refactoring: best mirror group
- f3c83e5 refactoring: check ErrCanceledByUser
- 0c1a08d refactoring: close fpart at one place
- 6f32ae5 refactoring: init debug logger in (*Part).download
- f0434ff refactoring: log "Saving to" outside of (Session).summary
- 6759c41 refactoring: pass maxTry as arg to (*Part).download
- 67f6ea9 refactoring: pass session.OutputName as arg to (*Part).download
- bea835d refactoring: proper handling of http status 200
- e38a346 refactoring: rename dlogger to logger
- 35a0e56 refactoring: rename to Session.OutputName
- 1e79a35 refactoring: rename to firstErr
- 0803848 refactoring: type http200Context struct
- 47f0047 refactoring: unwrapOrErr
- d4b050f relevant wrap message for ErrMaxRetry
- 34c68d3 remaining args aren't needed after cmd.parser.ParseArgs(args)
- a3e3828 rename HttpError to BadHttpStatus
- e418ae4 request pooled transport if only there is more than 1 part
- ae70a30 return err of resp.Body.Close()
- 161cef8 revert ecd50ea
- e7ce93d set both InsecureSkipVerify and RootCAs
- 30c66bd setting bar refill only at http.StatusPartialContent case
- 6ee895c short switch for debug
- 2c30a87 some written assertion in status 200 mode
- 133e4a0 stop on not resumable session
- 68b94b4 sync with new options
- f56b4a3 timeout based on timer.Stop
- ceecf7c undo debug hack
- 7cec9bc var buf [bufLen]byte
- b90db09 wrap BadHttpStatus
v1.21.3
Changelog
- 44572ff Revert "fpart.Sync on retry"
- e4eec33 Revert "unnecessary panic"
- 04c1a4b always report 5xx status via p.progress
- d8494eb always report client.Do error via p.progress
- 0b8b06f better err handling of fpart.Write
- a940b50 capture written in if
- 9d8752c debug on dropped bar messages
- ead9541 debug on removing existing file
- 52e118e different json name on panic
- 426a347 ditch fmt.Errorf
- 5b63224 don't panic on os.OpenFile
- 9bb8465 drop flashBar
- 34c3612 err check on statSizeCmp
- 765b801 extra methods on Part
- dffd11c fpart.Sync on io.EOF
- 372ab10 fpart.Sync on retry
- c2d4512 go get -u
- f4e7fa8 goreleaser v2
- 46330de goreleaser-action@v6 with version ~> v2
- 6005607 handle Part is done before EOF
- 43aca62 handle Part isn't done after EOF
- 3d2e9ed handle err is nil case
- 786b1da if p.Skip do nothing in defer
- 7be397c more 5xx retry cases
- 5e07c6c no need for func init
- 4486342 no need to pass logger to concatenateParts
- 7f2d5bb no panic on file close error
- afcb144 non nil bar assertion
- 62f8c68 panic extension for panic session
- 15eb5c1 pass single as param
- c0b5a93 refactoring EOF detection
- b0ad846 report error on fpart.Write
- a0194b6 revert 90284cb
- 24f0f91 session.hasSkippedParts check
- 57a36dd unnecessary ctx err check
- 1a3e9d7 unnecessary panic
v1.21.2
Changelog
- 49666d2 UserAgent: default:"chrome"
- 940e135 go get -u
- e48bfb9 makeReqPatcher: always skip hCookie
- 0dd0097 paru as aur helper
- 3ebe047 replace req patcher in (*Cmd).getState
- f774f7a store req patcher on Cmd
- 55fdb24 "" = "chrome"
- 2cfac03 set user agent before best mirror
- cff6d90 from source upd
- 3b76940 aur url
- 1ba7205 log query mirror err as warn
- 40d7b99 clear user/pass after we get *url.Userinfo
- 08357f2 modify HeaderMap close to usage
- c0edbd5 refactoring: reset cmd.Out and cmd.Err
- d0f74c3 stop at len(via) >= maxRedirects
- f93b86a set client.CheckRedirect in (Cmd).getState
- e3cc648 pass *http.Client to (Cmd).getState
- 90284cb remove empty file always
- dc2ed69 init *http.Client outside go func
- 118af39 init *http.Request in (*Part).download
- fdd254a no need to store *tls.Config on Cmd
- 0e2efa7 RoundTripper builder
- 69c3170 pass userinfo to makeReqPatcher
- eae064c getErr once before loop
- 88c532f rever commit dbe2ec8
- 378f67c refactoring: initTLSConfig
- e460e42 don't use md url format for mirrors.txt
- 7445900 some -b examples
- 0d902ad reflect -b help
- bf495e7 update mirrors list example
- 892c815 log if session is restored from json
- 784d0ae refactoring loggers
- 31e7742 refactoring best mirror implementation
- 8950e18 more relevant error message on written != ContentLenght
- 8c0bf52 prefer error to panic on corrupted file detection
- 7bd990e Get file size by Stat() on each file part
- 6368c4f default commit string: HEAD
- 7b38d06 retry on 500 and 503
- 8b2f410 Merge pull request #30 from nwoodmsft/log-remoteaddr
- fa891c7 Add debug output to show the remote server address
- e7383bf bugfix: progress.Wait() in any case
v1.21.1
v1.21
Changelog
- 4894291 go get -u
- 9f15bb1 SpeedPeak: ewma 30 with upd count
- b1df581 rename files
- 690a494 refactoring: distinctBarRefiller
- d3e0230 baseBarStyle: disable tip
- 7110c43 year++
- 097abed makeTotalBar: revert to AverageSpeed
- decf1bb compose bar of # symbols
- 6cac6b8 makeTotalBar: make sure goroutine quits by blocking incr func
- 815ee18 makeTotalBar: return nop incr func on unsatisfied invariants
- 223b112 makeTotalBar: return error on add bar error
- 01a1a55 go get -u
- eb28f5f release: checkout@v4, setup-go@v5 and goreleaser-action@v5
- d3372c0 build: checkout@v4 and setup-go@v5
- 4a276dd refactoring: message.isErr
- f9de470 no need to go bar.flash
- 1ce2f70 data race fix: pass p.Written as param
- b0c2f5c peak: no need for 'completed bool'
- ef0a885 flashBar.init: OnCompleteOrOnAbort AverageETA
- aa264eb makeTotalBar: OnCompleteOrOnAbort AverageETA
- 77cffe2 Revert "flash msgCh buffer size 3"
- 27c9998 makeMsgHandler method of Part
- a35e4bf flash msgCh buffer size 3
- bdc3bdf makeMsgHandler without quiet
- 9e99ed8 don't log exit error on status 0
- 0d3adb8 make flash msgCh buffer size 1
- 30b238b comment what flags.ErrHelp means
- 458303d resort to default logger if ErrBadInvariant
- 859bdba init loggers early
- b7586df refactoring: cause
- 131d580 invariantCheck in its own clause
- 1e586bb cmd.getOut and cmd.getErr
- 5267f97 ErrBadInvariant
- db17091 version is more specific than quiet
- 18ab758 refactoring: cmd.getTimeout and cmd.getSleep
- a223ff2 inline readPassword
- a60181a prefer return err to logger.Fatalf
- 98ddc39 refactoring: utilize firstNonNil
- 28eb8fc refactoring: eitherError to firstNonNil
- d02338d refactoring: move isResumable
- c3e87bf refactoring: move Session.concatenateParts to the bottom
- c7e92b4 refactoring: Session.dumpState
- 28f8efb refactoring: Session.loadState
- d393bcf small refactoring
- 0c04565 go get -u
- bb5dcad comment for future self
- cfe1866 do not async write to p.progress
- 546fd3e refactoring: totalEwmaIncr
- 8f073b8 check total bar add error
- d3ea69a drop unnecessary debug log
- d25eabc else is redundant in this context
- c2dea5e refactoring read resp.Body loop
- 325be0f don't be paranoid
- 5766fa3 init sleepCtx with empty context
- 2d2c484 make sure totalEwmaInc never blocks
- 6a49d3b write json state while waiting for progress
- 52b6f88 totalCancel is idempotent
- 8fe2d98 totalCancel(drop bool)
- 22b11da no need to check parent cmd.Ctx, as ctx derives cmd.Ctx
- dbe2ec8 same client for all parts
- 252968e refactoring: doneCount
- 1894f81 fix nil pointer deref
- e492f7c refactoring: totalEwmaInc
- e7ba21f go bar.SetRefill
- 1411026 license year++
- 87bae39 go bar.SetRefill
- 7202770 session.makeTotalBar
- 3600d0c SpeedPeak: ewma 20
- 1365d9b Conditional decorator on top
- d84661d same ':' for concatenate bar
- c5c8a1f print just ':' instead of 'Avg:'
- dfaddaa refactoring: switch to EwmaSpeed decorator
- fa8515f refactoring: (*flashBar).init
v1.20.2
Changelog
- 4fded83 go get -u
- fccc9ef max try message: surround / with space
- 90e9b73 concatenateParts: return on any errors
- 188909b remove part if nothing were written
- 55a3395 go get -u
- bab3be9 SpeedPeak: ewma 18
- cab1ee7 remove EwmaUpdate comment
- 51289f3 account zDur on math.IsInf or math.IsNaN
- cf05ed9 display written/total size on max try
- 9fec6fc account n = 0 case for peak decorator
- 8c1d7ee undo: peak.EwmaUpdate: post Add
- 6adb428 flash limit 15
- 202438b don't count first msg receive
- 9077d3c output err in new goroutine on retry = true
- 432ed26 type HttpError int
- 4a12366 drop cutCode
- 51a40a9 bar.Abort in current goroutine
- a829f8f refactoring makeMsgHandler
- 80880c5 message final is not used anymore
- 3370d81 decrease globTry if not initial attempt only
- ed056fd go get -u
- b5ee458 use DextraSpace config for decor.Spinner