GitLabgitlab-org

cli

main
ply5 git calls31 ms97 KiB4 cachedprotocol v2
163 lines4.8 KiBRaw
1version: "2"
3run:
4 modules-download-mode: readonly
6# Unlimited so a failing run lists every issue; the defaults keep a
7# truncated sample whose members vary between runs.
8issues:
9 max-issues-per-linter: 0
10 max-same-issues: 0
12linters:
13 default: none
14 enable:
15 - asasalint
16 - asciicheck
17 - bidichk
18 - bodyclose
19 - contextcheck
20 - copyloopvar
21 - depguard
22 - dupword
23 - errcheck
24 - errorlint
25 - exptostd
26 - fatcontext
27 - forbidigo
28 - forcetypeassert
29 - gocheckcompilerdirectives
30 - gochecksumtype
31 - gocritic
32 - gomoddirectives
33 - govet
34 - ineffassign
35 - makezero
36 - mirror
37 - misspell
38 - modernize
39 - nilerr
40 - nilnesserr
41 - nolintlint
42 - nonamedreturns
43 - nosprintfhostport
44 - reassign
45 - staticcheck
46 - testifylint
47 - unconvert
48 - unparam
49 - unused
50 - usetesting
51 - thelper
52 - tparallel
53 exclusions:
54 presets:
55 - comments
56 - common-false-positives
57 - legacy
58 - std-error-handling
59 rules:
60 - path: _test\.go
61 linters:
62 - dupword
63 - forbidigo
64 - path-except: internal/commands/
65 linters:
66 - forbidigo
67 text: "stdout and stderr output"
68 # TODO: surfaced by staticcheck in golangci-lint 2.13.x; drop these once
69 # the deprecated fields are migrated and the token cache nil check is fixed.
70 - path: (internal/api/milestone|internal/cmdutils/cmdutils|internal/commands/issue/create/issue_create_test|internal/commands/issue/create/issue_create_attach_test|internal/commands/mr/create/mr_create_test|internal/commands/mr/create/mr_create_attach_test)\.go
71 linters:
72 - staticcheck
73 text: "SA1019"
74 - path: internal/commands/cluster/agent/token_cache/list/list\.go
75 linters:
76 - staticcheck
77 text: "SA4023"
78 settings:
79 forbidigo:
80 forbid:
81 - pattern: ^json\.Marshal(Indent)?$
82 msg: "Use IOStreams.PrintJSON for stdout output. For non-stdout serialization (request bodies, disk, protocols), add //nolint:forbidigo with a reason."
83 - pattern: ^json\.NewEncoder$
84 msg: "Use IOStreams.PrintJSON for stdout output. For non-stdout serialization (request bodies, disk, protocols), add //nolint:forbidigo with a reason."
85 - pattern: ^fmt\.F(print|printf|println|scan|scanf|scanln)$
86 msg: "Use IOStreams LogInfo, LogInfof, Error, and Errorf for stdout and stderr output."
87 gocritic:
88 enabled-tags:
89 - diagnostic
90 - style
91 disabled-checks:
92 # Wants named results, which nonamedreturns forbids.
93 - unnamedResult
94 # Narrower restatement of govet's shadow check, disabled below.
95 - importShadow
96 # Duplicates nolintlint's require-explanation.
97 - whyNoLint
98 # Purely cosmetic parameter grouping.
99 - paramTypeCombine
100 govet:
101 enable-all: true
102 disable:
103 - fieldalignment
104 - shadow
105 modernize:
106 disable:
107 - omitzero
108 # TODO: new in golangci-lint 2.13.x; re-enable once the tree is cleaned up.
109 - errorsastype
110 - embedlit
111 - reflecttypeassert
112 staticcheck:
113 checks:
114 - all
115 - -QF*
116 - -ST1003
117 - -ST1008
118 - -ST1012
119 - -ST1016
120 - -ST1018
121 - -ST1023
122 depguard:
123 rules:
124 cmdutils-only-in-commands:
125 files:
126 - "**/*.go"
127 - "!**/cmd/glab/*.go"
128 - "!**/cmd/gen-docs/*.go"
129 - "!**/internal/testing/cmdtest/*.go"
130 - "!**/internal/cmdutils/*_test.go"
131 - "!**/internal/commands/*.go"
132 - "!**/internal/commands/**/*.go"
133 deny:
134 - pkg: "gitlab.com/gitlab-org/cli/internal/cmdutils"
135 desc: "internal/cmdutils should only be imported from packages under internal/commands/"
137 no-testing-in-production:
138 files:
139 - "!$test"
140 deny:
141 - pkg: "gitlab.com/gitlab-org/cli/internal/testing/**"
142 desc: "Testing utilities should only be used in test files"
143 usetesting:
144 context-background: true
145 context-todo: true
146 os-chdir: true
147 os-mkdir-temp: true
148 os-setenv: true
149 os-create-temp: true
150 os-temp-dir: true
152formatters:
153 enable:
154 - gci
155 - gofumpt
156 - goimports
157 settings:
158 gci:
159 sections:
160 - standard
161 - default
162 - prefix(gitlab.com/gitlab-org/api)
163 - localmodule
Diagnostics5 git calls · 31 ms
CallStatusSizeTime031 ms
discover200185 B2 ms
git.upload-pack discover
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=ls-refs
git.upstream.dur_ms=2
git.response.bytes=185
git.server.agent=git/2.56.g1891de4-Linux
git.server.object_format=sha1
git.server.caps=agent ls-refs fetch server-option object-format
git.server.fetch=shallow wait-for-done filter
git.protocol.version=2
git.pkt.frames=9
git.pkt.data=7
git.pkt.flush=2
git.pkt.delim=0
git.pkt.bytes=185
git.pkt.payload.max=35
ls-refs20058 KiB · hit3 ms
git.upload-pack ls-refs
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=ls-refs
git.upstream.dur_ms=3
git.response.bytes=59849
git.response.cache=HIT
git.response.duration_ms=3
git.protocol.version=2
git.pkt.frames=731
git.pkt.data=730
git.pkt.flush=1
git.pkt.delim=0
git.pkt.bytes=59849
git.pkt.payload.max=143
git.ls_refs.count=730
git.ls_refs.head=refs/heads/main
fetchcombine:blob:none+tree:2 · deepen 12004.2 KiB · hit3 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=4
git.response.bytes=4273
git.response.cache=HIT
git.response.duration_ms=3
git.fetch.filter=combine:blob:none+tree:2
git.fetch.wants=0dd7574dce9e385c5c30540e6c15657adc6bdce9
git.fetch.haves.count=0
git.fetch.deepen=1
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=7
git.pkt.data=5
git.pkt.flush=1
git.pkt.delim=1
git.pkt.bytes=4273
git.pkt.payload.max=4173
git.sideband.band1.bytes=4173
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0
git.pack.objects=11
git.pack.bytes=4173
git.fetch.wide.objects=11
git.fetch.wide.extra_bytes=3930
git.fetch.wide.blobs=0
fetchtree:0 · deepen 1020032 KiB · hit4 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=3
git.response.bytes=32926
git.response.cache=HIT
git.response.duration_ms=4
git.fetch.filter=tree:0
git.fetch.wants=0dd7574dce9e385c5c30540e6c15657adc6bdce9
git.fetch.haves.count=0
git.fetch.deepen=10
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=22
git.pkt.data=20
git.pkt.flush=1
git.pkt.delim=1
git.pkt.bytes=32926
git.pkt.payload.max=32046
git.sideband.band1.bytes=32046
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0
git.pack.objects=80
git.pack.bytes=32046
git.pack.ofs_delta=36
git.pack.ref_delta=0
git.pack.chain.max=2
git.pack.trailer=cb0bad5d7ffc514895d8b21c4dd470327f90bc91
git.pack.full=44
Open pack map
fetch2001.6 KiB · hit24 ms
git.upload-pack fetch
http.response.status_code=200
git.upstream.cf_ray=-
git.upstream.phase=fetch
git.upstream.dur_ms=24
git.response.bytes=1682
git.response.cache=HIT
git.response.duration_ms=24
git.fetch.wants=955c6458bcdcdb3f95b55035c18b01c745b7d551
git.fetch.haves.count=0
git.fetch.deepen=0
git.fetch.thin_pack=false
git.fetch.ofs_delta=true
git.protocol.version=2
git.pkt.frames=4
git.pkt.data=3
git.pkt.flush=1
git.pkt.delim=0
git.pkt.bytes=1682
git.pkt.payload.max=1655
git.sideband.band1.bytes=1655
git.sideband.band2.bytes=0
git.sideband.band3.bytes=0

Each row is one HTTP round trip ply made to the git server for this page, on one timeline. discover asks what the server speaks, ls-refs lists branch tips, fetch brings objects by id. A hit was served by Workers Cache. Tap a row for its wire details.

Remote
https://gitlab.com/gitlab-org/cli
Ref
refs/heads/main
Commit
0dd7574dce9e385c5c30540e6c15657adc6bdce9
cf-ray
a5e28a95dd75bd4a
Request
c118acea…
Protocol
v2 · sha1
Agent
git/2.56.g1891de4-Linux
Filter
advertised
Fetch
shallow wait-for-done filter
Capabilities
agent ls-refs fetch server-option object-format