Skip to content
GitHub Actions / golangci failed May 14, 2024 in 1s

reviewdog [golangci] report

reported by reviewdog 🐶

Findings (27)

controller/adapter.go|4 col 2| could not import github.com/traPtitech/anke-to/model (-: # github.com/traPtitech/anke-to/model
model/questionnaires_impl.go|326 col 34| undefined: targetGroups
model/questionnaires_impl.go|326 col 64| undefined: administoratorGroups) (typecheck)
controller/questionnaire.go|83 col 27| q.GetRespondentInfos undefined (type Questionnaire has no field or method GetRespondentInfos) (typecheck)
controller/questionnaire.go|122 col 29| q.InsertQuestionnaire undefined (type Questionnaire has no field or method InsertQuestionnaire) (typecheck)
controller/questionnaire.go|137 col 11| q.InsertTargets undefined (type Questionnaire has no field or method InsertTargets) (typecheck)
controller/questionnaire.go|142 col 11| q.InsertTargetGroups undefined (type Questionnaire has no field or method InsertTargetGroups) (typecheck)
controller/questionnaire.go|157 col 11| q.InsertAdministrators undefined (type Questionnaire has no field or method InsertAdministrators) (typecheck)
controller/questionnaire.go|162 col 11| q.InsertAdministratorGroups undefined (type Questionnaire has no field or method InsertAdministratorGroups) (typecheck)
controller/questionnaire.go|188 col 87| q.GetQuestionnaireInfo undefined (type Questionnaire has no field or method GetQuestionnaireInfo) (typecheck)
controller/questionnaire.go|198 col 87| q.GetQuestionnaireInfo undefined (type Questionnaire has no field or method GetQuestionnaireInfo) (typecheck)
controller/questionnaire.go|213 col 12| q.UpdateQuestionnaire undefined (type Questionnaire has no field or method UpdateQuestionnaire) (typecheck)
controller/questionnaire.go|218 col 11| q.DeleteTargets undefined (type Questionnaire has no field or method DeleteTargets) (typecheck)
controller/questionnaire.go|223 col 11| q.DeleteTargetGroups undefined (type Questionnaire has no field or method DeleteTargetGroups) (typecheck)
controller/questionnaire.go|233 col 11| q.InsertTargets undefined (type Questionnaire has no field or method InsertTargets) (typecheck)
controller/questionnaire.go|238 col 11| q.InsertTargetGroups undefined (type Questionnaire has no field or method InsertTargetGroups) (typecheck)
controller/questionnaire.go|243 col 11| q.DeleteAdministrators undefined (type Questionnaire has no field or method DeleteAdministrators) (typecheck)
controller/questionnaire.go|248 col 11| q.DeleteAdministratorGroups undefined (type Questionnaire has no field or method DeleteAdministratorGroups) (typecheck)
controller/questionnaire.go|258 col 11| q.InsertAdministrators undefined (type Questionnaire has no field or method InsertAdministrators) (typecheck)
controller/questionnaire.go|263 col 11| q.InsertAdministratorGroups undefined (type Questionnaire has no field or method InsertAdministratorGroups) (typecheck)
controller/questionnaire.go|287 col 11| q.DeleteTargets undefined (type Questionnaire has no field or method DeleteTargets) (typecheck)
controller/questionnaire.go|293 col 11| q.DeleteAdministrators undefined (type Questionnaire has no field or method DeleteAdministrators) (typecheck)
model/questionnaires_impl.go|326 col 34| undefined: targetGroups
model/questionnaires_impl.go|326 col 64| undefined: administoratorGroups) (typecheck)
model/questionnaires_impl.go|326 col 34| undefined: targetGroups (typecheck)
model/questionnaires_impl.go|326 col 34| undefined: targetGroups
model/questionnaires_impl.go|326 col 64| undefined: administoratorGroups) (typecheck)

Filtered Findings (29)

