mirror of
https://github.com/adulau/napkin-text-analysis.git
synced 2024-11-21 09:27:07 +00:00
chg: [redis] use default Redis port
This commit is contained in:
parent
793ce3228f
commit
afc06a3850
2 changed files with 7 additions and 3 deletions
4
.github/workflows/python-app.yml
vendored
4
.github/workflows/python-app.yml
vendored
|
@ -15,6 +15,10 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: zhulik/redis-action@1.1.0
|
||||
with:
|
||||
redis version: '5'
|
||||
number of databases: 100
|
||||
- uses: actions/checkout@v2
|
||||
- name: Set up Python 3.8
|
||||
uses: actions/setup-python@v2
|
||||
|
|
|
@ -39,14 +39,14 @@ if args.f is None:
|
|||
# args.full_labels = True
|
||||
|
||||
if not args.binary:
|
||||
redisdb = redis.Redis(host="localhost", port=6380, db=5, encoding='utf-8', decode_responses=True)
|
||||
redisdb = redis.Redis(host="localhost", port=6379, db=5, encoding='utf-8', decode_responses=True)
|
||||
else:
|
||||
redisdb = redis.Redis(host="localhost", port=6380, db=5)
|
||||
redisdb = redis.Redis(host="localhost", port=6379, db=5)
|
||||
|
||||
try:
|
||||
redisdb.ping()
|
||||
except:
|
||||
print("Redis database on port 6380 is not running...", file=sys.stderr)
|
||||
print("Redis database on port 6379 is not running...", file=sys.stderr)
|
||||
sys.exit()
|
||||
|
||||
if not args.no_flushdb:
|
||||
|
|
Loading…
Reference in a new issue