fittrackee: 0.11.2 -> 1.3.3 (#444673)

This commit is contained in:
dotlambda
2026-07-17 22:01:03 +00:00
committed by GitHub
4 changed files with 73 additions and 57 deletions
+1 -2
View File
@@ -146,8 +146,7 @@
### Breaking changes {#sec-nixpkgs-release-26.11-lib-breaking}
- Create the first release note entry in this section!
- `fittrackee` 1.0.0 now requires postgres with postgis. The [upgrade guide](https://docs.fittrackee.org/en/upgrading-to-1.0.0.html) has steps to prepare for this upgrade.
### Deprecations {#sec-nixpkgs-release-26.11-lib-deprecations}
+46 -31
View File
@@ -1,49 +1,51 @@
{
fetchFromGitHub,
fetchFromCodeberg,
fetchNpmDeps,
lib,
stdenv,
nodejs_24,
npmHooks,
postgresql,
postgresqlTestHook,
python3Packages,
}:
python3Packages.buildPythonApplication (finalAttrs: {
pname = "fittrackee";
version = "0.11.2";
version = "1.3.3";
pyproject = true;
src = fetchFromGitHub {
owner = "SamR1";
src = fetchFromCodeberg {
owner = "FitTrackee";
repo = "FitTrackee";
tag = "v${finalAttrs.version}";
hash = "sha256-A9gebHxNCpYUUIm7IjyySojIIyuTxfYCUeUufpUM1iA=";
hash = "sha256-XWR9gg52pfg0lHoFikQ2wVhvkPCTjTTndBYqBzYPB8s=";
};
makeCacheWritable = true;
npmRoot = "fittrackee_client";
npmDeps = fetchNpmDeps {
inherit (finalAttrs) pname version src;
hash = "sha256-HEgof2ln+mBxM63Dv8Lc/bfx3ozoJCRYYyJOz6jh+Vs=";
sourceRoot = "${finalAttrs.src.name}/fittrackee_client";
};
nativeBuildInputs = [
nodejs_24
npmHooks.npmConfigHook
];
preBuild = ''
pushd fittrackee_client
npm run build-only
popd
'';
build-system = [
python3Packages.poetry-core
];
# The upstream project changed the behavior of the CLI when --set-admin and --set-role are used together.
# Previously, it would raise an error, but now it issues a deprecation warning.
# This patch updates the test assertion to expect the new deprecation warning message.
# See upstream commit 6eda1b6119b3e41bdf8896e74b4a07d3c9e97609.
postPatch = ''
substituteInPlace fittrackee/tests/users/test_users_commands.py \
--replace '"--set-admin and --set-role can not be used together."' '"WARNING: --set-admin is deprecated. Please use --set-role option instead."'
'';
pythonRelaxDeps = [
"authlib"
"fitdecode"
"flask"
"flask-limiter"
"flask-migrate"
"nh3"
"lxml"
"pyopenssl"
"pytz"
"sqlalchemy"
"xmltodict"
];
pythonRelaxDeps = true;
dependencies =
with python3Packages;
@@ -53,21 +55,31 @@ python3Packages.buildPythonApplication (finalAttrs: {
click
dramatiq
dramatiq-abort
feedgenerator
fitdecode
flask
flask-babel
flask-bcrypt
flask-dramatiq
flask-limiter
flask-migrate
flask-sqlalchemy
geoalchemy2
geopandas
gpxpy
gunicorn
humanize
jsonschema
lxml
mistune
nh3
numpy
pandas
psycopg2-binary
pyjwt
pyopenssl
pyproj
python-magic
pytz
shortuuid
sqlalchemy
@@ -76,7 +88,9 @@ python3Packages.buildPythonApplication (finalAttrs: {
xmltodict
]
++ dramatiq.optional-dependencies.redis
++ flask-limiter.optional-dependencies.redis;
++ flask-limiter.optional-dependencies.redis
++ geoalchemy2.optional-dependencies.shapely
++ staticmap3.optional-dependencies.filecache;
pythonImportsCheck = [ "fittrackee" ];
@@ -84,7 +98,7 @@ python3Packages.buildPythonApplication (finalAttrs: {
pytestCheckHook
freezegun
postgresqlTestHook
postgresql
(postgresql.withPackages (ps: with ps; [ postgis ]))
time-machine
];
@@ -93,6 +107,7 @@ python3Packages.buildPythonApplication (finalAttrs: {
];
postgresqlTestSetupPost = ''
echo "CREATE EXTENSION postgis; CREATE EXTENSION postgis_topology;" | PGUSER=postgres psql test_db
export DATABASE_TEST_URL=postgresql://$PGUSER/$PGDATABASE?host=$PGHOST
'';
@@ -105,8 +120,8 @@ python3Packages.buildPythonApplication (finalAttrs: {
meta = {
description = "Self-hosted outdoor activity tracker";
homepage = "https://github.com/SamR1/FitTrackee";
changelog = "https://github.com/SamR1/FitTrackee/blob/${finalAttrs.src.tag}/CHANGELOG.md";
homepage = "https://docs.fittrackee.org/";
changelog = "https://codeberg.org/FitTrackee/FitTrackee/src/tag/${finalAttrs.src.tag}/CHANGELOG.md";
license = lib.licenses.agpl3Only;
maintainers = with lib.maintainers; [
tebriel
@@ -2,11 +2,13 @@
lib,
buildPythonPackage,
dramatiq,
fetchFromGitLab,
fetchFromGitHub,
flask-migrate,
flask-sqlalchemy,
flask,
httpx,
periodiq,
poetry-core,
hatchling,
postgresql,
postgresqlTestHook,
psycopg2,
@@ -16,35 +18,33 @@
requests,
}:
buildPythonPackage {
buildPythonPackage (finalAttrs: {
pname = "flask-dramatiq";
version = "0.6.0";
version = "0.8.0";
pyproject = true;
src = fetchFromGitLab {
owner = "bersace";
src = fetchFromGitHub {
owner = "pallets-eco";
repo = "flask-dramatiq";
rev = "840209e9bf582b4dda468e8bba515f248f3f8534";
hash = "sha256-qjV1zyVzHPXMt+oUeGBdP9XVlbcSz2MF9Zygj543T4w=";
tag = "v${finalAttrs.version}";
hash = "sha256-Gt9yynbmFWMISP1U0jRjU6oY3ImrLxYa2D0xf0llCEg=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace 'poetry>=0.12' 'poetry-core' \
--replace 'poetry.masonry.api' 'poetry.core.masonry.api'
patchShebangs --build ./example.py
'';
build-system = [ poetry-core ];
build-system = [ hatchling ];
pythonRelaxDeps = [ "dramatiq" ];
dependencies = [ dramatiq ];
nativeCheckInputs = [
flask-sqlalchemy
flask
flask-migrate
httpx
periodiq
postgresql
postgresqlTestHook
@@ -54,7 +54,8 @@ buildPythonPackage {
pytestCheckHook
requests
]
++ dramatiq.optional-dependencies.rabbitmq;
++ dramatiq.optional-dependencies.rabbitmq
++ dramatiq.optional-dependencies.watch;
postgresqlTestSetupPost = ''
substituteInPlace config.py \
@@ -72,8 +73,8 @@ buildPythonPackage {
meta = {
description = "Adds Dramatiq support to your Flask application";
homepage = "https://gitlab.com/bersace/flask-dramatiq";
homepage = "https://github.com/pallets-eco/flask-dramatiq";
license = lib.licenses.bsd3;
maintainers = with lib.maintainers; [ traxys ];
};
}
})
@@ -2,7 +2,7 @@
lib,
buildPythonPackage,
fetchFromGitLab,
poetry-core,
uv-build,
dramatiq,
pendulum,
setuptools,
@@ -13,27 +13,28 @@
buildPythonPackage rec {
pname = "periodiq";
version = "0.13.0";
version = "0.14.0";
pyproject = true;
src = fetchFromGitLab {
owner = "bersace";
repo = "periodiq";
tag = "v${version}";
hash = "sha256-Pyh/T3/HGPYyaXjyM0wkQ1V7p5ibqxE1Q62QwCIJ8To=";
hash = "sha256-XYQ0cR0gdiX7GePqpMDG/Ml0CK+SBcNbsNB99FZ/D3I=";
};
postPatch = ''
substituteInPlace pyproject.toml \
--replace-fail 'poetry>=0.12' 'poetry-core' \
--replace-fail 'poetry.masonry.api' 'poetry.core.masonry.api'
--replace-fail "uv_build>=0.11,<0.12" uv_build
'';
pythonRelaxDeps = [ "dramatiq" ];
pythonRelaxDeps = [
"dramatiq"
];
nativeBuildInputs = [ poetry-core ];
build-system = [ uv-build ];
propagatedBuildInputs = [
dependencies = [
dramatiq
pendulum
setuptools