python-dotenv: bump to 1.2.2
authorAlexandru Ardelean <redacted>
Wed, 1 Apr 2026 15:28:57 +0000 (18:28 +0300)
committerAlexandru Ardelean <redacted>
Thu, 2 Apr 2026 16:23:54 +0000 (19:23 +0300)
Changes since 1.0.1:
- Added support for Python 3.14 (including free-threaded build)
- CLI now forwards flags directly to commands
- Improved symlink handling with explicit follow_symlinks option
- Added FIFO file support on Unix systems
- Changed file mode preservation to maintain original permissions

Also add test.sh to verify dotenv_values parsing and load_dotenv.

Note: PyPI renamed the source tarball from python-dotenv-*.tar.gz
to python_dotenv-*.tar.gz; add PYPI_SOURCE_NAME accordingly.

Link: https://github.com/theskumar/python-dotenv/blob/main/CHANGELOG.md
Signed-off-by: Alexandru Ardelean <redacted>
lang/python/python-dotenv/Makefile
lang/python/python-dotenv/test.sh [new file with mode: 0644]

index b01e2bab49f96b822a4da59466d65451ee048a1f..fb7ddd1205030e97fe8428ccba8f74af89de957b 100644 (file)
@@ -1,11 +1,12 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=python-dotenv
-PKG_VERSION:=1.0.1
+PKG_VERSION:=1.2.2
 PKG_RELEASE:=1
 
 PYPI_NAME:=python-dotenv
-PKG_HASH:=e324ee90a023d808f1959c46bcbc04446a10ced277783dc6ee09987c37ec10ca
+PYPI_SOURCE_NAME:=python_dotenv
+PKG_HASH:=2c371a91fbd7ba082c2c1dc1f8bf89ca22564a087c2c287cd9b662adde799cf3
 
 PKG_MAINTAINER:=Javier Marcet <javier@marcet.info>
 PKG_LICENSE:=BSD-3-Clause
diff --git a/lang/python/python-dotenv/test.sh b/lang/python/python-dotenv/test.sh
new file mode 100644 (file)
index 0000000..03936c1
--- /dev/null
@@ -0,0 +1,31 @@
+#!/bin/sh
+
+[ "$1" = python3-dotenv ] || exit 0
+
+python3 - << 'EOF'
+import os
+import tempfile
+from dotenv import dotenv_values, load_dotenv, set_key, get_key
+
+# Write a temp .env file and parse it
+with tempfile.NamedTemporaryFile(mode='w', suffix='.env', delete=False) as f:
+    f.write('FOO=bar\n')
+    f.write('BAZ=123\n')
+    f.write('QUOTED="hello world"\n')
+    env_path = f.name
+
+try:
+    values = dotenv_values(env_path)
+    assert values['FOO'] == 'bar', f"got FOO={values['FOO']}"
+    assert values['BAZ'] == '123', f"got BAZ={values['BAZ']}"
+    assert values['QUOTED'] == 'hello world', f"got QUOTED={values['QUOTED']}"
+
+    # Test load_dotenv sets environment variables
+    load_dotenv(env_path, override=True)
+    assert os.environ.get('FOO') == 'bar'
+    assert os.environ.get('BAZ') == '123'
+finally:
+    os.unlink(env_path)
+
+print("python-dotenv OK")
+EOF
git clone https://git.99rst.org/PROJECT