vektra / mockery

A mock code autogenerator for Go
https://vektra.github.io/mockery/
BSD 3-Clause "New" or "Revised" License
5.8k stars 395 forks source link

error: package "context" without types was imported #751

Closed MuhammadAndriJP closed 5 months ago

MuhammadAndriJP commented 5 months ago

Description

i've got error when generate mockery

mockery --all --output=action/mocks
26 Jan 24 13:21 WIB INF Starting mockery dry-run=false version=v3.0.0-alpha.0
26 Jan 24 13:21 WIB INF Walking dry-run=false version=v3.0.0-alpha.0
2024/01/26 13:21:11 internal error: package "context" without types was imported from "github.com/MuhAndriJP/reku/action/chef"

i've tried in 2.40.1, runing without error but there is no file mock generated

Mockery Version

v3.0.0-alpha.0

Golang Version

go 1.21.6

Installation Method

Steps to Reproduce

  1. mockery --all --output=action/mocks
  2. got error

Expected Behavior

generating file mock without error

Actual Behavior

got error like this

2024/01/26 13:21:11 internal error: package "context" without types was imported from "github.com/MuhAndriJP/reku/action/chef"