Skip to content

A programming framework for agentic AI

cleanup

Chi Wang1517105c3aa2
diff --git a/.github/workflows/CD.yml b/.github/workflows/CD.yml
deleted file mode 100644
index 7cf8fe245..000000000
--- a/.github/workflows/CD.yml
+++ /dev/null
@@ -1,52 +0,0 @@
-# This workflows will build and upload a Python Package using Twine when a release is published
-# Conda-forge bot will pick up new PyPI version and automatically create new version
-# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
-
-name: CD
-
-on:
- release:
- types: [published]
-
-jobs:
- deploy:
- strategy:
- matrix:
- os: ['ubuntu-latest']
- python-version: [3.8]
- runs-on: ${{ matrix.os }}
- environment: package
- steps:
- - name: Checkout
- uses: actions/checkout@v3
- - name: Cache conda
- uses: actions/cache@v3
- with:
- path: ~/conda_pkgs_dir
- key: conda-${{ matrix.os }}-python-${{ matrix.python-version }}-${{ hashFiles('environment.yml') }}
- - name: Setup Miniconda
- uses: conda-incubator/setup-miniconda@v2
- with:
- auto-update-conda: true
- auto-activate-base: false
- activate-environment: hcrystalball
- python-version: ${{ matrix.python-version }}
- use-only-tar-bz2: true
- - name: Install from source
- # This is required for the pre-commit tests
- shell: pwsh
- run: pip install .
- - name: Conda list
- shell: pwsh
- run: conda list
- - name: Build
- shell: pwsh
- run: |
- pip install twine
- python setup.py sdist bdist_wheel
- - name: Publish to PyPI
- env:
- TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
- TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
- shell: pwsh
- run: twine upload dist/*
diff --git a/.github/workflows/python-package.yml b/.github/workflows/python-package.yml
index fd96f4cae..7cf8fe245 100644
--- a/.github/workflows/python-package.yml
+++ b/.github/workflows/python-package.yml
@@ -1,60 +1,52 @@
-# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
-# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
+# This workflows will build and upload a Python Package using Twine when a release is published
+# Conda-forge bot will pick up new PyPI version and automatically create new version
+# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries
-name: Build
+name: CD
on:
- push:
- branches: ['main']
- paths:
- - 'autogen/**'
- - 'test/**'
- - 'notebook/**'
- - '.github/workflows/python-package.yml'
- - 'setup.py'
- pull_request:
- branches: ['main']
- merge_group:
- types: [checks_requested]
-
-concurrency:
- group: ${{ github.workflow }}-${{ github.ref }}-${{ github.head_ref }}
- cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
+ release:
+ types: [published]
jobs:
- build:
-
- runs-on: ${{ matrix.os }}
+ deploy:
strategy:
- fail-fast: false
matrix:
- os: [ubuntu-latest, macos-latest, windows-2019]
- python-version: ["3.8", "3.9", "3.10"]
+ os: ['ubuntu-latest']
+ python-version: [3.8]
+ runs-on: ${{ matrix.os }}
+ environment: package
steps:
- - uses: actions/checkout@v3
- - name: Set up Python ${{ matrix.python-version }}
- uses: actions/setup-python@v4
+ - name: Checkout
+ uses: actions/checkout@v3
+ - name: Cache conda
+ uses: actions/cache@v3
with:
+ path: ~/conda_pkgs_dir
+ key: conda-${{ matrix.os }}-python-${{ matrix.python-version }}-${{ hashFiles('environment.yml') }}
+ - name: Setup Miniconda
+ uses: conda-incubator/setup-miniconda@v2
+ with:
+ auto-update-conda: true
+ auto-activate-base: false
+ activate-environment: hcrystalball
python-version: ${{ matrix.python-version }}
- - name: Install packages and dependencies
- run: |
- python -m pip install --upgrade pip wheel
- pip install -e .
- python -c "import autogen"
- pip install -e .[test]
- - name: Test with pytest
- if: matrix.python-version != '3.10'
+ use-only-tar-bz2: true
+ - name: Install from source
+ # This is required for the pre-commit tests
+ shell: pwsh
+ run: pip install .
+ - name: Conda list
+ shell: pwsh
+ run: conda list
+ - name: Build
+ shell: pwsh
run: |
- pytest test
- - name: Coverage
- if: matrix.python-version == '3.10'
- run: |
- pip install coverage
- coverage run -a -m pytest test
- coverage xml
- - name: Upload coverage to Codecov
- if: matrix.python-version == '3.10'
- uses: codecov/codecov-action@v3
- with:
- file: ./coverage.xml
- flags: unittests
+ pip install twine
+ python setup.py sdist bdist_wheel
+ - name: Publish to PyPI
+ env:
+ TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
+ TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
+ shell: pwsh
+ run: twine upload dist/*
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
new file mode 100644
index 000000000..a9f9f282c
--- /dev/null
+++ b/.github/workflows/test.yml
@@ -0,0 +1,59 @@
+# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
+# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
+
+name: Build
+
+on:
+ push:
+ branches: ['main']
+ paths:
+ - 'autogen/**'
+ - 'test/**'
+ - '.github/workflows/test.yml'
+ - 'setup.py'
+ pull_request:
+ branches: ['main']
+ merge_group:
+ types: [checks_requested]
+
+concurrency:
+ group: ${{ github.workflow }}-${{ github.ref }}-${{ github.head_ref }}
+ cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
+
+jobs:
+ build:
+
+ runs-on: ${{ matrix.os }}
+ strategy:
+ fail-fast: false
+ matrix:
+ os: [ubuntu-latest, macos-latest, windows-2019]
+ python-version: ["3.8", "3.9", "3.10"]
+ steps:
+ - uses: actions/checkout@v3
+ - name: Set up Python ${{ matrix.python-version }}
+ uses: actions/setup-python@v4
+ with:
+ python-version: ${{ matrix.python-version }}
+ - name: Install packages and dependencies
+ run: |
+ python -m pip install --upgrade pip wheel
+ pip install -e .
+ python -c "import autogen"
+ pip install -e .[test]
+ - name: Test with pytest
+ if: matrix.python-version != '3.10'
+ run: |
+ pytest test
+ - name: Coverage
+ if: matrix.python-version == '3.10'
+ run: |
+ pip install coverage
+ coverage run -a -m pytest test
+ coverage xml
+ - name: Upload coverage to Codecov
+ if: matrix.python-version == '3.10'
+ uses: codecov/codecov-action@v3
+ with:
+ file: ./coverage.xml
+ flags: unittests
diff --git a/setup.py b/setup.py
index 682b1088f..d9ae8805c 100644
--- a/setup.py
+++ b/setup.py
@@ -25,7 +25,7 @@ setuptools.setup(
name="AutoGen",
version=__version__,
author="AutoGen",
- author_email="[email protected]",
+ author_email="[email protected]",
description="Enabling Next-Gen LLM Applications via Multi-Agent Conversation Framework",
long_description=long_description,
long_description_content_type="text/markdown",