Skip to content

Commit d3401b6

Browse files
chore: remove the artifact upload limit from CLI side (#187)
This limit is enforced on the server side. Signed-off-by: Sourya Vatsyayan <sourya@deepsource.io> Signed-off-by: Sourya Vatsyayan <sourya@deepsource.io>
1 parent 7d9ac55 commit d3401b6

2 files changed

Lines changed: 2 additions & 8 deletions

File tree

command/report/constants.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,5 @@ Notes:
2929
Documentation:
3030
https://deepsource.io/docs/cli#report
3131
`
32-
reportGraphqlQuery = "mutation($input: CreateArtifactInput!) {\r\n createArtifact(input: $input) {\r\n ok\r\n error\r\n }\r\n}"
33-
maxArtifactUploadSize = 20000000
32+
reportGraphqlQuery = "mutation($input: CreateArtifactInput!) {\r\n createArtifact(input: $input) {\r\n ok\r\n error\r\n }\r\n}"
3433
)

command/report/report.go

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -173,18 +173,13 @@ func (opts *ReportOptions) Run() int {
173173

174174
if reportCommandValueFile != "" {
175175
// Check file size
176-
fileStat, err := os.Stat(reportCommandValueFile)
176+
_, err := os.Stat(reportCommandValueFile)
177177
if err != nil {
178178
fmt.Println("DeepSource error | Error | Unable to read specified value file: " + reportCommandValueFile)
179179
sentry.CaptureException(err)
180180
return 1
181181
}
182182

183-
if fileStat.Size() > maxArtifactUploadSize {
184-
fmt.Println("DeepSource | Error | Value file too large. Should be less than 20 Megabytes")
185-
return 1
186-
}
187-
188183
valueBytes, err := ioutil.ReadFile(reportCommandValueFile)
189184
if err != nil {
190185
fmt.Println("DeepSource error| Error | Unable to read specified value file: ", reportCommandValueFile)

0 commit comments

Comments
 (0)