main.go|14 col 2| could not import github.com/traPtitech/anke-to/model (-: # github.com/traPtitech/anke-to/model
model/questionnaires_test.go|1056 col 188| not enough arguments in call to questionnaireImpl.GetQuestionnaires
router/middleware.go|12 col 2| could not import github.com/traPtitech/anke-to/model (-: # github.com/traPtitech/anke-to/model
router/middleware.go|128 col 21| m.CheckQuestionnaireAdmin undefined (type *Middleware has no field or method CheckQuestionnaireAdmin) (typecheck)
router/middleware.go|160 col 24| m.GetRespondent undefined (type *Middleware has no field or method GetRespondent) (typecheck)
router/middleware.go|186 col 39| m.GetResponseReadPrivilegeInfoByResponseID undefined (type *Middleware has no field or method GetResponseReadPrivilegeInfoByResponseID) (typecheck)
router/middleware.go|224 col 24| m.GetRespondent undefined (type *Middleware has no field or method GetRespondent) (typecheck)
router/middleware.go|270 col 21| m.CheckQuestionAdmin undefined (type *Middleware has no field or method CheckQuestionAdmin) (typecheck)
router/middleware.go|301 col 39| m.GetResponseReadPrivilegeInfoByQuestionnaireID undefined (type *Middleware has no field or method GetResponseReadPrivilegeInfoByQuestionnaireID) (typecheck)
router/questionnaires.go|185 col 28| q.InsertQuestionnaire undefined (type *Questionnaire has no field or method InsertQuestionnaire) (typecheck)
router/questionnaires.go|191 col 12| q.InsertTargets undefined (type *Questionnaire has no field or method InsertTargets) (typecheck)
router/questionnaires.go|197 col 11| q.InsertAdministrators undefined (type *Questionnaire has no field or method InsertAdministrators) (typecheck)
router/questionnaires.go|253 col 64| q.GetQuestionnaireInfo undefined (type *Questionnaire has no field or method GetQuestionnaireInfo) (typecheck)
router/questionnaires.go|304 col 37| q.CheckQuestionNum undefined (type *Questionnaire has no field or method CheckQuestionNum) (typecheck)
router/questionnaires.go|322 col 15| q.CheckNumberValid undefined (type *Questionnaire has no field or method CheckNumberValid) (typecheck)
router/questionnaires.go|328 col 19| q.InsertQuestion undefined (type *Questionnaire has no field or method InsertQuestion) (typecheck)
router/questionnaires.go|337 col 16| q.InsertOption undefined (type *Questionnaire has no field or method InsertOption) (typecheck)
router/questionnaires.go|343 col 15| q.InsertScaleLabel undefined (type *Questionnaire has no field or method InsertScaleLabel) (typecheck)
router/questionnaires.go|354 col 15| q.InsertValidation undefined (type *Questionnaire has no field or method InsertValidation) (typecheck)
router/questionnaires.go|412 col 11| q.UpdateQuestionnaire undefined (type *Questionnaire has no field or method UpdateQuestionnaire) (typecheck)
router/questionnaires.go|418 col 11| q.DeleteTargets undefined (type *Questionnaire has no field or method DeleteTargets) (typecheck)
router/questionnaires.go|424 col 11| q.InsertTargets undefined (type *Questionnaire has no field or method InsertTargets) (typecheck)
router/questionnaires.go|430 col 11| q.DeleteAdministrators undefined (type *Questionnaire has no field or method DeleteAdministrators) (typecheck)
router/questionnaires.go|436 col 11| q.InsertAdministrators undefined (type *Questionnaire has no field or method InsertAdministrators) (typecheck)
router/questionnaires.go|472 col 11| q.DeleteTargets undefined (type *Questionnaire has no field or method DeleteTargets) (typecheck)
router/questionnaires.go|478 col 11| q.DeleteAdministrators undefined (type *Questionnaire has no field or method DeleteAdministrators) (typecheck)
router/questionnaires.go|552 col 20| q.GetOptions undefined (type *Questionnaire has no field or method GetOptions) (typecheck)
router/questionnaires.go|562 col 24| q.GetScaleLabels undefined (type *Questionnaire has no field or method GetScaleLabels) (typecheck)
router/questionnaires.go|572 col 24| q.GetValidations undefined (type *Questionnaire has no field or method GetValidations) (typecheck)

Annotations

Check failure on line 4 in controller/adapter.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/adapter.go#L4

could not import github.com/traPtitech/anke-to/model (-: # github.com/traPtitech/anke-to/model
Raw output
controller/adapter.go:4:2: could not import github.com/traPtitech/anke-to/model (-: # github.com/traPtitech/anke-to/model

Check failure on line 326 in model/questionnaires_impl.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] model/questionnaires_impl.go#L326

undefined: targetGroups
Raw output
model/questionnaires_impl.go:326:34: undefined: targetGroups

Check failure on line 326 in model/questionnaires_impl.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] model/questionnaires_impl.go#L326

undefined: administoratorGroups) (typecheck)
Raw output
model/questionnaires_impl.go:326:64: undefined: administoratorGroups) (typecheck)
	"github.com/traPtitech/anke-to/model"
	^

