fix(metagpt)

add OPEN_API_MODEL key to test; convert to `bkpyvenv`.

closes #4704
This commit is contained in:
Jacob Heider 2024-01-04 14:11:49 -05:00 committed by Jacob Heider
parent eaf5f19362
commit e910345810
2 changed files with 18 additions and 6 deletions

View file

@ -1,7 +1,7 @@
### Setup your OPENAI_API_KEY, or make sure it existed in the env ### Setup your OPENAI_API_KEY and OPENAI_API_MODEL, or make sure they exist in the env
``` ```
mkdir ~/.metagpt/key.yaml mkdir ~/.metagpt/key.yaml
cp config/config.yaml ~/.metagpt/key.yaml cp config/config.yaml ~/.metagpt/key.yaml
vim ~/.metagpt/key.yaml vim ~/.metagpt/key.yaml
``` ```

View file

@ -1,19 +1,31 @@
distributable: distributable:
url: https://github.com/geekan/MetaGPT/archive/v{{version}}.tar.gz url: https://github.com/geekan/MetaGPT/archive/v{{version}}.tar.gz
strip-components: 1 strip-components: 1
display-name: MetaGPT display-name: MetaGPT
versions: versions:
github: geekan/MetaGPT github: geekan/MetaGPT
dependencies: dependencies:
# Python 3.12 ==> ModuleNotFoundError: No module named 'distutils' pkgx.sh: ^1
python.org: '>=3.9<3.12'
build: build:
- python-venv.sh {{prefix}}/bin/metagpt dependencies:
# Python 3.12 ==> ModuleNotFoundError: No module named 'distutils'
python.org: '>=3.9<3.12'
script:
- bkpyvenv stage {{prefix}} {{version}}
- ${{prefix}}/venv/bin/pip install .
- bkpyvenv seal {{prefix}} metagpt
provides: provides:
- bin/metagpt - bin/metagpt
test: test:
env: env:
OPENAI_API_KEY: metaGptTestKey OPENAI_API_KEY: metaGptTestKey
OPENAI_API_MODEL: gpt-4-1106-preview
script: script:
# for more tests we need to set valid OPENAI_API_KEY with gpt-4 access
- metagpt --help | grep 'Run a startup. Be a boss.' - metagpt --help | grep 'Run a startup. Be a boss.'
# for more tests we need to set valid OPENAI_API_KEY with gpt-4 access