Reverted python upgrade for now

This commit is contained in:
krateng 2021-12-26 20:22:17 +01:00
parent 84e8ac0139
commit f56e23db1e
2 changed files with 11 additions and 6 deletions

View File

@ -9,12 +9,17 @@ try:
VERSIONSTR = metadata['version']
HOMEPAGE = metadata['urls']['homepage']
except:
# package distributrion
from importlib import metadata
VERSIONSTR = metadata.version('maloja')
urls = metadata.metadata('maloja').get_all('Project-URL')
urls = [e.split(', ') for e in urls]
HOMEPAGE = [e[1] for e in urls if e[0] == 'homepage'][0]
from pkg_resources import get_distribution
pkg = get_distribution('maloja') # also contains a metadata
VERSIONSTR = pkg.version
#urls = metadata.metadata('maloja').get_all('Project-URL')
#urls = [e.split(', ') for e in urls]
#HOMEPAGE = [e[1] for e in urls if e[0] == 'homepage'][0]
# hardcode this for now
HOMEPAGE = "https://github.com/krateng/maloja"
VERSION = VERSIONSTR.split('.')

View File

@ -3,7 +3,7 @@ name = "maloja"
version = "2.13.4"
description = "Self-hosted music scrobble database"
readme = "./README.md"
requires-python = ">=3.8"
requires-python = ">=3.6"
license = { file="./LICENSE" }
authors = [ { name="Johannes Krattenmacher", email="maloja@dev.krateng.ch" } ]