From fd0539ef7d7b45ed8689a6d9299a4a08be9bbba9 Mon Sep 17 00:00:00 2001 From: zhenghaoz Date: Tue, 1 Aug 2023 21:14:14 +0800 Subject: [PATCH] Add CONTRIBUTING.md (#4) --- .github/workflows/ci.yml | 3 +- CONTRIBUTING.md | 48 +++++++++++++++++++ tests/config.toml => config.toml | 0 .../docker-compose.yml => docker-compose.yml | 2 +- setup.py | 4 +- 5 files changed, 52 insertions(+), 5 deletions(-) create mode 100644 CONTRIBUTING.md rename tests/config.toml => config.toml (100%) rename tests/docker-compose.yml => docker-compose.yml (95%) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 41ea26b..7a72c25 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -14,11 +14,10 @@ jobs: name: test (Python ${{ matrix.python-version }}) strategy: matrix: - python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"] + python-version: ["3.8", "3.9", "3.10", "3.11"] steps: - uses: actions/checkout@v2 - name: Build the stack - working-directory: ./tests run: docker-compose up -d - name: Check the deployed service health uses: jtalk/url-health-check-action@v2 diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..842004a --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,48 @@ +# Contribution Guide + +Welcome and thank you for considering contributing to PyGorse! + +Reading and following these guidelines will help us make the contribution process easy and effective for everyone involved. It also communicates that you agree to respect the time of the developers managing and developing these open source projects. In return, we will reciprocate that respect by addressing your issue, assessing changes, and helping you finalize your pull requests. + +## Getting Started + +### Setup Develop Environment + +These following installations are required: + +- **Python 3.8+**: The minimum version of Python required to run PyGorse. +- **Docker Compose**: Start a local Gorse cluster for testing. + +After installing the required software, run the following commands: + +```bash +# Install tox +pip install tox + +# Start a local Gorse cluster +docker-compose up -d +``` + +### Run Unit Tests + +```bash +tox +``` + +## Your First Contribution + +### Contribution Workflow + +To contribute to the Gorse code base, please follow the workflow as defined in this section. + +- Fork the repository to your own Github account +- Make commits and add test case if the change fixes a bug or adds new functionality. +- Run tests and make sure all the tests are passed. +- Push your changes to a topic branch in your fork of the repository. +- Submit a pull request. + +This is a rough outline of what a contributor's workflow looks like. Thanks for your contributions! + +## Getting Help + +Join us in the [Discord](https://discord.gg/x6gAtNNkAE) and post your question in the `#developers` channel. diff --git a/tests/config.toml b/config.toml similarity index 100% rename from tests/config.toml rename to config.toml diff --git a/tests/docker-compose.yml b/docker-compose.yml similarity index 95% rename from tests/docker-compose.yml rename to docker-compose.yml index b5047ee..93db50a 100644 --- a/tests/docker-compose.yml +++ b/docker-compose.yml @@ -18,7 +18,7 @@ services: MYSQL_PASSWORD: gorse_pass gorse: - image: zhenghaoz/gorse-in-one:nightly + image: zhenghaoz/gorse-in-one restart: unless-stopped ports: - 8086:8086 diff --git a/setup.py b/setup.py index a9c13ac..0f02eec 100644 --- a/setup.py +++ b/setup.py @@ -7,10 +7,10 @@ long_description = (this_directory / "README.md").read_text() setup(name='PyGorse', - version='0.4.7', + version='0.4.8', description='Python SDK for gorse recommender system', packages=['gorse'], - install_requires=['requests~=2.14.0', 'aiohttp~=3.8.3'], + install_requires=['requests>=2.14.0', 'aiohttp>=3.8.3'], long_description=long_description, long_description_content_type='text/markdown' )