I have the following Go code executing an external Python script.
package main
import (
"log"
"os"
"os/exec"
"fmt"
)
func main(){
//Call Python script
cmd := exec.Command(`C:\Python35\python35.exe`, `C:\...\py_file.py`)
cmd.Stdout = os.Stdout
cmd.Stderr = os.Stderr
log.Println(cmd.Run())
}
It causes this error within the Py file:
ImportError: No module named 'youtube_transcript_api'
However, if I run the Py file by itself, it works perfectly fine. It should output JSON.
Am I missing something? Let me know if you need more info!
Thank you so much, M2com