Skip to content

Commit df2620d

Browse files
committed
features(ci) go to poetry
1 parent fa2b9df commit df2620d

File tree

7 files changed

+1180
-14
lines changed

7 files changed

+1180
-14
lines changed

.flake8

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,5 @@ ignore = E203, W503
33
max-line-length = 130
44
max-complexity = 16
55
buildins = CloudFoundryClient
6-
exclude = vendors,.git,.github,main/cloudfoundry_client/dropsonde,venv,.eggs,build
6+
exclude = vendors,.git,.github,cloudfoundry_client/dropsonde,.venv,.eggs,build
77

.github/workflows/pythonpackage.yml

+13-8
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
strategy:
1414
max-parallel: 1
1515
matrix:
16-
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
16+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
1717

1818
steps:
1919
- uses: actions/checkout@v4
@@ -23,14 +23,19 @@ jobs:
2323
with:
2424
python-version: ${{ matrix.python-version }}
2525

26-
- name: Install dependencies
27-
run: |
28-
python -m pip install --upgrade pip
29-
pip install -r requirements.txt
30-
pip install -r dev-requirements.txt
26+
- name: Install and configure Poetry
27+
uses: snok/install-poetry@v1
28+
with:
29+
virtual envs-create: true
30+
virtualenvs-in-project: true
31+
virtualenvs-path: .venv
32+
installer-parallel: true
33+
34+
- name: Install project
35+
run: poetry install --no-interaction
3136

3237
- name: Launch tests
33-
run: python setup.py test
38+
run: poetry run pytest
3439

3540
- name: Launch Linting
36-
run: flake8 --show-source --statistics
41+
run: poetry run flake8 --show-source --statistics

dev-requirements.txt

-3
This file was deleted.

poetry.lock

+1,121
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

poetry.toml

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
[virtualenvs]
2+
create = true
3+
in-project = true
4+
prefer-active-python = true
5+
prompt = "cf-python-client"

pyproject.toml

+40-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,43 @@ exclude = '''
44
^/(
55
(main\/cloudfoundry_client\/dropsonde.*)
66
)/
7-
'''
7+
'''
8+
9+
[tool.poetry]
10+
name = "cloudfoundry_client"
11+
version = "1.37.1"
12+
description = "A client library for CloudFoundry"
13+
authors = ["Benjamin Einaudi <[email protected]>"]
14+
readme = "README.rst"
15+
homepage = "https://pypi.org/project/cloudfoundry-client/"
16+
documentation = "https://pypi.org/project/cloudfoundry-client/"
17+
repository = "https://github.com/cloudfoundry-community/cf-python-client"
18+
keywords = ["cloudfoundry", "cf"]
19+
include = ["requirements.txt"]
20+
21+
[tool.poetry.dependencies]
22+
python = ">=3.9"
23+
aiohttp = ">=3.8.0"
24+
protobuf = ">= 3.20.0, < 6.0.0"
25+
oauth2-client= "1.4.2"
26+
websocket-client= "~1.8.0"
27+
PyYAML = ">=6.0"
28+
requests = ">=2.5.0"
29+
polling2= "0.5.0"
30+
31+
[tool.poetry.group.dev.dependencies]
32+
black= "24.4.2"
33+
flake8= "7.1.0"
34+
pytest = "~8.2.2"
35+
36+
[tool.poetry.scripts]
37+
cloudfoundry-client = "cloudfoundry_client.main.main:main"
38+
39+
[tool.pytest.ini_options]
40+
console_output_style = "count"
41+
pythonpath = [".", "tests",]
42+
testpaths = ["tests"]
43+
44+
[build-system]
45+
requires = ["poetry-core"]
46+
build-backend = "poetry.core.masonry.api"

requirements.txt

-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,3 @@ oauth2-client==1.4.2
44
websocket-client~=1.8.0
55
PyYAML>=6.0
66
requests>=2.5.0
7-
polling2==0.5.0

0 commit comments

Comments
 (0)