Skip to content
This repository was archived by the owner on Jan 13, 2024. It is now read-only.

Commit cfcfae2

Browse files
committed
update config and fix import
1 parent 5f5d9ad commit cfcfae2

File tree

4 files changed

+8
-7
lines changed

4 files changed

+8
-7
lines changed

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[tool.black]
22
line-length = 79
33
skip-string-normalization = true
4-
target-version = ["py36", "py37", "py38", "py39"]
4+
target-version = ["py37", "py38", "py39", "py310"]
55
include = ".py$"
66
exclude = "migrations"
77

twootfeed/config.example.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,12 @@ mastodon:
1414
feed:
1515
language: 'fr'
1616
author_name: ''
17-
feed_url: 'http://localhost:5000/'
17+
feed_url: 'http://localhost:8080'
1818
timezone: 'Europe/Paris'
1919
text_length_limit: 100
2020
max_items: 20
2121
token: ''
2222
app:
23-
host: '0.0.0.0'
23+
host: 'localhost'
2424
port: '8080'
25-
# nb_workers: 4 # if not defined, the number is defined by the app
25+
nb_workers: 2 # if not defined, the number is calculated by the app

twootfeed/config.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
import os
22

33
from twootfeed import param
4-
from twootfeed.tests.data import TEST_TOKEN
54

65
if os.getenv('TWOOTFEED_SETTINGS') == 'TestingConfig':
6+
from twootfeed.tests.data import TEST_TOKEN
7+
78
param['feed']['token'] = TEST_TOKEN
89

910

twootfeed/tests/data.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@
2727
'feed': {
2828
'language': 'fr',
2929
'author_name': '',
30-
'feed_url': 'http://localhost:5000/',
30+
'feed_url': 'http://localhost:8080',
3131
'timezone': 'Europe/Paris',
3232
'text_length_limit': 100,
3333
'max_items': max_items,
3434
'token': TEST_TOKEN,
3535
},
36-
'app': {'host': '0.0.0.0', 'port': '8080'},
36+
'app': {'host': 'localhost', 'port': '8080', 'nb_workers': 2},
3737
}
3838

3939
invalid_param: Dict = deepcopy(init_param)

0 commit comments

Comments
 (0)