Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
11 changes: 2 additions & 9 deletions .github/workflows/test_djelme.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,16 +26,9 @@ jobs:
test:
strategy:
matrix:
python: ['3.6', '3.7', '3.8', '3.9', '3.10']
django: ['1.11', '2.0', '2.1', '2.2', '3.0', '3.1', '3.2', '4.0', '4.1']
python: ['3.8', '3.9', '3.10']
django: ['3.2', '4.1']
# TODO: elasticsearch: ['6', '7', '8', '9']
exclude:
- {python: '3.6', django: '4.0'}
- {python: '3.6', django: '4.1'}
- {python: '3.7', django: '4.0'}
- {python: '3.7', django: '4.1'}
- {python: '3.10', django: '1.11'}
- {python: '3.10', django: '2.0'}
runs-on: ubuntu-20.04
services:
elasticsearch:
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ Django app for storing time-series metrics in Elasticsearch.

## Pre-requisites

* Python 2.7 or >=3.6
* Django 1.11 or 2.0
* Python >=3.10
* Django 4.2, 5.1, or 5.2
* Elasticsearch 6

## Install
Expand Down
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ services:
depends_on:
- elasticsearch
environment:
TOXENV: py39-django40
TOXENV: py310-django41
ELASTICSEARCH_HOST: elasticsearch:9200
volumes:
- ./:/code:cached
88 changes: 88 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
[project]
name = "django-elasticsearch-metrics"
version = "2022.0.6"
description = "Django app for storing time-series metrics in Elasticsearch."
authors = [
{name = "CenterForOpenScience", email = "[email protected]"}
]
readme = "README.md"
license = "MIT"
requires-python = ">=3.10"
keywords = [
"django",
"elastic",
"elasticsearch",
"elasticsearch-dsl",
"time-series",
"metrics",
"statistics",
]
classifiers = [
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Framework :: Django",
"Framework :: Django :: 1.11",
"Framework :: Django :: 2.0",
"Framework :: Django :: 2.1",
"Framework :: Django :: 2.2",
"Framework :: Django :: 3.0",
"Framework :: Django :: 3.1",
"Framework :: Django :: 3.2",
"Framework :: Django :: 4.0",
"Framework :: Django :: 4.1",
"Environment :: Web Environment",
"Intended Audience :: Developers",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"elasticsearch6-dsl>=6.3.0,<7.0.0",
]

[project.urls]
repository = "http://github.com/CenterForOpenScience/django-elasticsearch-metrics"
changelog = "https://github.com/CenterForOpenScience/django-elasticsearch-metrics/blob/master/CHANGELOG.md"

[dependency-groups]
tests = [
"pytest",
"mock",
"pytest-django==3.10.0",
"factory-boy==2.11.1",
]
lint = [
"flake8==5.0.4",
'flake8-bugbear==18.8.0; python_version >= "3.5"',
"pre-commit==2.17.0",
]
dev = [
{ include-group = "tests" },
{ include-group = "lint" },
"konch>=3.0.0",
"tox",
]

[tool.poetry.group.tests]
optional = true

[tool.poetry.group.lint]
optional = true

[tool.poetry.group.dev]
optional = true

[tool.poetry]
packages = [
{ include = "elasticsearch_metrics" }
]

[build-system]
requires = ["poetry-core>=2.0.0,<3.0.0"]
build-backend = "poetry.core.masonry.api"
3 changes: 0 additions & 3 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
[metadata]
license_file = LICENSE

[bdist_wheel]
universal=1

Expand Down
96 changes: 0 additions & 96 deletions setup.py

This file was deleted.

9 changes: 5 additions & 4 deletions testbox.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
FROM python:3.9-slim as testbox
FROM python:3.10-slim as testbox

RUN pip install poetry==2.2.1

RUN mkdir -p /code
WORKDIR /code
COPY ./ /code
RUN poetry install --with dev

RUN pip install .[dev]

CMD ["tox"]
CMD ["poetry", "run", "tox"]
5 changes: 4 additions & 1 deletion tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ envlist =

[testenv]
passenv=ELASTICSEARCH_HOST
extras = tests
dependency_groups =
tests
deps =
django111: Django>=1.11,<1.12
django20: Django>=2.0,<2.1
Expand All @@ -18,6 +19,8 @@ deps =
django41: Django>=4.1,<4.2
commands=
pytest {posargs}
allowlist_externals =
pytest

; NOTE: pre-commit runs both black and flake8
[testenv:lint]
Expand Down
Loading