diff --git a/.golangci.yml b/.golangci.yml index 76bad2652ca..5c9ec15c4ce 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -1,4 +1,4 @@ -# v1.62.2 +# v1.63.4 # Please don't remove the first line. It uses in CI to determine the golangci version run: timeout: 5m diff --git a/cloudapi/logs.go b/cloudapi/logs.go index b4b90378cd4..98eb078b9b5 100644 --- a/cloudapi/logs.go +++ b/cloudapi/logs.go @@ -118,8 +118,6 @@ func (c *Config) logtailConn(ctx context.Context, referenceID string, since time // StreamLogsToLogger streams the logs for the configured test to the provided logger until ctx is // Done or an error occurs. -// -//nolint:funlen func (c *Config) StreamLogsToLogger( ctx context.Context, logger logrus.FieldLogger, referenceID string, tailFrom time.Duration, ) error { diff --git a/internal/cmd/ui.go b/internal/cmd/ui.go index 1beaece013f..48723f3a574 100644 --- a/internal/cmd/ui.go +++ b/internal/cmd/ui.go @@ -164,7 +164,6 @@ func printExecutionDescription( } } -//nolint:funlen func renderMultipleBars( nocolor, isTTY, goBack bool, maxLeft, termWidth, widthDelta int, pbs []*pb.ProgressBar, ) (string, int) { diff --git a/internal/js/modules/k6/browser/browser/browser_mapping.go b/internal/js/modules/k6/browser/browser/browser_mapping.go index 42ccf187981..d0977922b1d 100644 --- a/internal/js/modules/k6/browser/browser/browser_mapping.go +++ b/internal/js/modules/k6/browser/browser/browser_mapping.go @@ -10,7 +10,9 @@ import ( ) // mapBrowser to the JS module. -func mapBrowser(vu moduleVU) mapping { //nolint:funlen,gocognit +// +//nolint:gocognit +func mapBrowser(vu moduleVU) mapping { return mapping{ "context": func() (mapping, error) { b, err := vu.browser() diff --git a/internal/js/modules/k6/browser/common/element_handle.go b/internal/js/modules/k6/browser/common/element_handle.go index 6c19619747b..03780bc1035 100644 --- a/internal/js/modules/k6/browser/common/element_handle.go +++ b/internal/js/modules/k6/browser/common/element_handle.go @@ -1618,7 +1618,7 @@ func (h *ElementHandle) newAction( } } -//nolint:funlen,gocognit +//nolint:gocognit func (h *ElementHandle) newPointerAction( fn elementHandlePointerActionFunc, opts *ElementHandleBasePointerOptions, ) func(apiCtx context.Context, resultCh chan any, errCh chan error) { diff --git a/internal/js/modules/k6/browser/common/frame.go b/internal/js/modules/k6/browser/common/frame.go index 9dc34f88b25..4bdb46581a3 100644 --- a/internal/js/modules/k6/browser/common/frame.go +++ b/internal/js/modules/k6/browser/common/frame.go @@ -1888,8 +1888,6 @@ func (f *Frame) WaitForLoadState(state string, opts sobek.Value) error { } // WaitForNavigation waits for the given navigation lifecycle event to happen. -// -//nolint:funlen func (f *Frame) WaitForNavigation(opts *FrameWaitForNavigationOptions) (*Response, error) { f.log.Debugf("Frame:WaitForNavigation", "fid:%s furl:%s", f.ID(), f.URL()) diff --git a/internal/js/modules/k6/browser/common/frame_session.go b/internal/js/modules/k6/browser/common/frame_session.go index da3cb8855ef..6f2a8fbb103 100644 --- a/internal/js/modules/k6/browser/common/frame_session.go +++ b/internal/js/modules/k6/browser/common/frame_session.go @@ -225,7 +225,7 @@ func (fs *FrameSession) initDomains() error { return nil } -//nolint:funlen,cyclop +//nolint:cyclop func (fs *FrameSession) initEvents() { fs.logger.Debugf("NewFrameSession:initEvents", "sid:%v tid:%v", fs.session.ID(), fs.targetID) diff --git a/internal/js/modules/k6/browser/common/network_manager.go b/internal/js/modules/k6/browser/common/network_manager.go index 8d9c2619a99..15de532f123 100644 --- a/internal/js/modules/k6/browser/common/network_manager.go +++ b/internal/js/modules/k6/browser/common/network_manager.go @@ -193,7 +193,6 @@ func (m *NetworkManager) emitRequestMetrics(req *Request) { }) } -//nolint:funlen func (m *NetworkManager) emitResponseMetrics(resp *Response, req *Request) { state := m.vu.State() diff --git a/internal/js/modules/k6/browser/common/screenshotter.go b/internal/js/modules/k6/browser/common/screenshotter.go index 15cbfeaa9ab..5612c488223 100644 --- a/internal/js/modules/k6/browser/common/screenshotter.go +++ b/internal/js/modules/k6/browser/common/screenshotter.go @@ -269,7 +269,6 @@ func getViewPortDimensions(ctx context.Context, sess session, logger *log.Logger return visualViewportScale, visualViewportPageX, visualViewportPageY, nil } -//nolint:funlen func (s *screenshotter) screenshotElement(h *ElementHandle, opts *ElementHandleScreenshotOptions) ([]byte, error) { format := opts.Format viewportSize, originalViewportSize, err := s.originalViewportSize(h.frame.page) diff --git a/js/modules/k6/http/response.go b/js/modules/k6/http/response.go index 0cc04b51de6..9ac014ac37c 100644 --- a/js/modules/k6/http/response.go +++ b/js/modules/k6/http/response.go @@ -134,8 +134,6 @@ func checkErrorInJSON(input []byte, offset int, err error) error { // SubmitForm parses the body as an html looking for a from and then submitting it // TODO: document the actual arguments that can be provided -// -//nolint:funlen func (res *Response) SubmitForm(args ...sobek.Value) (*Response, error) { rt := res.client.moduleInstance.vu.Runtime() diff --git a/lib/executor/ramping_vus.go b/lib/executor/ramping_vus.go index 78fb54c2bbb..e590123fc0a 100644 --- a/lib/executor/ramping_vus.go +++ b/lib/executor/ramping_vus.go @@ -304,7 +304,7 @@ func (vlvc RampingVUsConfig) precalculateTheRequiredSteps(et *lib.ExecutionTuple // executorEndOffset, is not handled here. Instead GetExecutionRequirements() // takes care of that. But to make its job easier, this method won't add any // steps with an offset that's greater or equal to executorEndOffset. -func (vlvc RampingVUsConfig) reserveVUsForGracefulRampDowns( //nolint:funlen +func (vlvc RampingVUsConfig) reserveVUsForGracefulRampDowns( rawSteps []lib.ExecutionStep, executorEndOffset time.Duration, ) []lib.ExecutionStep { rawStepsLen := len(rawSteps) diff --git a/lib/netext/httpext/transport.go b/lib/netext/httpext/transport.go index d2f00a5829d..23dc4082ac0 100644 --- a/lib/netext/httpext/transport.go +++ b/lib/netext/httpext/transport.go @@ -72,8 +72,6 @@ func newTransport( // Helper method to finish the tracer trail, assemble the tag values and emits // the metric samples for the supplied unfinished request. -// -//nolint:funlen func (t *transport) measureAndEmitMetrics(unfReq *unfinishedRequest) *finishedRequest { trail := unfReq.tracer.Done()