报错Network Error: Request Failed

Aperta
#261 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
25/100
Tipo di issue
Bug
Chiarezza
Da chiarire
Stato di attività
Ferma
Stack tecnologico
python
Ambito
api

Direzione di ricerca

Start with PCAgent/api.py at line 62, where inference_chat prints completion, and trace how request failures are handled; run.py line 661 is the reported call site. Reproduce the repeated “Network Error: Request Failed” and inspect the relevant request configuration and error handling. Done means the failure cause is understood and the program reports it without the shown UnboundLocalError.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Image

PS E:\X-PLUG\PCAgent\MyPcAgent> python run.py --instruction="打开 “此电脑”" --mac 0
2026-03-02 17:30:50,933 - modelscope - INFO - PyTorch version 2.10.0 Found.
2026-03-02 17:30:50,934 - modelscope - INFO - Loading ast index from C:\Users\Administrator.cache\modelscope\ast_indexer
2026-03-02 17:30:51,125 - modelscope - INFO - Loading done! Current index file version is 1.15.0, with md5 c4022a2bbc7c06b7df540266ce6f1e75 and a total number of 980 components indexed
打开 此电脑
task_1/screenshot_1.png
Network Error:
Request Failed
Network Error:
Request Failed
Network Error:
Request Failed
Network Error:
Request Failed
Network Error:
Request Failed
Traceback (most recent call last):
File "E:\X-PLUG\PCAgent\MyPcAgent\run.py", line 661, in
output_action = inference_chat(chat_action, vl_model_version, API_url, token)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\X-PLUG\PCAgent\MyPcAgent\PCAgent\api.py", line 62, in inference_chat
print("completion"+completion)
^^^^^^^^^^
UnboundLocalError: cannot access local variable 'completion' where it is not associated with a value

纯小白,跪求作者大大回复

Lingua principale
Python
Stelle
9.3k
Fork
928
Merge medio
1g 2h
PR unite (30g)
3

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di X-PLUG/MobileAgent

Tutte le issue di X-PLUG/MobileAgent

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.