Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for args to execute_python_file #3972

Merged
merged 47 commits into from
Sep 9, 2023

Conversation

MauroDruwel
Copy link
Contributor

Background

Auto-GPT couldn't run Python scripts when args were specified. Now it can!

Changes

Added args field, also made it optional so that it doesn't always need args.

Documentation

Added to the command explanation. Added the args field in the Python command.
Documented in the code as you can see below:
Screenshot from 2023-05-07 21-02-11

Test Plan

I was able to execute files with and without arguments in a Docker container.

PR Quality Checklist

  • [ x ] My pull request is atomic and focuses on a single change.
  • [ x ] I have thoroughly tested my changes with multiple different prompts.
  • [ x ] I have considered potential risks and mitigations for my changes.
  • [ x ] I have documented my changes clearly and comprehensively.
  • [ x ] I have not snuck in any "extra" small tweaks changes

@vercel
Copy link

vercel bot commented May 7, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 7, 2023 1:12am

@github-actions github-actions bot added the size/s label May 7, 2023
@Boostrix
Copy link
Contributor

Boostrix commented May 9, 2023

bateller
bateller previously approved these changes May 9, 2023
@vercel vercel bot temporarily deployed to Preview May 10, 2023 13:10 Inactive
Copy link
Member

@ntindle ntindle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add tests for this

@vercel
Copy link

vercel bot commented May 18, 2023

Deployment failed with the following error:

Resource is limited - try again in 26 minutes (more than 100, code: "api-deployments-free-per-day").

@codecov
Copy link

codecov bot commented May 18, 2023

Codecov Report

Patch coverage: 60.00% and project coverage change: +18.98% 🎉

Comparison is base (78a620c) 50.73% compared to head (d5c1ee0) 69.71%.
Report is 1588 commits behind head on master.

❗ Current head d5c1ee0 differs from pull request most recent head 648d124. Consider uploading reports for the commit 648d124 to get more accurate results

Additional details and impacted files
@@             Coverage Diff             @@
##           master    #3972       +/-   ##
===========================================
+ Coverage   50.73%   69.71%   +18.98%     
===========================================
  Files         128       72       -56     
  Lines        5517     3563     -1954     
  Branches      759      570      -189     
===========================================
- Hits         2799     2484      -315     
+ Misses       2507      889     -1618     
+ Partials      211      190       -21     
Files Changed Coverage Δ
autogpt/commands/execute_code.py 65.59% <60.00%> (-10.56%) ⬇️

... and 146 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ntindle ntindle dismissed their stale review May 18, 2023 17:16

Fixed request

@vercel
Copy link

vercel bot commented May 18, 2023

Deployment failed with the following error:

Resource is limited - try again in 20 minutes (more than 100, code: "api-deployments-free-per-day").

@github-actions github-actions bot added size/l and removed size/m labels May 18, 2023
@vercel
Copy link

vercel bot commented May 18, 2023

Deployment failed with the following error:

Resource is limited - try again in 4 minutes (more than 100, code: "api-deployments-free-per-day").

@Auto-GPT-Bot
Copy link
Contributor

You changed AutoGPT's behaviour. The cassettes have been updated and will be merged to the submodule when this Pull Request gets merged.

@Pwuts Pwuts changed the title 🎉 Python scripts can now be executed with arguments through Docker.🎉 Add support for args to execute_python_file Jun 21, 2023
autogpt/commands/execute_code.py Outdated Show resolved Hide resolved
@lc0rp lc0rp modified the milestones: v0.4.3 Release, v0.4.4 Release Jun 26, 2023
@lc0rp lc0rp modified the milestones: v0.4.4 Release, v0.4.5 Release Jul 6, 2023
@lc0rp lc0rp modified the milestones: v0.4.5 Release, v0.4.6 Release Jul 14, 2023
@lc0rp lc0rp modified the milestones: v0.4.6 Release, v0.4.7 Release Jul 22, 2023
@lc0rp lc0rp modified the milestones: v0.4.7 Release, v0.4.8 Aug 1, 2023
@MauroDruwel
Copy link
Contributor Author

I sincerely apologize for my delayed response. I was caught up in some commitments, and it completely slipped my mind. I've incorporated the necessary changes to make it compatible as both a list or a string. Should you encounter any problems, please don't hesitate to reach out to me. I'm here to assist! Thank you for your understanding.

@github-actions github-actions bot removed the conflicts Automatically applied to PRs with merge conflicts label Sep 9, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Sep 9, 2023

Conflicts have been resolved! 🎉 A maintainer will review the pull request shortly.

@Pwuts Pwuts merged commit 7780670 into Significant-Gravitas:master Sep 9, 2023
@Pwuts Pwuts assigned Pwuts and unassigned bfalans Sep 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

9 participants