Skip to content

Updgrade to the latest base version #1

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

Open
wants to merge 122 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
122 commits
Select commit Hold shift + click to select a range
a0e86f2
fix TypeError: NoneType takes no arguments
Denkneb Mar 23, 2022
883eb55
black reformat
Denkneb Mar 24, 2022
4feb8d8
Merge pull request #58 from Denkneb/patch-1
timthelion Mar 24, 2022
618b382
Add apps file to avoid underscores in admin app label.
marksweb Mar 28, 2022
a4716ea
Load celery model choices in the form, not the model.
marksweb Mar 28, 2022
28df695
Specify a choice field on the form to avoid a text input.
marksweb Mar 28, 2022
e9f9dab
Ran black.
marksweb Mar 28, 2022
d2fdeb0
Added editorconfig and pre-commit black hook.
marksweb Mar 28, 2022
09745de
Added pyupgrade & ran it for 3.7+
marksweb Mar 28, 2022
05627f8
Added & ran pre-commit-hooks with useful checks
marksweb Mar 28, 2022
14e50e6
Added & ran flake8
marksweb Mar 28, 2022
7161243
Remove unnecessary choices from import job model.
marksweb Mar 28, 2022
3bba544
Add github action for flake8 checks and more python testing for travis
marksweb Mar 28, 2022
0568578
Remove python 3.10 from travis - not available
marksweb Mar 28, 2022
5de5236
Updated black to match pre-commit
marksweb Mar 28, 2022
ef6528b
Revert change in smoke test, now with noqa
marksweb Mar 28, 2022
99c429a
Change travis distro for python 3.10
marksweb Mar 28, 2022
997b0d9
Update postgres port for focal distro
marksweb Mar 28, 2022
4cf747a
Travis database user/port changes
marksweb Mar 28, 2022
0130676
Revert move to ubuntu 20.04
marksweb Mar 28, 2022
a7f556b
Remove pip cache from github action
marksweb Mar 28, 2022
e9ab6e0
Update python trove classifiers to match those tested against.
marksweb Mar 28, 2022
68c42cb
Merge pull request #60 from marksweb/fix/52
timthelion Mar 29, 2022
1ef2ae6
Added pypi workflows
marksweb Mar 29, 2022
839e592
Fix for dry_run when diff is skipped (#63)
marksweb Mar 30, 2022
00fc48f
Merge pull request #64 from marksweb/fix/63
timthelion Mar 30, 2022
ae5cb85
Merge pull request #62 from marksweb/feat/pypi-actions
timthelion Mar 31, 2022
2668331
Create SHOWCASE_AND_THANKS.md
timthelion Apr 1, 2022
581b4ad
Update README.rst
timthelion Apr 1, 2022
0eba680
Fix for git describe during the automated pypi builds
marksweb Apr 1, 2022
eee21e7
Merge pull request #65 from marksweb/fix/auto-build
timthelion Apr 2, 2022
2b75e2b
Update publish-to-test-pypi.yml
timthelion Apr 2, 2022
7f2c5ba
Update setup.py
timthelion Apr 2, 2022
154ff83
Update setup.py
timthelion Apr 2, 2022
ea56fc6
Update setup.py
timthelion Apr 2, 2022
9ba068a
Update setup.py
timthelion Apr 2, 2022
5b59dcf
Update setup.py
timthelion Apr 2, 2022
98c4ea6
Update publish-to-test-pypi.yml
timthelion Apr 2, 2022
292254e
Update publish-to-live-pypi.yml
timthelion Apr 2, 2022
cb40cbb
Add pypi badge to readme
timthelion Apr 2, 2022
9698a56
Checkout all history and tags.
marksweb Apr 2, 2022
4754b99
Header was wrong its LGPL3
timthelion Apr 2, 2022
7f1b2b2
Header was wrong its LGPL3
timthelion Apr 2, 2022
d52a8b6
Added queryset customisation for celery export job
Apr 8, 2022
69ec0a5
Merge pull request #69 from xalien10/ft/customise-export-queryset
timthelion Apr 8, 2022
1ecd38a
Documentation added for customising model queryset for celery export job
Apr 8, 2022
69b4838
Merge pull request #71 from xalien10/docs/customise-export-queryset
timthelion Apr 8, 2022
2007313
Bump django from 3.2.7 to 3.2.13 in /example
dependabot[bot] Apr 22, 2022
2967833
Use gettext_lazy for Django 4 #67
frabyn Apr 27, 2022
e9cd01b
Replace deprecated force_text with force_str
frabyn Apr 28, 2022
74ba22a
Merge pull request #66 from marksweb/feat/workflow-fetch-all
timthelion May 30, 2022
c7fd103
Merge pull request #72 from auto-mat/dependabot/pip/example/django-3.…
timthelion May 30, 2022
25546dc
Merge pull request #73 from frabyn/django-4-compat
timthelion May 30, 2022
f5d8871
Improve and document docker-compose development environment
timthelion May 30, 2022
34b319c
Update README.rst
timthelion Jun 12, 2022
aaf4e47
Create CODE_OF_CONDUCT.md
timthelion Jun 12, 2022
645283a
Advertise commercial support
timthelion Jun 12, 2022
272cbcb
Update README.rst
timthelion Jun 12, 2022
9cb6b20
Bump django from 3.2.13 to 3.2.15 in /example
dependabot[bot] Aug 11, 2022
f41360d
Merge pull request #78 from auto-mat/dependabot/pip/example/django-3.…
timthelion Dec 19, 2022
dfad399
Bump django from 3.2.15 to 3.2.16 in /example
dependabot[bot] Dec 19, 2022
5347419
Merge pull request #85 from auto-mat/dependabot/pip/example/django-3.…
timthelion Dec 19, 2022
a1e01f3
Bump django from 3.2.16 to 3.2.18 in /example
dependabot[bot] Feb 15, 2023
1ecabe2
Default import mode configuration added
Mar 2, 2023
4e3e973
Merge pull request #88 from auto-mat/dependabot/pip/example/django-3.…
timthelion Mar 2, 2023
1f02c4a
Update README.rst
timthelion Mar 2, 2023
afe519b
Merge pull request #90 from xalien10/default_settings_for_import
timthelion Mar 2, 2023
f52326f
use template to send mail for export job completion
Jaspreet-singh-1032 Mar 26, 2023
e347b0f
fixed flake8 issues and added html2text to setup.py dependencies
Jaspreet-singh-1032 Mar 26, 2023
083aafe
Merge pull request #91 from Jaspreet-singh-1032/issue-83-use-template…
timthelion Mar 26, 2023
d6243e7
added documentation
Jaspreet-singh-1032 Mar 27, 2023
8a37502
Merge pull request #92 from Jaspreet-singh-1032/issue-83-use-template…
timthelion Mar 27, 2023
256acd8
error fix in readme
Jaspreet-singh-1032 Mar 28, 2023
2d5755d
Merge pull request #94 from Jaspreet-singh-1032/issue-83-use-template…
timthelion Mar 28, 2023
87bb13f
Weird typo in code of conduct :O
timthelion Apr 8, 2023
65ed15a
added translation in portuguese
May 17, 2023
dde72db
Merge pull request #99 from Ubiwhere/feat/translations
timthelion May 20, 2023
4e49658
Add missing migration
jacklinke May 27, 2023
c98ed0e
Merge pull request #100 from jacklinke/add_missing_migration
timthelion May 28, 2023
1cb2857
Add Basque localization
urtzai Jun 7, 2023
5928884
translatable email template
urtzai Jun 7, 2023
918410c
Optional function to exclude some DEFAULT_FORMATS
urtzai Jun 7, 2023
f7a01be
function rewrited in more pythonic way
urtzai Jun 7, 2023
03dc463
get_formats conditional fixed
urtzai Jun 7, 2023
4ab9cd0
removed translatable template + black
urtzai Jun 8, 2023
3937528
treat templates and locale directories as sub-module
Jaspreet-singh-1032 Jul 7, 2023
0df1fdf
added MANIFEST.in to include data files
Jaspreet-singh-1032 Jul 9, 2023
9eddf39
Merge pull request #103 from Jaspreet-singh-1032/fixes-101-convert-di…
timthelion Jul 9, 2023
b4232e0
Necesary changes for the PR acceptance
urtzai Jul 17, 2023
aa8fb58
fix README tablib URL
urtzai Jul 17, 2023
234e93e
Merge pull request #102 from urtzai/master
timthelion Jul 17, 2023
b3273d3
add customizable storage backend configurable via IMPORT_EXPORT_CELER…
zachbellay Jul 29, 2023
5a54a81
Merge pull request #105 from zachbellay/feat/customizable-storage-bac…
timthelion Jul 29, 2023
a08f82d
Underline two short errors are sadistic bs.
timthelion Jul 29, 2023
e7bc39c
Fix AttributeError if IMPORT_EXPORT_CELERY_STORAGE is not defined in …
zachbellay Jul 31, 2023
066bf85
add configurable soft and hard time limits for import and export tasks
zachbellay Jul 31, 2023
a8738b1
delete uploaded file on import job delete
Jaspreet-singh-1032 Aug 5, 2023
86664b3
Merge pull request #106 from zachbellay/patch-1
Jaspreet-singh-1032 Aug 5, 2023
97589eb
Merge pull request #108 from Jaspreet-singh-1032/104-delete-uploaded-…
timthelion Aug 5, 2023
f6744d9
added try except for import file delete
Jaspreet-singh-1032 Aug 5, 2023
4e92ed1
Merge pull request #109 from Jaspreet-singh-1032/add-try-except-for-a…
timthelion Aug 7, 2023
d8357e7
Fix: Lazy-initialize storage class to prevent unwanted migration gene…
samupl Oct 13, 2023
90a34d5
add support for Django 4.2 storages
PetrDlouhy Nov 14, 2023
71885dd
Merge pull request #107 from rinse-inc/feat/customize-global-soft-tim…
timthelion Dec 2, 2023
f86afdb
Manage custom storage class using django.core.files.storage.storages …
JMSoler7 Feb 19, 2024
2064e2d
Merge pull request #116 from JMSoler7/fix/warn_storages
timthelion Apr 12, 2024
c4340d0
Bump django from 3.2.18 to 3.2.19 in /example (#98)
dependabot[bot] Apr 15, 2024
825484d
Bump pygments from 2.10.0 to 2.15.0 in /example
dependabot[bot] Apr 15, 2024
2017a76
Bump django from 3.2.19 to 3.2.25 in /example
dependabot[bot] Apr 15, 2024
1ea5a06
update publish-to-pypi actions
PetrDlouhy May 20, 2024
7678b58
Bumped version for normal release.
PetrDlouhy May 20, 2024
80a1ebb
fix flake8 errors
PetrDlouhy May 20, 2024
eb8fa0c
Revert "fix flake8 errors"
PetrDlouhy May 20, 2024
5a9bab6
Revert "Bumped version for normal release."
PetrDlouhy May 20, 2024
c2302df
fix tests
PetrDlouhy May 22, 2024
244b008
establish GitHub actions testing with TOX
PetrDlouhy May 22, 2024
c554263
re-enable Codecov
PetrDlouhy May 24, 2024
7a9ec54
fix #115 correctly
PetrDlouhy May 22, 2024
37d2c96
Handle ValidationErrors having just plain messages list
ikseek Sep 27, 2024
f58ed82
add configurable email on completion for export job
KarimTayie Nov 22, 2024
6e3abd4
Merge pull request #132 from ikseek/master
timthelion Feb 7, 2025
a46ef09
Merge pull request #134 from KarimTayie/email_on_completion_setting
timthelion Feb 7, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[run]
omit =
*/virtualenvs/*,
*/migrations/*,
*/site-packages/*
include = import_export_celery/*
plugins =
django_coverage_plugin
branch = True
23 changes: 23 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# editorconfig.org

root = true

[*]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true

[*.py]
max_line_length = 150

[*.{scss,js,html}]
max_line_length = 150

[*.rst]
max_line_length = 150

[*.yml]
indent_size = 2
105 changes: 105 additions & 0 deletions .github/workflows/linters.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,105 @@
name: CI

on: [push, pull_request]

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

jobs:
test:
runs-on: ubuntu-latest

services:
postgres:
image: postgres:13
ports:
- 5432:5432
env:
POSTGRES_DB: pguser
POSTGRES_USER: pguser
POSTGRES_PASSWORD: foobar
options: >-
--health-cmd "pg_isready -U pguser"
--health-interval 10s
--health-timeout 5s
--health-retries 5

redis:
image: redis:latest
ports:
- 6379:6379
options: >-
--health-cmd "redis-cli ping"
--health-interval 10s
--health-timeout 5s
--health-retries 5

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", "5.1"]
exclude:
- python-version: "3.8"
django-version: "5.0"
- python-version: "3.8"
django-version: "5.1"

- python-version: "3.9"
django-version: "5.0"
- python-version: "3.9"
django-version: "5.1"

- python-version: "3.11"
django-version: "3.2"

- python-version: "3.12"
django-version: "3.2"
- python-version: "3.12"
django-version: "4.0"

steps:
- uses: actions/checkout@v2

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install tox tox-gh-actions

- name: Run Tox
env:
DJANGO_VERSION: ${{ matrix.django-version }}
run: |
PYTHON_VERSION=`echo ${{ matrix.python-version }} | sed 's/\.//'`
DJANGO_VERSION=`echo $DJANGO_VERSION | sed 's/\.//'`
tox -e py${PYTHON_VERSION}-django${DJANGO_VERSION}

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: coverage.xml
fail_ci_if_error: true

flake8:
name: flake8
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.9
- run: pip install --upgrade flake8
- name: flake8
uses: liskin/gh-problem-matcher-wrap@v1
with:
linters: flake8
run: flake8
42 changes: 42 additions & 0 deletions .github/workflows/publish-to-live-pypi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: Publish Python 🐍 distributions 📦 to pypi

on:
release:
types:
- published

jobs:
build-n-publish:
name: Build and publish Python 🐍 distributions 📦 to pypi
runs-on: ubuntu-latest
environment: pypi
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Python 3.9
uses: actions/setup-python@v3
with:
python-version: 3.9

- name: Install pypa/build
run: >-
python -m
pip install
build
--user
- name: Build a binary wheel and a source tarball
run: >-
python -m
build
--sdist
--wheel
--outdir dist/
.

- name: Publish distribution 📦 to PyPI
if: startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
43 changes: 43 additions & 0 deletions .github/workflows/publish-to-test-pypi.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
name: Publish Python 🐍 distributions 📦 to TestPyPI

on:
push:
branches:
- master

jobs:
build-n-publish:
name: Build and publish Python 🐍 distributions 📦 to TestPyPI
environment: pypi-test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Set up Python 3.9
uses: actions/setup-python@v3
with:
python-version: 3.9

- name: Install pypa/build
run: >-
python -m
pip install
build
--user
- name: Build a binary wheel and a source tarball
run: >-
python -m
build
--sdist
--wheel
--outdir dist/
.

- name: Publish distribution 📦 to Test PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.TEST_PYPI_API_TOKEN }}
repository_url: https://test.pypi.org/legacy/
skip_existing: true
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ dist/
example/django-import-export-celery-import-change-summaries/
example/django-import-export-celery-import-jobs/
example/django-import-export-celery-export-jobs/
pipenv/
pyenv/
django_import_export_celery.egg-info/
db/
.idea/
33 changes: 33 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
default_language_version:
python: python3.7

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.1.0
hooks:
- id: check-added-large-files
- id: check-case-conflict
- id: check-merge-conflict
- id: end-of-file-fixer
- id: trailing-whitespace

- repo: https://github.com/asottile/pyupgrade
rev: v2.31.1
hooks:
- id: pyupgrade
args: [--py37-plus]

- repo: https://github.com/psf/black
rev: 22.3.0
hooks:
- id: black

- repo: https://github.com/PyCQA/flake8
rev: 4.0.1
hooks:
- id: flake8
additional_dependencies:
- flake8-bugbear
- flake8-comprehensions
- flake8-tidy-imports
- flake8-typing-imports
6 changes: 5 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,19 @@ env:
global:
- DATABASE_NAME="travis_ci"
- DATABASE_USER="postgres"
- DATABASE_PORT=5432
- DATABASE_HOST=""
- DATABASE_PASSWORD=""
- DJANGO_SETTINGS_MODULE="project.settings"
- SECRET_KEY="sadfjasasdfasdfsadfsadfsadfeq"

matrix:
- DJANGO_VERSION="Django==3.1"
- DJANGO_VERSION="Django==3.2"
python:
- "3.7"
- "3.8"
- "3.9"
# - "3.10"
install:
- pip install poetry
- cd example
Expand Down
1 change: 1 addition & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Please follow the spirit of [The PSF code of conduct](https://www.python.org/psf/conduct/) and try to be nice.
3 changes: 2 additions & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
FROM python:3.7
RUN pip3 install poetry celery
RUN apt-get update ; apt-get install -yq python3-psycopg2 gdal-bin
RUN useradd test
ARG UID
RUN useradd test --uid $UID
RUN chsh test -s /bin/bash
3 changes: 3 additions & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
recursive-include import_export_celery/static *.js *.css *.map *.png *.ico *.eot *.svg *.ttf *.woff *.woff2
recursive-include import_export_celery/templates *.html
recursive-include import_export_celery/locale *.mo
37 changes: 7 additions & 30 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,31 +1,8 @@
VERSION = $(shell git describe --abbrev=0 --tags)
REPO_FILES ?= git ls-files -z | xargs --null -I '{}' find '{}' -type f -print0
REPO_TXT_FILES ?= git ls-files -z | xargs --null -I '{}' find '{}' -type f -print0 | egrep -zZv '(png|svg)$$'
docker-compose: Dockerfile
mkdir -p pyenv
mkdir -p db
sudo docker-compose build --build-arg UID=$(shell id -u)
sudo docker-compose up -d web postgres
sudo docker exec -it django-import-export-celery_web_1 /proj/setup-dev-env.sh
sudo docker-compose down

packages: clean
python3 setup.py bdist_wheel
git archive --format=tar.gz $(VERSION) > dist/django-import-export-celery-$(VERSION).tar.gz
cd dist ; gpg --detach-sign -a *.whl
cd dist ; gpg --detach-sign -a *.tar.gz

deploy-pypi:
twine upload dist/*.whl
twine upload dist/*.whl.asc

deploy: deploy-pypi
echo Deployed

clean:
rm -r dist ; exit 0
rm -r django_import_export_celery.egg-info ; exit 0
rm -r build ; exit 0

qa: qa-miscellaneous qa-https-everywhere

qa-miscellaneous:
$(REPO_TXT_FILES) | grep -zZv 'setup.py$$' | xargs --null sed -i 's#LGPL\s*v3#LGPL-3.0#g;'

qa-https-everywhere:
$(REPO_TXT_FILES) | xargs --null sed --regexp-extended --in-place 's#http(:\\?/\\?/)(momentjs\.com|overpass-turbo\.eu|www\.gnu\.org|stackoverflow\.com|(:?www\.)?openstreetmap\.(org|de)|nominatim\.openstreetmap\.org|taginfo\.openstreetmap\.org|wiki\.openstreetmap\.org|josm.openstreetmap.de|www.openstreetmap.org\\/copyright|github\.com|xkcd\.com|www\.heise\.de|www\.readthedocs\.org|askubuntu\.com|xpra\.org|docker\.com|linuxcontainers\.org|www\.ecma-international\.org|www\.w3\.org|example\.com|www\.example\.com)#https\1\2#g;'
$(REPO_TXT_FILES) | xargs --null sed -i 's#http://overpass-api\.de#https://overpass-api.de#g;'
$(REPO_TXT_FILES) | xargs --null sed --regexp-extended --in-place 's#http://(\w+\.wikipedia\.org)#https://\1#g;'
Loading