-
Notifications
You must be signed in to change notification settings - Fork 19
Update django-livefield to poetry #64
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
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,89 @@ | ||
| name: Client Build, Publish, and Release | ||
|
|
||
| on: | ||
| workflow_dispatch: | ||
| inputs: | ||
| tag: | ||
| description: "Release tag (for example: 1.1.1)" | ||
| required: true | ||
| type: string | ||
| release_name: | ||
| description: "Release name (defaults to tag if empty)" | ||
| required: false | ||
| default: "" | ||
| type: string | ||
| prerelease: | ||
| description: "Mark as prerelease" | ||
| required: true | ||
| default: false | ||
| type: boolean | ||
|
|
||
| jobs: | ||
| build: | ||
| name: Build package distributions | ||
| runs-on: ubuntu-latest | ||
| permissions: | ||
| contents: read | ||
| steps: | ||
| - name: Checkout code | ||
| uses: actions/checkout@v4 | ||
| - name: Set up Python | ||
| uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: "3.11" | ||
| - name: Install Poetry | ||
| run: | | ||
| make poetry | ||
| - name: Install dependencies | ||
| run: | | ||
| make install-build | ||
| - name: Build package | ||
| run: | | ||
| make build | ||
| - name: Upload dist artifacts | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: python-dist | ||
| path: dist/* | ||
| if-no-files-found: error | ||
|
|
||
| pypi-publish: | ||
| name: Upload release to public PyPI | ||
| runs-on: ubuntu-latest | ||
| needs: build | ||
| environment: | ||
| name: pypi | ||
| url: https://pypi.org/p/django-livefield | ||
| permissions: | ||
| id-token: write | ||
| steps: | ||
| - name: Download dist artifacts | ||
| uses: actions/download-artifact@v4 | ||
| with: | ||
| name: python-dist | ||
| path: dist | ||
| - name: Publish package distributions to PyPI | ||
| uses: pypa/gh-action-pypi-publish@release/v1 | ||
|
|
||
| create-github-release: | ||
| name: Create GitHub release | ||
| runs-on: ubuntu-latest | ||
| needs: | ||
| - pypi-publish | ||
| permissions: | ||
| contents: write | ||
| steps: | ||
| - name: Download dist artifacts | ||
| uses: actions/download-artifact@v4 | ||
| with: | ||
| name: python-dist | ||
| path: dist | ||
| - name: Create release | ||
| uses: softprops/action-gh-release@v2 | ||
| with: | ||
| tag_name: ${{ inputs.tag }} | ||
| name: ${{ inputs.release_name || inputs.tag }} | ||
| target_commitish: ${{ github.sha }} | ||
| prerelease: ${{ inputs.prerelease }} | ||
| generate_release_notes: true | ||
| files: dist/* | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,85 @@ | ||
| name: Python Version Tests | ||
|
|
||
| on: | ||
| push: | ||
| branches: ["master"] | ||
| pull_request: | ||
| branches: ["master"] | ||
| workflow_dispatch: | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| build: | ||
| runs-on: ubuntu-latest | ||
| strategy: | ||
| fail-fast: false | ||
| matrix: | ||
| python-version: ['3.8', '3.9', '3.10', '3.11', '3.12'] | ||
| django-version: ['3.2', '4.0', '4.1', '4.2', '5.0'] | ||
| exclude: | ||
| - python-version: '3.8' | ||
| django-version: '5.0' | ||
| - python-version: '3.9' | ||
| django-version: '5.0' | ||
| - python-version: '3.11' | ||
| django-version: '3.2' | ||
| - python-version: '3.11' | ||
| django-version: '4.0' | ||
| - python-version: '3.12' | ||
| django-version: '3.2' | ||
| - python-version: '3.12' | ||
| django-version: '4.0' | ||
| - python-version: '3.12' | ||
| django-version: '4.1' | ||
| services: | ||
| postgres: | ||
| image: postgres:12 | ||
| ports: | ||
| - 5432:5432 | ||
| options: >- | ||
| --health-cmd=pg_isready | ||
| --health-interval=10s | ||
| --health-timeout=5s | ||
| --health-retries=5 | ||
| env: | ||
| POSTGRES_DB: testdb | ||
| POSTGRES_USER: postgres | ||
| POSTGRES_PASSWORD: postgres | ||
| mysql: | ||
| image: mysql:8 | ||
| ports: | ||
| - 3306:3306 | ||
| options: >- | ||
| --health-cmd="mysqladmin ping" | ||
| --health-interval=10s | ||
| --health-timeout=5s | ||
| --health-retries=5 | ||
| env: | ||
| MYSQL_USER: travis | ||
| MYSQL_PASSWORD: travis | ||
| MYSQL_ALLOW_EMPTY_PASSWORD: true | ||
| MYSQL_DATABASE: test_testdb | ||
|
Comment on lines
+18
to
+63
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. runs the tests the same as the repo did before |
||
|
|
||
| steps: | ||
| - uses: actions/checkout@v4 | ||
| - name: Set up Python ${{ matrix.python-version }} | ||
| uses: actions/setup-python@v5 | ||
| with: | ||
| python-version: ${{ matrix.python-version }} | ||
| - name: Install Poetry | ||
| run: | | ||
| make poetry | ||
| - name: Install dependencies | ||
| run: | | ||
| make install-dev | ||
| - name: Pin Django version | ||
| run: | | ||
| poetry run pip install "Django==${{ matrix.django-version }}" | ||
| - name: Lint with flake8 and pylint | ||
| run: | | ||
| make lint | ||
| - name: Test with custom bootstrap runner | ||
| run: | | ||
| make test | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| Developed and maintained by [Hearsay Social, Inc.](http://hearsaysocial.com). | ||
|
|
||
| ## Contributors | ||
|
|
||
| - [Adam DePue](http://github.com/adepue) | ||
| - [Akshay Shah](http://github.com/akshayjshah) | ||
| - [Cordelia Notbohm](http://github.com/cnotbohm) | ||
| - [John Lynn](http://github.com/jlynn) | ||
| - [Dylan Verheul](http://github.com/dyve) | ||
| - [Grant McConnaughey](http://github.com/grantmcconnaughey) | ||
| - [Luke Burden](http://github.com/lukeburden) | ||
| - [James Addison](http://github.com/jaddison) | ||
| - [Krisztian Csizmazia](http://github.com/csizmaziakiki) |
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,75 @@ | ||
| # Changelog | ||
|
|
||
| ## 4.2.0 | ||
| - Migrate to Poetry for building and publishing | ||
|
|
||
| ## 4.1.0 | ||
|
|
||
| - Add support for Python 3.12 | ||
| - Add support for Django 5.0 | ||
|
|
||
| ## 4.0.0 | ||
|
|
||
| - Add support for Python 3.8 - 3.11 | ||
| - Add support for Django 4.1 and 4.2 | ||
| - Remove support for old Django versions | ||
| - Remove support for old Python versions | ||
|
|
||
| ## 3.3.0 | ||
|
|
||
| - Django 3.x support | ||
| - switch to BooleanField as base (Django 4.x deprecation) | ||
|
|
||
| ## 3.2.1 | ||
|
|
||
| - Fix rST formatting in this file to pass PyPI rendering check | ||
|
|
||
| ## 3.2.0 (Not released) | ||
|
|
||
| - Support Django 2.2 | ||
| - Support Python 3.7 | ||
| - Fix metadata to remove deprecated Django versions | ||
| - Expand travis tests for versions and database engines | ||
| - Remove obsolete pylint suppressions | ||
| - Thanks to [@shurph](https://github.com/shurph) for the above! | ||
|
|
||
| ## 3.1.0 | ||
|
|
||
| - Fix [deprecation of context param for Field.from_db_value](https://code.djangoproject.com/ticket/28370) | ||
| - Support for Django 2.1 (Thanks [@lukeburden](https://github.com/lukeburden) | ||
| - Switch tests suite to use pytest | ||
| - Remove pylint-django plugin, no longer needed | ||
|
|
||
| ## 3.0.0 | ||
|
|
||
| - Add support for Python 3.6 | ||
| - Add support for Django 2.0 | ||
| - Remove support for Python 3.4 | ||
| - Remove support for old Django versions | ||
| - Remove GIS | ||
|
|
||
| ## 2.5.0 (Not released) | ||
|
|
||
| - Added official Python 3 support. | ||
| - Re-added support for Django 1.8. Now supports Django 1.8 and 1.9. | ||
|
|
||
| ## 2.4.0 (2016-02-11) | ||
|
|
||
| - Drop support for Django 1.8 | ||
| - Add number of affected rows for delete methods (hard_delete, soft_delete, delete). Note: Django 1.9+ only. | ||
|
|
||
| ## 2.1.0 (2014-09-04) | ||
|
|
||
| - Add support for Django 1.7. | ||
|
|
||
| ## 2.0.0 (2014-07-13) | ||
|
|
||
| - Renamed top-level namespace to `livefield`. | ||
| - Restructured internally to match Django convention. | ||
| - Added GIS support. | ||
| - Added South support. | ||
|
|
||
| ## 1.0.0 (2014-02-14) | ||
|
|
||
| - Initial release. | ||
| - Separated existing code from main application repository. |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This action follows our old process, publish to pypi first, then create a github release, but does it all manually for us
only users with write access to the repo will be able to call the action