Check failure on line 83 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L83

q.GetRespondentInfos undefined (type Questionnaire has no field or method GetRespondentInfos) (typecheck)
Raw output
controller/questionnaire.go:83:27: q.GetRespondentInfos undefined (type Questionnaire has no field or method GetRespondentInfos) (typecheck)
		myRespondents, err := q.GetRespondentInfos(ctx.Request().Context(), userID, questionnaire.ID)
		                        ^

Check failure on line 122 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L122

q.InsertQuestionnaire undefined (type Questionnaire has no field or method InsertQuestionnaire) (typecheck)
Raw output
controller/questionnaire.go:122:29: q.InsertQuestionnaire undefined (type Questionnaire has no field or method InsertQuestionnaire) (typecheck)
		questionnaireID, err := q.InsertQuestionnaire(ctx, params.Title, params.Description, responseDueDateTime, convertResponseViewableBy(params.ResponseViewableBy))
		                          ^

Check failure on line 137 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L137

q.InsertTargets undefined (type Questionnaire has no field or method InsertTargets) (typecheck)
Raw output
controller/questionnaire.go:137:11: q.InsertTargets undefined (type Questionnaire has no field or method InsertTargets) (typecheck)
		err = q.InsertTargets(ctx, questionnaireID, allTargetUsers)
		        ^

Check failure on line 142 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L142

q.InsertTargetGroups undefined (type Questionnaire has no field or method InsertTargetGroups) (typecheck)
Raw output
controller/questionnaire.go:142:11: q.InsertTargetGroups undefined (type Questionnaire has no field or method InsertTargetGroups) (typecheck)
		err = q.InsertTargetGroups(ctx, questionnaireID, params.Targets.Groups)
		        ^

Check failure on line 157 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L157

q.InsertAdministrators undefined (type Questionnaire has no field or method InsertAdministrators) (typecheck)
Raw output
controller/questionnaire.go:157:11: q.InsertAdministrators undefined (type Questionnaire has no field or method InsertAdministrators) (typecheck)
		err = q.InsertAdministrators(ctx, questionnaireID, allAdminUsers)
		        ^

Check failure on line 162 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L162

q.InsertAdministratorGroups undefined (type Questionnaire has no field or method InsertAdministratorGroups) (typecheck)
Raw output
controller/questionnaire.go:162:11: q.InsertAdministratorGroups undefined (type Questionnaire has no field or method InsertAdministratorGroups) (typecheck)
		err = q.InsertAdministratorGroups(ctx, questionnaireID, params.Admins.Groups)
		        ^

Check failure on line 188 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L188

q.GetQuestionnaireInfo undefined (type Questionnaire has no field or method GetQuestionnaireInfo) (typecheck)
Raw output
controller/questionnaire.go:188:87: q.GetQuestionnaireInfo undefined (type Questionnaire has no field or method GetQuestionnaireInfo) (typecheck)
	questionnaireInfo, targets, targetGroups, admins, adminGroups, respondents, err := q.GetQuestionnaireInfo(c.Request().Context(), questionnaireID)
	                                                                                     ^

Check failure on line 198 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L198

q.GetQuestionnaireInfo undefined (type Questionnaire has no field or method GetQuestionnaireInfo) (typecheck)
Raw output
controller/questionnaire.go:198:87: q.GetQuestionnaireInfo undefined (type Questionnaire has no field or method GetQuestionnaireInfo) (typecheck)
	questionnaireInfo, targets, targetGroups, admins, adminGroups, respondents, err := q.GetQuestionnaireInfo(ctx.Request().Context(), questionnaireID)
	                                                                                     ^

Check failure on line 213 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L213

q.UpdateQuestionnaire undefined (type Questionnaire has no field or method UpdateQuestionnaire) (typecheck)
Raw output
controller/questionnaire.go:213:12: q.UpdateQuestionnaire undefined (type Questionnaire has no field or method UpdateQuestionnaire) (typecheck)
		err := q.UpdateQuestionnaire(ctx, params.Title, params.Description, responseDueDateTime, string(params.ResponseViewableBy), questionnaireID)
		         ^

Check failure on line 218 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L218

q.DeleteTargets undefined (type Questionnaire has no field or method DeleteTargets) (typecheck)
Raw output
controller/questionnaire.go:218:11: q.DeleteTargets undefined (type Questionnaire has no field or method DeleteTargets) (typecheck)
		err = q.DeleteTargets(ctx, questionnaireID)
		        ^

Check failure on line 223 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L223

