简体   繁体   中英

How to run Python code from GitHub actions

Introduction

In my project, I want to run Python from GitHub workflow, but when I run it, it shows an error.

Showed error:

Run python ../main.py
python: can't open file '../main.py': [Errno 2] No such file or directory
Error: Process completed with exit code 2.

*before I test main.py instead of ../main.py

But he shows a another error:

Run python main.py
Traceback (most recent call last):
Valeur out : 311
  File "main.py", line 9, in <module>
    lineSplit = open("log", "r").readline().split(' ')
FileNotFoundError: [Errno 2] No such file or directory: 'log'
Error: Process completed with exit code 1.

The link to the project

https://github.com/MathieuSoysal/bot-area

Someone have the solution to this problem?

the error said No such file or directory: 'log' which means you need to add log file to the project

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM