Skip to content

Commit dc74724

Browse files
committed
Version 1.2.3
1 parent ff8f269 commit dc74724

File tree

12 files changed

+37
-26
lines changed

12 files changed

+37
-26
lines changed

FUNDING.yml

Lines changed: 0 additions & 1 deletion
This file was deleted.

README.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,11 @@ It require *libusb*, *pyusb* and *pyserial*.
4242

4343
* `sudo docker run --rm --user root -it --privileged -v /dev:/dev python:3.x-alpine /bin/sh` then: `apk update ; apk add libusb ; python3 -m pip install radexreader`
4444

45-
#### Alternative installation for Debian and Ubuntu
45+
#### Repository for Debian and Ubuntu
4646

4747
```bash
48-
# https://launchpad.net/~luigifab/+archive/ubuntu/packages
48+
# PPA: https://launchpad.net/~luigifab/+archive/ubuntu/packages
49+
# with Debian 12+ you can use mantic+ instead of focal (https://unix.stackexchange.com/a/669008/364800)
4950
sudo add-apt-repository ppa:luigifab/packages
5051
sudo apt update
5152
sudo apt install python3-radexreader radexreader
@@ -71,8 +72,8 @@ pub rsa4096 2020-10-31 [SC]
7172

7273
## Copyright
7374

74-
- Current version: 1.2.2 (06/06/2023)
75-
- Compatibility: Python 3.3 / 3.4 / 3.5 / 3.6 / 3.7 / 3.8 / 3.9 / 3.10 / 3.11
75+
- Current version: 1.2.3 (10/10/2023)
76+
- Compatibility: Python 3.3 / 3.4 / 3.5 / 3.6 / 3.7 / 3.8 / 3.9 / 3.10 / 3.11 / 3.12
7677
- Links: [luigifab.fr](https://www.luigifab.fr/python/radexreader) - [github.com](https://github.com/luigifab/python-radexreader) - [pypi.org](https://pypi.org/project/radexreader/)\
7778
[Debian python-radexreader.deb](https://packages.debian.org/python3-radexreader)\
7879
[Fedora python-radexreader.rpm](https://src.fedoraproject.org/rpms/python-radexreader)\

debian/changelog

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
python-radexreader (1.2.2-1) experimental; urgency=low
1+
python-radexreader (1.2.3-1) experimental; urgency=low
22

33
* Initial Debian package release (Closes: #973447)
44

5-
-- Fabrice Creuzot <code@luigifab.fr> Tue, 06 Jun 2023 20:00:00 +0000
5+
-- Fabrice Creuzot <code@luigifab.fr> Tue, 10 Oct 2023 20:00:00 +0000

debian/deb.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44

55
cd "$(dirname "$0")"
6-
version="1.2.2"
6+
version="1.2.3"
77

88

99
rm -rf builder/
@@ -31,7 +31,7 @@ fi
3131

3232

3333
# create packages for Debian and Ubuntu
34-
for serie in experimental mantic lunar kinetic jammy focal bionic xenial trusty; do
34+
for serie in experimental mantic lunar jammy focal bionic xenial trusty; do
3535

3636
if [ $serie = "experimental" ]; then
3737
# for Ubuntu

fedora/python-radexreader.spec

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ Pour éviter un Access denied (insufficient permissions), n'oubliez pas
1818
de débrancher l'appareil après l'installation.}
1919

2020
Name: python-radexreader
21-
Version: 1.2.2
22-
Release: 2%{?dist}
21+
Version: 1.2.3
22+
Release: 1%{?dist}
2323
Summary: %{common_summary_en}
2424
Summary(fr): %{common_summary_fr}
2525
License: GPLv2+
@@ -80,6 +80,9 @@ install -p -m 644 ../debian/udev %{buildroot}/lib/udev/rules.d/60-python3-radexr
8080

8181

8282
%changelog
83+
* Tue Oct 10 2023 Fabrice Creuzot <code@luigifab.fr> - 1.2.3-1
84+
- New upstream release
85+
8386
* Fri Jun 16 2023 Fabrice Creuzot <code@luigifab.fr> - 1.2.2-2
8487
- Package spec update
8588

fedora/rpm.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Fedora: configure: error: C compiler cannot create executables? remove and reinstall glibc-devel gcc
44

55
cd "$(dirname "$0")"
6-
version="1.2.2"
6+
version="1.2.3"
77

88

99
rm -rf builder/

opensuse/python-radexreader.spec

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
22
Name: python-radexreader
3-
Version: 1.2.2
3+
Version: 1.2.3
44
Release: 0
55
Summary: Reader for the RADEX RD1212 and ONE Geiger counters
66
License: GPL-2.0-or-later
@@ -71,6 +71,9 @@ install -p -m 644 ../debian/radexreader.fr.1 %{buildroot}%{_mandir}/fr/man1/rade
7171

7272

7373
%changelog
74+
* Tue Oct 10 2023 Fabrice Creuzot <code@luigifab.fr> - 1.2.3-1
75+
- New upstream release
76+
7477
* Fri Jun 16 2023 Fabrice Creuzot <code@luigifab.fr> - 1.2.2-2
7578
- Package spec update
7679

opensuse/rpm.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44

55
cd "$(dirname "$0")"
6-
version="1.2.2"
6+
version="1.2.3"
77

88

99
rm -rf builder/

pypi/pypi.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Fedora: sudo dnf install python3-devel
44

55
cd "$(dirname "$0")"
6-
version="1.2.2"
6+
version="1.2.3"
77
rm -rf builder/
88

99

src/radexreader.py

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
#!/usr/bin/python3
22
# -*- coding: utf8 -*-
33
# Created L/19/10/2020
4-
# Updated D/01/01/2023
4+
# Updated D/08/10/2023
55
#
66
# Copyright 2020-2023 | Fabrice Creuzot (luigifab) <code~luigifab~fr>
77
# https://github.com/luigifab/python-radexreader
@@ -16,13 +16,18 @@
1616
# merchantability or fitness for a particular purpose. See the
1717
# GNU General Public License (GPL) for more details.
1818

19-
from datetime import datetime
19+
import datetime
2020
from platform import python_version
2121
import sys
2222
import time
2323
import usb
2424
import serial
2525

26+
try:
27+
datetime.UTC
28+
except AttributeError:
29+
datetime.UTC = None
30+
2631
# https://stackoverflow.com/a/62804772/2980105
2732
# prevent auto import for "import radexreader" when filename is "radexreader.py"
2833
sys.path = sys.path[1:]
@@ -60,7 +65,7 @@
6065
for timestamp, measure in measures.items():
6166
if timestamp != prev:
6267
print('%s %s µSv/h ±%s%% (%s ≤ %s ≤ %s)' % (
63-
str(datetime.utcfromtimestamp(timestamp)),
68+
str(datetime.datetime.fromtimestamp(timestamp, datetime.UTC)),
6469
str('{:.2f}'.format(measure['val'])).rjust(6, ' '),
6570
str(int(measure['pct'])),
6671
str('{:.2f}'.format(measure['min'])),
@@ -97,7 +102,7 @@
97102
measures = reader.read(True)
98103
for timestamp, measure in measures.items():
99104
print('%s %s µSv/h ±%s%% (%s ≤ %s ≤ %s)' % (
100-
str(datetime.utcfromtimestamp(timestamp)),
105+
str(datetime.datetime.fromtimestamp(timestamp, datetime.UTC)),
101106
str('{:.2f}'.format(measure['val'])).rjust(6, ' '),
102107
str(int(measure['pct'])),
103108
str('{:.2f}'.format(measure['min'])),
@@ -126,7 +131,7 @@
126131
measures = reader.read(False)
127132
for timestamp, measure in measures.items():
128133
print('%s %s µSv/h ±%s%% (%s ≤ %s ≤ %s)' % (
129-
str(datetime.utcfromtimestamp(timestamp)),
134+
str(datetime.datetime.fromtimestamp(timestamp, datetime.UTC)),
130135
str('{:.2f}'.format(measure['val'])).rjust(6, ' '),
131136
str(int(measure['pct'])),
132137
str('{:.2f}'.format(measure['min'])),

0 commit comments

Comments
 (0)