Skip to content

Commit cac6050

Browse files
author
Joel Collins
committed
Merge remote-tracking branch 'origin/master' into gevent-pool
2 parents c705d50 + d279815 commit cac6050

File tree

4 files changed

+57
-3
lines changed

4 files changed

+57
-3
lines changed

.github/workflows/publish.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Publish
2+
3+
on:
4+
release:
5+
types: [published]
6+
7+
jobs:
8+
publish:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v1
12+
with:
13+
fetch-depth: 1
14+
15+
- name: Set up Python 3.7
16+
uses: actions/setup-python@v1
17+
with:
18+
python-version: 3.7
19+
20+
- name: Install Poetry
21+
uses: dschep/install-poetry-action@v1.3
22+
23+
- name: Set Poetry config
24+
env:
25+
POETRY_PYPI_TOKEN_PYPI: ${{ secrets.POETRY_PYPI_TOKEN_PYPI }}
26+
run: |
27+
poetry config virtualenvs.in-project false
28+
poetry config virtualenvs.path ~/.virtualenvs
29+
poetry config pypi-token.pypi "$POETRY_PYPI_TOKEN_PYPI"
30+
31+
- name: Install Dependencies
32+
run: poetry install
33+
if: steps.cache.outputs.cache-hit != 'true'
34+
35+
- name: Build with Poetry
36+
run: poetry build
37+
38+
- name: Publish with Poetry
39+
run: poetry publish

.github/workflows/ci.yml renamed to .github/workflows/test.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
1-
name: CI
1+
name: Test
22

3-
on: [push]
3+
on:
4+
push:
5+
release:
6+
types:
7+
- created
48

59
jobs:
610
test:

labthings/server/representations.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
from flask import make_response, current_app
2-
from json import dumps, JSONEncoder
2+
3+
# Flask JSON encoder so we get UUID, datetime etc support
4+
from flask.json import JSONEncoder
5+
from json import dumps
6+
37

48
from ..core.utilities import PY3
59

pyproject.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,14 @@
22
name = "labthings"
33
version = "0.4.0"
44
description = "Python implementation of LabThings, based on the Flask microframework"
5+
readme = "README.md"
6+
repository = "https://github.com/labthings/python-labthings/"
57
authors = ["jtc42 <jtc9242@gmail.com>"]
8+
classifiers = [
9+
"Topic :: System :: Hardware",
10+
"Topic :: Software Development :: Libraries :: Application Frameworks",
11+
"Topic :: Internet :: WWW/HTTP :: WSGI"
12+
]
613

714
[tool.poetry.dependencies]
815
python = "^3.6"

0 commit comments

Comments
 (0)