Closed HamzaETTH closed 1 year ago
Hmm that’s weird, I checked the engshell code and they don’t seem to do anything special. Are you running the latest commit of the main branch? I just removed a part of the prompt related to escaping newlines.
I think, it's thinking it will write the code, but calls execute_python
instead. Ran into it just now...
Your thought: I need to write the Flask app code with the required endpoint and back-end logic
Your command: execute_python
Cmd argument:
from flask import Flask, render_template, request, jsonify
import pyocr
I think, it's thinking it will write the code, but calls
execute_python
instead. Ran into it just now...Your thought: I need to write the Flask app code with the required endpoint and back-end logic Your command: execute_python Cmd argument: from flask import Flask, render_template, request, jsonify import pyocr
This seems like expected behavior. execute_python
takes an entire Python program as its argument.
Yeah but shouldn't it write the code first? Let me try again and investigate
@HamzaETTH I added some explicit instructions for how to treat newlines in Python code. It now seems to consistently produce working code on my Mac. Does it help on Windows?
Yeah but shouldn't it write the code first? Let me try again and investigate
No, the code gets passed directly to Python exec
.
@HamzaETTH #18 which should hopefully address the issue, please let me know if it works for you.
It's fixed ! Thank you.
Executing commands works fine but when trying to write a python script.
I've noticed that the generate file contain no new lines so execute_python fails and retry again and again . I've tried reminding the AI that this is running on a W10 machine to no avail so I'm guessing the issue lies in the script?
I've had no trouble running https://github.com/emcf/engshell but it does say "for any OS" .