...
 
Commits (3)
......@@ -9,9 +9,10 @@ test_buster:
image: $CI_REGISTRY_IMAGE/build:buster
stage: test
script:
- make ci_settings test
- make test
make_deb_package:
image: $CI_REGISTRY_IMAGE/build:buster
stage: build
tags:
- fast-io
......
......@@ -4,7 +4,7 @@ Small tornado service implementing the Thekno track service API.
# Run
Run with `python3 -m lohro_track_api` or `PYTHONPATH=. -m lohro_track_api` when
Run with `python3 -m lohro_track_api` or `PYTHONPATH=. -m lohro_track_api` in case
the library is not installed in your system. See `python3 -m lohro_track_api --help`
for available options.
......
......@@ -2,10 +2,10 @@ import datetime
class Track:
def __init__(self, pk, title, description, started_at):
def __init__(self, pk, artist, title, started_at):
self.id = pk
self.artist = artist
self.title = title
self.description = description
self.started_at = started_at
def __eq__(self, other):
......@@ -15,7 +15,8 @@ class Track:
return dict(
id=self.id,
title=self.title,
description=self.description,
artist=self.artist,
description=self.artist,
started_at=self.started_at.isoformat(),
finished_at=None,
cover_image=None,
......@@ -24,5 +25,5 @@ class Track:
@classmethod
def hydrate_from_db(cls, row):
pk, start, artist, title = row
return cls(pk, title, artist,
return cls(pk, artist, title,
datetime.datetime.fromtimestamp(start))