Issue When Analyzing any resource #167
Unanswered
ShoaibQureshi01
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi there,
i have installed the kube-copilot using helm with Azure OpenAI gpt-35-turbo-16k model. Now every other function is working fine except the analyze it is showing some python syntax error like this
here's the screenshot of the error
Got this in Logs of kube-copilot pod :-
"""
root@master:~/service# kubectl logs kube-copilot-6ff7b996c9-f2wbt
You can now view your Streamlit app in your browser.
Network URL: http://172.16.194.186:8501
External URL: http://110.235.219.135:8501
Observation: SyntaxError('invalid syntax', ('', 1, 9, 'kubectl get -n default Pod web -o yaml\n', 1, 12))
Thought:Could not parse LLM output: There seems to be a syntax error in the Python code. I need to fix the syntax error and try again.
Observation: There seems to be a syntax error in the Python code. I need to fix the syntax error and try again.
Thought:I need to fix the syntax error in the Python code and try again. The error is likely due to the fact that the command is not enclosed in quotes. I will enclose the command in quotes and try again.
"""
!!!
For reference here is the logs of diagnose function which is working fine
""""
Observation: {'api_version': 'v1',
'kind': 'Pod',
'metadata': {'annotations': {'kubectl.kubernetes.io/last-applied-configuration': '{"apiVersion":"v1","kind":"Pod","metadata":{"annotations":{},"labels":{"app":"httpd"},"name":"mypod","namespace":"default"},"spec":{"containers":[{"image":"httpd","name":"myhttpd","ports":[{"containerPort":80}]}],"nodeSelector":{"node":"mynode"}}}\n'},
'creation_timestamp': datetime.datetime(2023, 12, 14, 6, 24, 3, tzinfo=tzlocal()),
'deletion_grace_period_seconds': None,
'deletion_timestamp': None,
'finalizers': None,
'generate_name': None,
'generation': None,
'labels': {'app': 'httpd'},
'managed_fields': [{'api_version': 'v1',
......Output Ommited
From what i can think of is that the diagnose function is converting the prompt into python code but the analyze function is not, it is using the simple bash kubectl command. But i am not a developer and that is just a guess.
Any reply would be of help.
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions