golang cannot find module for local path [duplicate]
问题 This question already has an answer here : How do I resolve “cannot find module for path X” importing a local Go module? (1 answer) Closed 15 days ago . I want to push out some of API, from main package into separate package: myapp/ main.go myapi/ myapi.go Inside main.go i have package main import "./myapi" ... And myapi.go just starts with: package myapi ... When I am trying to run main, it seems like it can't find my myapi #include . It gives me following error: D:\go\myapp> go run . build