q.DeleteTargetGroups undefined (type Questionnaire has no field or method DeleteTargetGroups) (typecheck)
Raw output
controller/questionnaire.go:223:11: q.DeleteTargetGroups undefined (type Questionnaire has no field or method DeleteTargetGroups) (typecheck)
		err = q.DeleteTargetGroups(ctx, questionnaireID)
		        ^

Check failure on line 233 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L233

q.InsertTargets undefined (type Questionnaire has no field or method InsertTargets) (typecheck)
Raw output
controller/questionnaire.go:233:11: q.InsertTargets undefined (type Questionnaire has no field or method InsertTargets) (typecheck)
		err = q.InsertTargets(ctx, questionnaireID, allTargetUsers)
		        ^

Check failure on line 238 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L238

q.InsertTargetGroups undefined (type Questionnaire has no field or method InsertTargetGroups) (typecheck)
Raw output
controller/questionnaire.go:238:11: q.InsertTargetGroups undefined (type Questionnaire has no field or method InsertTargetGroups) (typecheck)
		err = q.InsertTargetGroups(ctx, questionnaireID, params.Targets.Groups)
		        ^

Check failure on line 243 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L243

q.DeleteAdministrators undefined (type Questionnaire has no field or method DeleteAdministrators) (typecheck)
Raw output
controller/questionnaire.go:243:11: q.DeleteAdministrators undefined (type Questionnaire has no field or method DeleteAdministrators) (typecheck)
		err = q.DeleteAdministrators(ctx, questionnaireID)
		        ^

Check failure on line 248 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L248

q.DeleteAdministratorGroups undefined (type Questionnaire has no field or method DeleteAdministratorGroups) (typecheck)
Raw output
controller/questionnaire.go:248:11: q.DeleteAdministratorGroups undefined (type Questionnaire has no field or method DeleteAdministratorGroups) (typecheck)
		err = q.DeleteAdministratorGroups(ctx, questionnaireID)
		        ^

Check failure on line 258 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L258

q.InsertAdministrators undefined (type Questionnaire has no field or method InsertAdministrators) (typecheck)
Raw output
controller/questionnaire.go:258:11: q.InsertAdministrators undefined (type Questionnaire has no field or method InsertAdministrators) (typecheck)
		err = q.InsertAdministrators(ctx, questionnaireID, allAdminUsers)
		        ^

Check failure on line 263 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L263

q.InsertAdministratorGroups undefined (type Questionnaire has no field or method InsertAdministratorGroups) (typecheck)
Raw output
controller/questionnaire.go:263:11: q.InsertAdministratorGroups undefined (type Questionnaire has no field or method InsertAdministratorGroups) (typecheck)
		err = q.InsertAdministratorGroups(ctx, questionnaireID, params.Admins.Groups)
		        ^

Check failure on line 287 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L287

q.DeleteTargets undefined (type Questionnaire has no field or method DeleteTargets) (typecheck)
Raw output
controller/questionnaire.go:287:11: q.DeleteTargets undefined (type Questionnaire has no field or method DeleteTargets) (typecheck)
		err = q.DeleteTargets(c.Request().Context(), questionnaireID)
		        ^

Check failure on line 293 in controller/questionnaire.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] controller/questionnaire.go#L293

q.DeleteAdministrators undefined (type Questionnaire has no field or method DeleteAdministrators) (typecheck)
Raw output
controller/questionnaire.go:293:11: q.DeleteAdministrators undefined (type Questionnaire has no field or method DeleteAdministrators) (typecheck)
		err = q.DeleteAdministrators(c.Request().Context(), questionnaireID)
		        ^

Check failure on line 326 in model/questionnaires_impl.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] model/questionnaires_impl.go#L326

undefined: targetGroups
Raw output
model/questionnaires_impl.go:326:34: undefined: targetGroups

Check failure on line 326 in model/questionnaires_impl.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] model/questionnaires_impl.go#L326

undefined: administoratorGroups) (typecheck)
Raw output
model/questionnaires_impl.go:326:64: undefined: administoratorGroups) (typecheck)
	"github.com/traPtitech/anke-to/model"
	^

Check failure on line 326 in model/questionnaires_impl.go

See this annotation in the file changed.

@github-actions github-actions / golangci

[golangci] model/questionnaires_impl.go#L326

undefined: targetGroups (typecheck)
Raw output
model/questionnaires_impl.go:326:34: undefined: targetGroups (typecheck)
	return &questionnaire, targets, targetGroups, administrators, administoratorGroups, respondents, nil
	                                ^