I am developing a custom beat and was testing the build on a clean directory when I hit a problem with glide. Note that I only have this problem with glide when using version 5.3 of beats. If I use version 5.2 glide does not have any problems.
In my beat's glide.yml file I had included beats like this:
- package: github.com/elastic/beats
version: ^5.1.4
subpackages:
- libbeat/beat
- libbeat/common
- libbeat/logp
- libbeat/publisher
When I did "glide up", glide selected version 5.3 of beats. Then it tried to import github.com/elastic/beats/libbeat/plugin. At that point, it printed the following error:
[DEBUG] Package github.com/elastic/beats/libbeat/beat imports github.com/elastic/beats/libbeat/plugin
[DEBUG] Missing github.com/elastic/beats/libbeat/plugin. Trying to resolve.
[DEBUG] Trying to open github.com/elastic/beats/libbeat/plugin (/Users/rebeccarelyea/.glide/cache/src/https-github.com-elastic-beats/libbeat/plugin)
[DEBUG] Package github.com/elastic/beats/libbeat/plugin imports github.com/elastic/beats/libbeat/logp
[DEBUG] Package github.com/elastic/beats/libbeat/plugin imports plugin
[DEBUG] Missing plugin. Trying to resolve.
[INFO] --> Fetching plugin.
[WARN] Unable to checkout plugin
[ERROR] Error looking for plugin: Cannot detect VCS
When I change my glide.yml file to this, glide is able to update successfully:
- package: github.com/elastic/beats
version: 5.2
subpackages:
- libbeat/beat
- libbeat/common
- libbeat/logp
- libbeat/publisher
Is this possibly because the load.go file in the plugin package also imports the plugin package?