sardana-nxsrecorder 3.29.1__tar.gz → 3.33.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/debian10_py2/Dockerfile +6 -2
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/debian10_py3/Dockerfile +6 -2
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/install.sh +8 -8
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.github/workflows/tests.yml +3 -28
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/ChangeLog +20 -0
- {sardana-nxsrecorder-3.29.1/sardana_nxsrecorder.egg-info → sardana-nxsrecorder-3.33.0}/PKG-INFO +5 -4
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/README.rst +4 -3
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/man/sardananxsrecorder.1 +15 -15
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0/sardana_nxsrecorder.egg-info}/PKG-INFO +5 -4
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardananxsrecorder/__init__.py +1 -1
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardananxsrecorder/nxsrecorder.py +200 -36
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/debian8_py2/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/debian8_py3/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/debian9_py2/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/debian9_py3/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/run.sh +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/ubuntu16.04_py2/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/ubuntu16.04_py3/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/ubuntu18.04_py2/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/ubuntu18.04_py3/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.ci/ubuntu20.04_py3/Dockerfile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.flake8 +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/.gitignore +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/COPYRIGHT +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/MANIFEST.in +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/doc/Makefile +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/doc/conf.py +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/doc/index.rst +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/doc/make.bat +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/doc/sardananxsrecorder.rst +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/SOURCES.txt +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/dependency_links.txt +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/not-zip-safe +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/requires.txt +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/top_level.txt +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/setup.cfg +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/setup.py +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/test/__init__.py +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/test/__main__.py +0 -0
- {sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/test/main.py +0 -0
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
FROM debian:buster
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
RUN
|
|
3
|
+
# switch to the german archive mirror
|
|
4
|
+
RUN sed -i 's|http://deb.debian.org|http://archive.debian.org|g' /etc/apt/sources.list
|
|
5
|
+
RUN sed -i 's|http://security.debian.org|http://archive.debian.org|g' /etc/apt/sources.list
|
|
6
|
+
|
|
7
|
+
# MAINTAINER DESY, Jan Kotanski <jankotan@gmail.com>
|
|
8
|
+
# RUN /bin/bash -c 'echo "deb http://ftp.de.debian.org/debian buster main" > /etc/apt/sources.list.d/debian9de.list'
|
|
5
9
|
RUN apt-get -qq update && apt-get -qq install -y libterm-readline-gnu-perl software-properties-common coreutils gnupg2 procps apt-utils curl apt-transport-https gnupg2 ca-certificates
|
|
6
10
|
RUN curl http://repos.pni-hdri.de/debian_repo.pub.gpg | apt-key add -
|
|
7
11
|
RUN add-apt-repository "deb http://repos.pni-hdri.de/apt/debian buster main" -y
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
FROM debian:buster
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
RUN
|
|
3
|
+
# switch to the german archive mirror
|
|
4
|
+
RUN sed -i 's|http://deb.debian.org|http://archive.debian.org|g' /etc/apt/sources.list
|
|
5
|
+
RUN sed -i 's|http://security.debian.org|http://archive.debian.org|g' /etc/apt/sources.list
|
|
6
|
+
|
|
7
|
+
# MAINTAINER DESY, Jan Kotanski <jankotan@gmail.com>
|
|
8
|
+
# RUN /bin/bash -c 'echo "deb http://ftp.de.debian.org/debian buster main" > /etc/apt/sources.list.d/debian9de.list'
|
|
5
9
|
RUN apt-get -qq update && apt-get -qq install -y libterm-readline-gnu-perl software-properties-common coreutils gnupg2 procps apt-utils curl apt-transport-https gnupg2 ca-certificates
|
|
6
10
|
RUN curl http://repos.pni-hdri.de/debian_repo.pub.gpg | apt-key add -
|
|
7
11
|
RUN add-apt-repository "deb http://repos.pni-hdri.de/apt/debian buster main" -y
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env bash
|
|
2
2
|
|
|
3
3
|
# workaround for a bug in debian9, i.e. starting mysql hangs
|
|
4
|
-
if [ "$1" = "debian11" ] || [ "$1" = "debian12" ] || [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ]; then
|
|
4
|
+
if [ "$1" = "debian11" ] || [ "$1" = "debian12" ] || [ "$1" = "debian13" ] || [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu25.04" ] || [ "$1" = "ubuntu25.10" ]; then
|
|
5
5
|
docker exec --user root ndts service mariadb restart
|
|
6
6
|
else
|
|
7
7
|
docker exec --user root ndts service mysql stop
|
|
@@ -16,7 +16,7 @@ fi
|
|
|
16
16
|
|
|
17
17
|
docker exec --user root ndts /bin/bash -c 'export DEBIAN_FRONTEND=noninteractive; apt-get -qq update; apt-get -qq install -y xvfb libxcb1 libx11-xcb1 libxcb-keysyms1 libxcb-image0 libxcb-icccm4 libxcb-render-util0 xkb-data tango-common; sleep 10'
|
|
18
18
|
if [ "$?" -ne "0" ]; then exit 255; fi
|
|
19
|
-
if [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ]; then
|
|
19
|
+
if [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu25.04" ] || [ "$1" = "ubuntu25.10" ]; then
|
|
20
20
|
# docker exec --user tango ndts /bin/bash -c '/usr/lib/tango/DataBaseds 2 -ORBendPoint giop:tcp::10000 &'
|
|
21
21
|
docker exec --user root ndts /bin/bash -c 'echo -e "[client]\nuser=root\npassword=rootpw" > /root/.my.cnf'
|
|
22
22
|
docker exec --user root ndts /bin/bash -c 'echo -e "[client]\nuser=tango\nhost=localhost\npassword=rootpw" > /var/lib/tango/.my.cnf'
|
|
@@ -32,7 +32,7 @@ fi
|
|
|
32
32
|
echo "install tango-db"
|
|
33
33
|
docker exec --user root ndts /bin/bash -c 'apt-get -qq update; export DEBIAN_FRONTEND=noninteractive; apt-get -qq install -y tango-db; sleep 10'
|
|
34
34
|
if [ "$?" -ne "0" ]; then exit 255; fi
|
|
35
|
-
if [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ]; then
|
|
35
|
+
if [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu25.04" ] || [ "$1" = "ubuntu25.10" ]; then
|
|
36
36
|
docker exec --user tango ndts /usr/bin/mysql -e 'create database tango'
|
|
37
37
|
docker exec --user tango ndts /bin/bash -c '/usr/bin/mysql tango < /usr/share/dbconfig-common/data/tango-db/install/mysql'
|
|
38
38
|
fi
|
|
@@ -67,20 +67,20 @@ else
|
|
|
67
67
|
docker exec --user root ndts /bin/bash -c 'cd itango-src; git checkout tags/v0.1.7 -b b0.1.7; python3 setup.py install'
|
|
68
68
|
# docker exec --user root ndts /bin/bash -c 'cd taurus-src; git checkout; python3 setup.py install'
|
|
69
69
|
fi
|
|
70
|
-
if [ "$1" = "debian10" ] || [ "$1" = "ubuntu20.04" ] || [ "$1" = "ubuntu22.04" ] || [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu20.10" ] || [ "$1" = "debian11" ] || [ "$1" = "debian12" ] ; then
|
|
70
|
+
if [ "$1" = "debian10" ] || [ "$1" = "ubuntu20.04" ] || [ "$1" = "ubuntu22.04" ] || [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu25.04" ] || [ "$1" = "ubuntu25.10" ] || [ "$1" = "ubuntu20.10" ] || [ "$1" = "debian11" ] || [ "$1" = "debian12" ] || [ "$1" = "debian13" ] ; then
|
|
71
71
|
docker exec --user root ndts /bin/bash -c 'export DEBIAN_FRONTEND=noninteractive; apt-get -qq update; apt-get install -y git python3-six python3-numpy graphviz python3-sphinx g++ build-essential python3-dev pkg-config python3-all-dev python3-setuptools libtango-dev python3-setuptools python3-tango python3-tz; apt-get -qq install -y nxsconfigserver-db; sleep 10'
|
|
72
72
|
else
|
|
73
73
|
docker exec --user root ndts /bin/bash -c 'export DEBIAN_FRONTEND=noninteractive; apt-get -qq update; apt-get install -y git python3-six python3-numpy graphviz python3-sphinx g++ build-essential python3-dev pkg-config python3-all-dev python3-setuptools libtango-dev python3-setuptools python3-pytango python3-tz; apt-get -qq install -y nxsconfigserver-db; sleep 10'
|
|
74
74
|
fi
|
|
75
75
|
docker exec --user root ndts /bin/bash -c 'export DEBIAN_FRONTEND=noninteractive; apt-get -qq update; apt-get install -y libboost-python-dev libboost-dev python3-h5py python3-qtpy python3-click python3-setuptools python3-pint'
|
|
76
|
-
if [ "$1" = "ubuntu20.04" ] || [ "$1" = "ubuntu20.10" ] || [ "$1" = "ubuntu21.04" ] || [ "$1" = "ubuntu22.04" ]|| [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "debian11" ] || [ "$1" = "debian12" ] || [ "$1" = "debian10" ]; then
|
|
76
|
+
if [ "$1" = "ubuntu20.04" ] || [ "$1" = "ubuntu20.10" ] || [ "$1" = "ubuntu21.04" ] || [ "$1" = "ubuntu22.04" ]|| [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu25.04" ] || [ "$1" = "ubuntu25.10" ] || [ "$1" = "debian11" ] || [ "$1" = "debian12" ] [ "$1" = "debian13" ] || [ "$1" = "debian10" ]; then
|
|
77
77
|
echo " "
|
|
78
78
|
else
|
|
79
79
|
docker exec --user root ndts /bin/bash -c 'export DEBIAN_FRONTEND=noninteractive; apt-get -qq update; apt-get install -y libtango-dev python3-dev'
|
|
80
80
|
docker exec --user root ndts /bin/bash -c 'git clone https://gitlab.com/tango-controls/pytango pytango; cd pytango; git checkout tags/v9.2.5 -b b9.2.5'
|
|
81
81
|
docker exec --user root ndts /bin/bash -c 'cd pytango; python3 setup.py install'
|
|
82
82
|
fi
|
|
83
|
-
if [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ]; then
|
|
83
|
+
if [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu25.04" ] || [ "$1" = "ubuntu25.10" ]; then
|
|
84
84
|
docker exec --user root ndts /usr/bin/mysql -e 'GRANT ALL PRIVILEGES ON nxsconfig.* TO "tango"@"%" identified by "rootpw"'
|
|
85
85
|
docker exec --user root ndts /usr/bin/mysql -e 'GRANT ALL PRIVILEGES ON nxsconfig.* TO "tango"@"localhost" identified by "rootpw"'
|
|
86
86
|
docker exec --user root ndts /usr/bin/mysql -e 'FLUSH PRIVILEGES'
|
|
@@ -91,7 +91,7 @@ fi
|
|
|
91
91
|
if [ "$?" -ne "0" ]; then exit 255; fi
|
|
92
92
|
|
|
93
93
|
echo "install qt5"
|
|
94
|
-
if [ "$1" = "debian12" ] ||[ "$1" = "debian11" ] || [ "$1" = "ubuntu22.04" ] || [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ]; then
|
|
94
|
+
if [ "$1" = "debian12" ] || [ "$1" = "debian13" ] || [ "$1" = "debian11" ] || [ "$1" = "ubuntu22.04" ] || [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu25.04" ] || [ "$1" = "ubuntu25.10" ]; then
|
|
95
95
|
docker exec --user root ndts /bin/bash -c 'export DEBIAN_FRONTEND=noninteractive; apt-get -qq update; apt-get -qq install -y qtbase5-dev-tools'
|
|
96
96
|
else
|
|
97
97
|
docker exec --user root ndts /bin/bash -c 'export DEBIAN_FRONTEND=noninteractive; apt-get -qq update; apt-get -qq install -y qtbase5-dev-tools qt5-default'
|
|
@@ -105,7 +105,7 @@ if [ "$2" = "2" ]; then
|
|
|
105
105
|
echo "install pytango and nxsconfigserver-db"
|
|
106
106
|
docker exec --user root ndts /bin/bash -c 'apt-get -qq update; apt-get install -y python-pytango nxsconfigserver-db ; sleep 10'
|
|
107
107
|
else
|
|
108
|
-
if [ "$1" = "debian10" ] || [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu22.04" ] || [ "$1" = "ubuntu20.04" ] || [ "$1" = "ubuntu20.10" ] || [ "$1" = "debian11" ] || [ "$1" = "debian12" ] ; then
|
|
108
|
+
if [ "$1" = "debian10" ] || [ "$1" = "ubuntu24.04" ] || [ "$1" = "ubuntu24.10" ] || [ "$1" = "ubuntu25.04" ] || [ "$1" = "ubuntu25.10" ] || [ "$1" = "ubuntu22.04" ] || [ "$1" = "ubuntu20.04" ] || [ "$1" = "ubuntu20.10" ] || [ "$1" = "debian11" ] || [ "$1" = "debian12" ] || [ "$1" = "debian13" ] ; then
|
|
109
109
|
echo "install pytango"
|
|
110
110
|
docker exec --user root ndts /bin/bash -c 'apt-get -qq update; apt-get install -y python3-tango'
|
|
111
111
|
echo "install nxsconfigserver-db"
|
|
@@ -24,7 +24,7 @@ jobs:
|
|
|
24
24
|
runs-on: ubuntu-latest
|
|
25
25
|
strategy:
|
|
26
26
|
matrix:
|
|
27
|
-
os: [debian12, debian11,
|
|
27
|
+
os: [debian13, debian12, debian11, ubuntu25.10, ubuntu24.04, ubuntu22.04]
|
|
28
28
|
steps:
|
|
29
29
|
- uses: actions/checkout@v2
|
|
30
30
|
- uses: actions/setup-python@v2
|
|
@@ -45,31 +45,6 @@ jobs:
|
|
|
45
45
|
- name: run tests
|
|
46
46
|
run: .ci/run.sh 3
|
|
47
47
|
- name: Stop the docker
|
|
48
|
-
run: docker container stop ndts
|
|
49
|
-
|
|
50
|
-
python2_tests:
|
|
51
|
-
runs-on: ubuntu-latest
|
|
52
|
-
strategy:
|
|
53
|
-
matrix:
|
|
54
|
-
os: [debian10]
|
|
55
|
-
steps:
|
|
56
|
-
- uses: actions/checkout@v2
|
|
57
|
-
- uses: actions/setup-python@v2
|
|
58
|
-
- name: Update bash files
|
|
59
48
|
run: |
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
- name: Build the docker
|
|
63
|
-
env:
|
|
64
|
-
OS: ${{ matrix.os }}
|
|
65
|
-
run: docker build -t ndts .ci/${OS}_py2
|
|
66
|
-
- name: Run the docker
|
|
67
|
-
run: docker run --name ndts -d -it -v `pwd`:/home/tango ndts
|
|
68
|
-
- name: install tango
|
|
69
|
-
env:
|
|
70
|
-
OS: ${{ matrix.os }}
|
|
71
|
-
run: .ci/install.sh ${OS} 2
|
|
72
|
-
- name: run tests
|
|
73
|
-
run: .ci/run.sh 2
|
|
74
|
-
- name: Stop the docker
|
|
75
|
-
run: docker container stop ndts
|
|
49
|
+
docker exec --user root ndts /bin/bash -c "chown -R 1001 /home/tango "
|
|
50
|
+
docker container stop ndts
|
|
@@ -1,3 +1,23 @@
|
|
|
1
|
+
2026-02-05 Jan Kotanski <jankotan@gmail.com>
|
|
2
|
+
* skip cached init datasource for dynamic component (#170)
|
|
3
|
+
* tagged as 3.33.0
|
|
4
|
+
|
|
5
|
+
2026-01-21 Jan Kotanski <jankotan@gmail.com>
|
|
6
|
+
* update configuration cache when profile created outside the nxselector #167
|
|
7
|
+
* tagged as 3.32.0
|
|
8
|
+
|
|
9
|
+
2026-01-16 Jan Kotanski <jankotan@gmail.com>
|
|
10
|
+
* add support for cache configuration
|
|
11
|
+
* tagged as 3.31.0
|
|
12
|
+
|
|
13
|
+
2026-01-13 Jan Kotanski <jankotan@gmail.com>
|
|
14
|
+
* add debug info
|
|
15
|
+
* tagged as 3.30.1
|
|
16
|
+
|
|
17
|
+
2025-07-29 Jan Kotanski <jankotan@gmail.com>
|
|
18
|
+
* add support for tango datasources from defmeas macro (#155)
|
|
19
|
+
* tagged as 3.30.0
|
|
20
|
+
|
|
1
21
|
2024-12-11 Jan Kotanski <jankotan@gmail.com>
|
|
2
22
|
* reset SciCatMeasurements if not dict (#149)
|
|
3
23
|
* tagged as 3.29.1
|
{sardana-nxsrecorder-3.29.1/sardana_nxsrecorder.egg-info → sardana-nxsrecorder-3.33.0}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: sardana-nxsrecorder
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.33.0
|
|
4
4
|
Summary: NeXus Sardana Scan Recorder
|
|
5
5
|
Home-page: https://github.com/nexdatas/sardana-nxs-filerecorder/
|
|
6
6
|
Author: Jan Kotanski
|
|
@@ -85,21 +85,22 @@ defining the package location, e.g.
|
|
|
85
85
|
Debian packages
|
|
86
86
|
"""""""""""""""
|
|
87
87
|
|
|
88
|
-
Debian Bookworm, Bullseye
|
|
88
|
+
Debian Trixie, Bookworm, Bullseye and Ubuntu Questing, Noble Jammy packages can be found in the HDRI repository.
|
|
89
89
|
|
|
90
90
|
To install the debian packages, add the PGP repository key
|
|
91
91
|
|
|
92
92
|
.. code-block:: console
|
|
93
93
|
|
|
94
94
|
$ sudo su
|
|
95
|
-
$
|
|
95
|
+
$ curl -s http://repos.pni-hdri.de/debian_repo.pub.gpg | gpg --no-default-keyring --keyring gnupg-ring:/etc/apt/trusted.gpg.d/debian-hdri-repo.gpg --import
|
|
96
|
+
$ chmod 644 /etc/apt/trusted.gpg.d/debian-hdri-repo.gpg
|
|
96
97
|
|
|
97
98
|
and then download the corresponding source list
|
|
98
99
|
|
|
99
100
|
.. code-block:: console
|
|
100
101
|
|
|
101
102
|
$ cd /etc/apt/sources.list.d
|
|
102
|
-
$ wget http://repos.pni-hdri.de/
|
|
103
|
+
$ wget http://repos.pni-hdri.de/trixie-pni-hdri.sources
|
|
103
104
|
|
|
104
105
|
|
|
105
106
|
Finally, for python2.7
|
|
@@ -60,21 +60,22 @@ defining the package location, e.g.
|
|
|
60
60
|
Debian packages
|
|
61
61
|
"""""""""""""""
|
|
62
62
|
|
|
63
|
-
Debian Bookworm, Bullseye
|
|
63
|
+
Debian Trixie, Bookworm, Bullseye and Ubuntu Questing, Noble Jammy packages can be found in the HDRI repository.
|
|
64
64
|
|
|
65
65
|
To install the debian packages, add the PGP repository key
|
|
66
66
|
|
|
67
67
|
.. code-block:: console
|
|
68
68
|
|
|
69
69
|
$ sudo su
|
|
70
|
-
$
|
|
70
|
+
$ curl -s http://repos.pni-hdri.de/debian_repo.pub.gpg | gpg --no-default-keyring --keyring gnupg-ring:/etc/apt/trusted.gpg.d/debian-hdri-repo.gpg --import
|
|
71
|
+
$ chmod 644 /etc/apt/trusted.gpg.d/debian-hdri-repo.gpg
|
|
71
72
|
|
|
72
73
|
and then download the corresponding source list
|
|
73
74
|
|
|
74
75
|
.. code-block:: console
|
|
75
76
|
|
|
76
77
|
$ cd /etc/apt/sources.list.d
|
|
77
|
-
$ wget http://repos.pni-hdri.de/
|
|
78
|
+
$ wget http://repos.pni-hdri.de/trixie-pni-hdri.sources
|
|
78
79
|
|
|
79
80
|
|
|
80
81
|
Finally, for python2.7
|
|
@@ -27,7 +27,7 @@ level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
|
|
|
27
27
|
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
|
|
28
28
|
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
|
|
29
29
|
..
|
|
30
|
-
.TH "SARDANANXSRECORDER" "1" "
|
|
30
|
+
.TH "SARDANANXSRECORDER" "1" "Jul 29, 2025" "3.30" "Sardana NeXus Recorder"
|
|
31
31
|
.SH NAME
|
|
32
32
|
sardananxsrecorder \- sardananxsrecorder Documentation
|
|
33
33
|
.sp
|
|
@@ -356,9 +356,9 @@ constructor
|
|
|
356
356
|
.B Parameters
|
|
357
357
|
.INDENT 7.0
|
|
358
358
|
.IP \(bu 2
|
|
359
|
-
\fBfilename\fP (\fI\%str\fP)
|
|
359
|
+
\fBfilename\fP (\fI\%str\fP) \-\- ScanFile name
|
|
360
360
|
.IP \(bu 2
|
|
361
|
-
\fBmacro\fP (\fI\%sardana.macroserver.macro.Macro\fP)
|
|
361
|
+
\fBmacro\fP (\fI\%sardana.macroserver.macro.Macro\fP) \-\- macro object
|
|
362
362
|
.UNINDENT
|
|
363
363
|
.UNINDENT
|
|
364
364
|
.INDENT 7.0
|
|
@@ -370,13 +370,13 @@ adds custom data to configuration variables, i.e. from macros
|
|
|
370
370
|
.B Parameters
|
|
371
371
|
.INDENT 7.0
|
|
372
372
|
.IP \(bu 2
|
|
373
|
-
\fBvalue\fP (\fIany\fP)
|
|
373
|
+
\fBvalue\fP (\fIany\fP) \-\- variable value
|
|
374
374
|
.IP \(bu 2
|
|
375
|
-
\fBname\fP (\fI\%str\fP)
|
|
375
|
+
\fBname\fP (\fI\%str\fP) \-\- variable name
|
|
376
376
|
.IP \(bu 2
|
|
377
|
-
\fBgroup\fP (\fI\%str\fP)
|
|
377
|
+
\fBgroup\fP (\fI\%str\fP) \-\- variable group inside variable dictionary
|
|
378
378
|
.IP \(bu 2
|
|
379
|
-
\fBremove\fP (\fI\%bool\fP)
|
|
379
|
+
\fBremove\fP (\fI\%bool\fP) \-\- if True variable will be removed
|
|
380
380
|
.UNINDENT
|
|
381
381
|
.UNINDENT
|
|
382
382
|
.UNINDENT
|
|
@@ -391,7 +391,7 @@ and closes the nexus file
|
|
|
391
391
|
.INDENT 7.0
|
|
392
392
|
.TP
|
|
393
393
|
.B Parameters
|
|
394
|
-
\fBrecordlist\fP (\fBsardana.macroserver.scan.scandata.RecordList\fP)
|
|
394
|
+
\fBrecordlist\fP (\fBsardana.macroserver.scan.scandata.RecordList\fP) \-\- sardana record list
|
|
395
395
|
.UNINDENT
|
|
396
396
|
.UNINDENT
|
|
397
397
|
.INDENT 7.0
|
|
@@ -405,7 +405,7 @@ and records in INIT mode
|
|
|
405
405
|
.INDENT 7.0
|
|
406
406
|
.TP
|
|
407
407
|
.B Parameters
|
|
408
|
-
\fBrecordlist\fP (\fBsardana.macroserver.scan.scandata.RecordList\fP)
|
|
408
|
+
\fBrecordlist\fP (\fBsardana.macroserver.scan.scandata.RecordList\fP) \-\- sardana record list
|
|
409
409
|
.UNINDENT
|
|
410
410
|
.UNINDENT
|
|
411
411
|
.INDENT 7.0
|
|
@@ -419,7 +419,7 @@ and records in INIT mode
|
|
|
419
419
|
.INDENT 7.0
|
|
420
420
|
.TP
|
|
421
421
|
.B Parameters
|
|
422
|
-
\fBrecord\fP (\fBsardana.macroserver.scan.scandata.Record\fP)
|
|
422
|
+
\fBrecord\fP (\fBsardana.macroserver.scan.scandata.Record\fP) \-\- sardana record list
|
|
423
423
|
.UNINDENT
|
|
424
424
|
.UNINDENT
|
|
425
425
|
.INDENT 7.0
|
|
@@ -477,12 +477,12 @@ indent level. An indent level of 0 will only insert newlines.
|
|
|
477
477
|
None is the most compact representation.
|
|
478
478
|
.sp
|
|
479
479
|
If specified, separators should be an (item_separator, key_separator)
|
|
480
|
-
tuple. The default is (
|
|
481
|
-
(
|
|
482
|
-
you should specify (
|
|
480
|
+
tuple. The default is (\(aq, \(aq, \(aq: \(aq) if \fIindent\fP is \fBNone\fP and
|
|
481
|
+
(\(aq,\(aq, \(aq: \(aq) otherwise. To get the most compact JSON representation,
|
|
482
|
+
you should specify (\(aq,\(aq, \(aq:\(aq) to eliminate whitespace.
|
|
483
483
|
.sp
|
|
484
484
|
If specified, default is a function that gets called for objects
|
|
485
|
-
that can
|
|
485
|
+
that can\(aqt otherwise be serialized. It should return a JSON encodable
|
|
486
486
|
version of the object or raise a \fBTypeError\fP\&.
|
|
487
487
|
.INDENT 7.0
|
|
488
488
|
.TP
|
|
@@ -491,7 +491,7 @@ default encoder
|
|
|
491
491
|
.INDENT 7.0
|
|
492
492
|
.TP
|
|
493
493
|
.B Parameters
|
|
494
|
-
\fBobj\fP (\fI\%object\fP or \fIany\fP)
|
|
494
|
+
\fBobj\fP (\fI\%object\fP or \fIany\fP) \-\- numpy array object
|
|
495
495
|
.UNINDENT
|
|
496
496
|
.UNINDENT
|
|
497
497
|
.UNINDENT
|
{sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0/sardana_nxsrecorder.egg-info}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: sardana-nxsrecorder
|
|
3
|
-
Version: 3.
|
|
3
|
+
Version: 3.33.0
|
|
4
4
|
Summary: NeXus Sardana Scan Recorder
|
|
5
5
|
Home-page: https://github.com/nexdatas/sardana-nxs-filerecorder/
|
|
6
6
|
Author: Jan Kotanski
|
|
@@ -85,21 +85,22 @@ defining the package location, e.g.
|
|
|
85
85
|
Debian packages
|
|
86
86
|
"""""""""""""""
|
|
87
87
|
|
|
88
|
-
Debian Bookworm, Bullseye
|
|
88
|
+
Debian Trixie, Bookworm, Bullseye and Ubuntu Questing, Noble Jammy packages can be found in the HDRI repository.
|
|
89
89
|
|
|
90
90
|
To install the debian packages, add the PGP repository key
|
|
91
91
|
|
|
92
92
|
.. code-block:: console
|
|
93
93
|
|
|
94
94
|
$ sudo su
|
|
95
|
-
$
|
|
95
|
+
$ curl -s http://repos.pni-hdri.de/debian_repo.pub.gpg | gpg --no-default-keyring --keyring gnupg-ring:/etc/apt/trusted.gpg.d/debian-hdri-repo.gpg --import
|
|
96
|
+
$ chmod 644 /etc/apt/trusted.gpg.d/debian-hdri-repo.gpg
|
|
96
97
|
|
|
97
98
|
and then download the corresponding source list
|
|
98
99
|
|
|
99
100
|
.. code-block:: console
|
|
100
101
|
|
|
101
102
|
$ cd /etc/apt/sources.list.d
|
|
102
|
-
$ wget http://repos.pni-hdri.de/
|
|
103
|
+
$ wget http://repos.pni-hdri.de/trixie-pni-hdri.sources
|
|
103
104
|
|
|
104
105
|
|
|
105
106
|
Finally, for python2.7
|
|
@@ -99,6 +99,7 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
99
99
|
:type macro: :class:`sardana.macroserver.macro.Macro`
|
|
100
100
|
"""
|
|
101
101
|
BaseFileRecorder.__init__(self)
|
|
102
|
+
self.debug('__init__: Init NXS_FileRecorder: %s' % str(filename))
|
|
102
103
|
#: (:obj:`str`) base filename
|
|
103
104
|
self.__base_filename = filename
|
|
104
105
|
#: (:obj:`str`) raw filename
|
|
@@ -116,7 +117,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
116
117
|
self.__nexussettings_device = None
|
|
117
118
|
|
|
118
119
|
#: (:obj:`int`) device proxy timeout
|
|
119
|
-
self.__timeout = 100000
|
|
120
|
+
# self.__timeout = 100000
|
|
121
|
+
self.__timeout = 10000000
|
|
120
122
|
#: (:obj:`dict` <:obj:`str`, :obj:`list` <:obj:`str`>
|
|
121
123
|
#: or :obj:`dict` <:obj:`str` , `any`> > ) Custom variables
|
|
122
124
|
self.__vars = {"data": {},
|
|
@@ -132,6 +134,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
132
134
|
|
|
133
135
|
#: (:obj:`str`) dynamic components
|
|
134
136
|
self.__dynamicCP = "__dynamic_component__"
|
|
137
|
+
#: (:obj:`str`) cache component prefix
|
|
138
|
+
self.__cacheCPPrefix = "__configuration_"
|
|
135
139
|
|
|
136
140
|
#: (:obj:`dict` <:obj:`str` , `any`> ) environment
|
|
137
141
|
self.__env = macro.getAllEnv() if macro else {}
|
|
@@ -167,13 +171,17 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
167
171
|
#: (:obj:`bool`) external measurement group
|
|
168
172
|
self.__oddmntgrp = False
|
|
169
173
|
|
|
174
|
+
self.debug('__init__: Set NeXus: %s' % str(filename))
|
|
170
175
|
self.__setNexusDevices(onlyconfig=True)
|
|
171
176
|
|
|
177
|
+
self.debug('__init__: Set Append Entry: %s' % str(filename))
|
|
172
178
|
appendentry = self.__getConfVar("AppendEntry", True)
|
|
173
179
|
scanID = self.__env["ScanID"] \
|
|
174
180
|
if "ScanID" in self.__env.keys() else -1
|
|
181
|
+
self.debug('__init__: Set FileName: %s' % str(filename))
|
|
175
182
|
self.__setFileName(
|
|
176
183
|
self.__base_filename, not appendentry, scanID)
|
|
184
|
+
self.debug('__init__: Done: %s' % str(filename))
|
|
177
185
|
|
|
178
186
|
def _serial(self, scanID):
|
|
179
187
|
serial = None
|
|
@@ -411,7 +419,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
411
419
|
subs = False
|
|
412
420
|
if not self.__raw_filename:
|
|
413
421
|
self.__raw_filename = self.__rawfilename(self.__serial)
|
|
414
|
-
self.debug('
|
|
422
|
+
self.debug('__setFileName: '
|
|
423
|
+
'Raw Filename: %s' % str(self.__raw_filename))
|
|
415
424
|
if not subs and self.__raw_filename and \
|
|
416
425
|
"{ScanID" in self.__raw_filename:
|
|
417
426
|
try:
|
|
@@ -453,6 +462,9 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
453
462
|
profile configuration of NXSRecSelector
|
|
454
463
|
:type onlyconfig: :obj:`bool`
|
|
455
464
|
"""
|
|
465
|
+
self.debug(
|
|
466
|
+
'__setNexusDevices: NXSRecSelector: %s'
|
|
467
|
+
% str(self.__raw_filename))
|
|
456
468
|
vl = self.__getEnvVar("NeXusSelectorDevice", None)
|
|
457
469
|
if vl is None:
|
|
458
470
|
servers = self.__db.get_device_exported_for_class(
|
|
@@ -474,6 +486,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
474
486
|
"Cannot connect to '%s'" % servers[0])
|
|
475
487
|
else:
|
|
476
488
|
self.__nexussettings_device = None
|
|
489
|
+
self.debug('__setNexusDevices: import profile: %s'
|
|
490
|
+
% str(self.__raw_filename))
|
|
477
491
|
if self.__nexussettings_device is None:
|
|
478
492
|
from nxsrecconfig import Settings
|
|
479
493
|
self.__nexussettings_device = Settings.Settings()
|
|
@@ -483,10 +497,13 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
483
497
|
raise Exception("NXSRecSelector (%s) version below 2.0.0" %
|
|
484
498
|
(servers[0] if servers else "module"))
|
|
485
499
|
|
|
500
|
+
self.debug('__setNexusDevices: set MG: %s' % str(self.__raw_filename))
|
|
486
501
|
mntgrp = self.__getServerVar("mntGrp", None)
|
|
487
502
|
amntgrp = self.__getEnvVar("ActiveMntGrp", None)
|
|
488
503
|
if mntgrp and amntgrp != mntgrp:
|
|
489
504
|
self.__nexussettings_device.mntgrp = amntgrp
|
|
505
|
+
self.debug('__setNexusDevices: list profile: %s'
|
|
506
|
+
% str(self.__raw_filename))
|
|
490
507
|
if amntgrp not in self.__command(
|
|
491
508
|
self.__nexussettings_device, "availableProfiles"):
|
|
492
509
|
if onlyconfig:
|
|
@@ -507,15 +524,29 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
507
524
|
self.info(
|
|
508
525
|
"NXS_FileRecorer: descriptive components will be reset")
|
|
509
526
|
else:
|
|
527
|
+
self.debug('__setNexusDevices: fetch profile: %s'
|
|
528
|
+
% str(self.__raw_filename))
|
|
510
529
|
self.__command(self.__nexussettings_device, "fetchProfile")
|
|
530
|
+
self.debug('__setNexusDevices: reset profile: %s'
|
|
531
|
+
% str(self.__raw_filename))
|
|
511
532
|
self.__asynchcommand(self.__nexussettings_device,
|
|
512
533
|
"resetPreselectedComponents")
|
|
534
|
+
self.debug('__setNexusDevices: reset profile Done: %s'
|
|
535
|
+
% str(self.__raw_filename))
|
|
513
536
|
self.__oddmntgrp = True
|
|
514
537
|
else:
|
|
538
|
+
self.debug('__setNexusDevices: '
|
|
539
|
+
'fetch profile 2: %s' % str(self.__raw_filename))
|
|
515
540
|
self.__command(self.__nexussettings_device, "fetchProfile")
|
|
541
|
+
self.debug('__setNexusDevices: fetch profile 2 Done: %s' %
|
|
542
|
+
str(self.__raw_filename))
|
|
516
543
|
self.__vars["vars"]["measurement_group"] = amntgrp
|
|
517
544
|
|
|
545
|
+
self.debug('__setNexusDevices: '
|
|
546
|
+
'profile config: %s' % str(self.__raw_filename))
|
|
518
547
|
self.__conf = self.__getServerVar("profileConfiguration", {}, True)
|
|
548
|
+
self.debug('__setNexusDevices: '
|
|
549
|
+
'MG config: %s' % str(self.__raw_filename))
|
|
519
550
|
if not self.__oddmntgrp and not onlyconfig:
|
|
520
551
|
if "MntGrpConfiguration" in self.__conf.keys():
|
|
521
552
|
poolmg = self.__command(
|
|
@@ -525,16 +556,27 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
525
556
|
poolmg = None
|
|
526
557
|
profmg = None
|
|
527
558
|
if not poolmg or not profmg or poolmg != profmg:
|
|
528
|
-
self.debug(
|
|
529
|
-
|
|
530
|
-
|
|
559
|
+
self.debug("__setNexusDevices: "
|
|
560
|
+
"ActiveMntGrp created outside NXSRecSelector v3. "
|
|
561
|
+
"Updating ActiveMntGrp")
|
|
531
562
|
if self.__macro:
|
|
532
563
|
self.__macro().debug(
|
|
533
564
|
"ActiveMntGrp created outside NXSRecSelector v3. "
|
|
534
565
|
"Updating ActiveMntGrp")
|
|
535
566
|
self.__command(self.__nexussettings_device, "importMntGrp")
|
|
536
567
|
self.__command(self.__nexussettings_device, "updateMntGrp")
|
|
537
|
-
|
|
568
|
+
if hasattr(self.__nexussettings_device, "cachecomponent"):
|
|
569
|
+
ccomp = self.__nexussettings_device.cachecomponent
|
|
570
|
+
if ccomp:
|
|
571
|
+
self.debug('__setNexusDevices: '
|
|
572
|
+
'Cache Writer Configuration: %s'
|
|
573
|
+
% str(ccomp))
|
|
574
|
+
self.__command(
|
|
575
|
+
self.__nexussettings_device,
|
|
576
|
+
"cacheWriterConfiguration", [])
|
|
577
|
+
|
|
578
|
+
self.debug('__setNexusDevices: '
|
|
579
|
+
'Writer Device: %s' % str(self.__raw_filename))
|
|
538
580
|
if not onlyconfig:
|
|
539
581
|
vl = self.__getConfVar("WriterDevice", None)
|
|
540
582
|
if not vl:
|
|
@@ -560,6 +602,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
560
602
|
else:
|
|
561
603
|
self.__nexuswriter_device = None
|
|
562
604
|
|
|
605
|
+
self.debug('__setNexusDevices: Writer Device Properties: %s'
|
|
606
|
+
% str(self.__raw_filename))
|
|
563
607
|
if self.__nexuswriter_device is None:
|
|
564
608
|
from nxswriter import TangoDataWriter
|
|
565
609
|
self.__nexuswriter_device = TangoDataWriter.TangoDataWriter()
|
|
@@ -575,6 +619,7 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
575
619
|
for ky, vl in properties.items():
|
|
576
620
|
if hasattr(self.__nexuswriter_device, ky):
|
|
577
621
|
setattr(self.__nexuswriter_device, ky, vl)
|
|
622
|
+
self.debug('__setNexusDevices: End: %s' % str(self.__raw_filename))
|
|
578
623
|
|
|
579
624
|
def __get_alias(self, name):
|
|
580
625
|
""" provides a device alias
|
|
@@ -600,6 +645,26 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
600
645
|
alias = None
|
|
601
646
|
return alias
|
|
602
647
|
|
|
648
|
+
def __short_name(self, name):
|
|
649
|
+
""" provides a device alias
|
|
650
|
+
|
|
651
|
+
:param name: device name
|
|
652
|
+
:type name: :obj:`str`
|
|
653
|
+
:returns: device alias
|
|
654
|
+
:rtype: :obj:`str`
|
|
655
|
+
"""
|
|
656
|
+
# if name does not contain a "/" it's probably an alias
|
|
657
|
+
if name.startswith("tango://"):
|
|
658
|
+
name = name[8:]
|
|
659
|
+
if name.find("/") == -1:
|
|
660
|
+
return name
|
|
661
|
+
|
|
662
|
+
# haso107klx:10000/expchan/hasysis3820ctrl/1
|
|
663
|
+
if name.find(':') >= 0:
|
|
664
|
+
lst = name.split("/")
|
|
665
|
+
name = "/".join(lst[1:])
|
|
666
|
+
return name
|
|
667
|
+
|
|
603
668
|
def __collectAliases(self, envRec):
|
|
604
669
|
""" sets deviceAlaises and dynamicDataSources from env record
|
|
605
670
|
|
|
@@ -649,13 +714,16 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
649
714
|
:param nexuscomponents: nexus component list
|
|
650
715
|
:type nexuscomponents: :obj:`list` <:obj:`str`>
|
|
651
716
|
"""
|
|
652
|
-
self.debug("Step DSs: %s" % dss)
|
|
653
|
-
self.debug("Init DSs: %s" % keys)
|
|
654
|
-
self.debug("Init User Data: %s" % udata)
|
|
717
|
+
self.debug("__createDynamicComponent: Step DSs: %s" % dss)
|
|
718
|
+
self.debug("__createDynamicComponent: Init DSs: %s" % keys)
|
|
719
|
+
self.debug("__createDynamicComponent: Init User Data: %s" % udata)
|
|
655
720
|
envRec = self.recordlist.getEnviron()
|
|
656
721
|
lddict = []
|
|
657
722
|
tdss = [ds for ds in dss if not ds.startswith("tango://")
|
|
658
723
|
and ds not in nexuscomponents]
|
|
724
|
+
tgdss = [self.__short_name(ds)
|
|
725
|
+
for ds in dss if ds.startswith("tango://")
|
|
726
|
+
and ds not in nexuscomponents]
|
|
659
727
|
|
|
660
728
|
fields = []
|
|
661
729
|
for dd in envRec['datadesc']:
|
|
@@ -695,20 +763,27 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
695
763
|
if fld and att:
|
|
696
764
|
if fld in fields.keys():
|
|
697
765
|
fields[fld][att] = vl
|
|
698
|
-
else:
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
766
|
+
# else:
|
|
767
|
+
# fields[fld] = {
|
|
768
|
+
# "name": fld,
|
|
769
|
+
# "strategy": "INIT",
|
|
770
|
+
# "dtype": "string",
|
|
771
|
+
# "shape": tuple(),
|
|
772
|
+
# att: vl}
|
|
704
773
|
|
|
705
774
|
for mdd in fields.values():
|
|
706
775
|
lddict.append(mdd)
|
|
707
776
|
|
|
777
|
+
tdss.extend(tgdss)
|
|
708
778
|
jddict = json.dumps(lddict, cls=NXS_FileRecorder.numpyEncoder)
|
|
709
779
|
jdss = json.dumps(tdss, cls=NXS_FileRecorder.numpyEncoder)
|
|
710
780
|
jkeys = json.dumps(keys, cls=NXS_FileRecorder.numpyEncoder)
|
|
711
|
-
|
|
781
|
+
self.debug("__createDynamicComponent: "
|
|
782
|
+
"tango STEP datasources: %s" % tdss)
|
|
783
|
+
self.debug("__createDynamicComponent: "
|
|
784
|
+
"sardana STEP datasources: %s" % jddict)
|
|
785
|
+
self.debug("__createDynamicComponent: "
|
|
786
|
+
"INIT datasources: %s" % jkeys)
|
|
712
787
|
self.__dynamicCP = \
|
|
713
788
|
self.__command(self.__nexussettings_device,
|
|
714
789
|
"createDynamicComponent",
|
|
@@ -752,11 +827,14 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
752
827
|
:rtype: (`list` <:obj:`str`>, `list` <:obj:`str`>,
|
|
753
828
|
`list` <:obj:`str`>, `list` <:obj:`str`>)
|
|
754
829
|
"""
|
|
830
|
+
self.debug("__searchDataSources: Init: %s"
|
|
831
|
+
% str([nexuscomponents, cfm, dyncp, userkeys]))
|
|
755
832
|
dsFound = {}
|
|
756
833
|
dsNotFound = []
|
|
757
834
|
|
|
758
835
|
# (:obj:`list` <:obj:`str`>) all component source names
|
|
759
836
|
allcpdss = []
|
|
837
|
+
cachedss = []
|
|
760
838
|
cpReq = {}
|
|
761
839
|
keyFound = set()
|
|
762
840
|
|
|
@@ -767,6 +845,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
767
845
|
else:
|
|
768
846
|
cmps = list(set(nexuscomponents) &
|
|
769
847
|
set(self.__availableComponents()))
|
|
848
|
+
self.debug("__searchDataSources: Get selected DSs: %s"
|
|
849
|
+
% str([cfm, dyncp]))
|
|
770
850
|
if self.__oddmntgrp:
|
|
771
851
|
nds = []
|
|
772
852
|
else:
|
|
@@ -774,8 +854,17 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
774
854
|
"selectedDataSources")
|
|
775
855
|
nds = nds if nds else []
|
|
776
856
|
datasources = list(set(nds) | set(self.__deviceAliases.keys()))
|
|
857
|
+
self.debug("__searchDataSources: Get components DSs: %s"
|
|
858
|
+
% str([cfm, dyncp]))
|
|
777
859
|
hascpsrcs = hasattr(self.__nexussettings_device, 'componentSources')
|
|
860
|
+
# aacpdss = json.loads(
|
|
861
|
+
# self.__command(self.__nexussettings_device,
|
|
862
|
+
# "componentSources",
|
|
863
|
+
# cmps))
|
|
864
|
+
self.debug("__searchDataSources: component loop: %s"
|
|
865
|
+
% str([cfm, dyncp, hascpsrcs]))
|
|
778
866
|
for cp in cmps:
|
|
867
|
+
self.debug("__searchDataSources: component item: %s" % cp)
|
|
779
868
|
try:
|
|
780
869
|
if hascpsrcs:
|
|
781
870
|
cpdss = json.loads(
|
|
@@ -786,6 +875,11 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
786
875
|
[ds["dsname"] for ds in cpdss
|
|
787
876
|
if ("parentobj" not in ds or
|
|
788
877
|
ds["parentobj"] in ["field"])])
|
|
878
|
+
if cp.startswith(self.__cacheCPPrefix):
|
|
879
|
+
cachedss.extend(
|
|
880
|
+
[ds["dsname"] for ds in cpdss
|
|
881
|
+
if ("parentobj" not in ds or
|
|
882
|
+
ds["parentobj"] in ["field"])])
|
|
789
883
|
|
|
790
884
|
else:
|
|
791
885
|
cpdss = json.loads(
|
|
@@ -807,28 +901,38 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
807
901
|
"Component '%s' wrongly defined in DB!" % cp)
|
|
808
902
|
# self.__macro().warning("Error: '%s'" % str(e))
|
|
809
903
|
else:
|
|
810
|
-
self.debug(
|
|
904
|
+
self.debug(
|
|
905
|
+
"__searchDataSources: "
|
|
906
|
+
"Component '%s' wrongly defined in DB!" % cp)
|
|
811
907
|
self.warning("Error: '%s'" % str(e))
|
|
812
908
|
if self.__macro:
|
|
813
909
|
self.__macro().debug(
|
|
910
|
+
"__searchDataSources: "
|
|
814
911
|
"Component '%s' wrongly defined in DB!" % cp)
|
|
815
912
|
self.__macro.debug("Error: '%s'" % str(e))
|
|
816
913
|
dss = []
|
|
817
914
|
if dss:
|
|
818
915
|
cdss = list(set(dss) & set(datasources))
|
|
819
916
|
for ds in cdss:
|
|
820
|
-
self.debug("'%s' found in '%s'"
|
|
917
|
+
self.debug("__searchDataSources: '%s' found in '%s'"
|
|
918
|
+
% (ds, cp))
|
|
821
919
|
if ds not in dsFound.keys():
|
|
822
920
|
dsFound[ds] = []
|
|
823
921
|
dsFound[ds].append(cp)
|
|
824
922
|
if cp not in cpReq.keys():
|
|
825
923
|
cpReq[cp] = []
|
|
826
924
|
cpReq[cp].append(ds)
|
|
925
|
+
self.debug("__searchDataSources: "
|
|
926
|
+
"component loop end: %s" % str([cfm, dyncp]))
|
|
827
927
|
missingKeys = set(userkeys) - keyFound
|
|
828
928
|
|
|
929
|
+
self.debug("__searchDataSources: "
|
|
930
|
+
"dynamic component loop: %s" % str([cfm, dyncp]))
|
|
829
931
|
datasources.extend(self.__dynamicDataSources.keys())
|
|
830
932
|
#: get not found datasources
|
|
831
933
|
for ds in datasources:
|
|
934
|
+
self.debug("__searchDataSources: "
|
|
935
|
+
" dynamic component item: %s" % ds)
|
|
832
936
|
if ds not in dsFound.keys() and ds not in allcpdss:
|
|
833
937
|
dsNotFound.append(ds)
|
|
834
938
|
if not dyncp:
|
|
@@ -857,7 +961,9 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
857
961
|
"It was not found in User Components!"
|
|
858
962
|
" Consider setting: "
|
|
859
963
|
"NeXusDynamicComponents=True" % ds)
|
|
860
|
-
|
|
964
|
+
self.debug("__searchDataSources: "
|
|
965
|
+
"dynamic component loop end: %s" % str([cfm, dyncp]))
|
|
966
|
+
return (nds, dsNotFound, cpReq, list(missingKeys), cachedss)
|
|
861
967
|
|
|
862
968
|
def __createConfiguration(self, userdata):
|
|
863
969
|
""" create NeXus configuration
|
|
@@ -867,14 +973,19 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
867
973
|
:returns: configuration xml string
|
|
868
974
|
:rtype: :obj:`str`
|
|
869
975
|
"""
|
|
976
|
+
self.debug("__createConfiguration: Init: %s" % self.__oddmntgrp)
|
|
870
977
|
cfm = self.__getConfVar("ComponentsFromMntGrp",
|
|
871
978
|
False, pass_default=self.__oddmntgrp)
|
|
872
979
|
dyncp = self.__getConfVar("DynamicComponents",
|
|
873
980
|
True, pass_default=self.__oddmntgrp)
|
|
874
981
|
|
|
875
982
|
envRec = self.recordlist.getEnviron()
|
|
983
|
+
self.debug("__createConfiguration: CollectAllises: %s"
|
|
984
|
+
% self.__oddmntgrp)
|
|
876
985
|
self.__collectAliases(envRec)
|
|
877
986
|
|
|
987
|
+
self.debug("__createConfiguration: Get Components: %s"
|
|
988
|
+
% self.__oddmntgrp)
|
|
878
989
|
mandatory = self.__command(self.__nexussettings_device,
|
|
879
990
|
"mandatoryComponents")
|
|
880
991
|
self.info("Default Components %s" % str(mandatory))
|
|
@@ -886,6 +997,15 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
886
997
|
nexuscomponents.extend(lst)
|
|
887
998
|
self.info("User Components %s" % str(nexuscomponents))
|
|
888
999
|
|
|
1000
|
+
ccomp = None
|
|
1001
|
+
if hasattr(self.__nexussettings_device, "cachecomponent"):
|
|
1002
|
+
ccomp = self.__nexussettings_device.cachecomponent
|
|
1003
|
+
allnexuscomponents = list(set(nexuscomponents) | set(mandatory))
|
|
1004
|
+
if ccomp:
|
|
1005
|
+
self.info("Cache Component %s" % str(ccomp))
|
|
1006
|
+
nexuscomponents = [ccomp]
|
|
1007
|
+
allnexuscomponents = [ccomp]
|
|
1008
|
+
|
|
889
1009
|
self.__availableComps = []
|
|
890
1010
|
lst = self.__getConfVar("OptionalComponents",
|
|
891
1011
|
None, True, pass_default=self.__oddmntgrp)
|
|
@@ -896,13 +1016,20 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
896
1016
|
self.info("Available Components %s" % str(
|
|
897
1017
|
self.__availableComponents()))
|
|
898
1018
|
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
905
|
-
self.debug("
|
|
1019
|
+
self.debug("__createConfiguration: Search DataSources: %s"
|
|
1020
|
+
% self.__oddmntgrp)
|
|
1021
|
+
nds, dsNotFound, cpReq, missingKeys, cachedss = \
|
|
1022
|
+
self.__searchDataSources(
|
|
1023
|
+
allnexuscomponents,
|
|
1024
|
+
cfm, dyncp, userdata.keys())
|
|
1025
|
+
self.debug("__createConfiguration: Get User data: %s"
|
|
1026
|
+
% self.__oddmntgrp)
|
|
1027
|
+
|
|
1028
|
+
self.debug("__createConfiguration: DataSources Not Found : %s"
|
|
1029
|
+
% dsNotFound)
|
|
1030
|
+
self.debug("__createConfiguration: Components required : %s" % cpReq)
|
|
1031
|
+
self.debug("__createConfiguration: Missing User Data : %s"
|
|
1032
|
+
% missingKeys)
|
|
906
1033
|
if "InitDataSources" in self.__conf.keys():
|
|
907
1034
|
# compatibility with version 2
|
|
908
1035
|
ids = self.__getConfVar(
|
|
@@ -920,9 +1047,14 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
920
1047
|
# udata = {ky: userdata[ky] for ky in missingKeys}
|
|
921
1048
|
if userdata:
|
|
922
1049
|
userdata.update(udata)
|
|
1050
|
+
ids = list(set(ids or []) - set(cachedss))
|
|
1051
|
+
self.debug("__createConfiguration: Create dynamic components: %s"
|
|
1052
|
+
% self.__oddmntgrp)
|
|
923
1053
|
self.__createDynamicComponent(
|
|
924
|
-
dsNotFound if dyncp else [], ids
|
|
1054
|
+
dsNotFound if dyncp else [], ids, udata, nexuscomponents)
|
|
925
1055
|
nexuscomponents.append(str(self.__dynamicCP))
|
|
1056
|
+
self.debug("__createConfiguration: Add Components: %s"
|
|
1057
|
+
% self.__oddmntgrp)
|
|
926
1058
|
|
|
927
1059
|
if cfm:
|
|
928
1060
|
self.info("Sardana Components %s" % cpReq.keys())
|
|
@@ -970,25 +1102,38 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
970
1102
|
if self.__macro:
|
|
971
1103
|
self.__macro().debug(
|
|
972
1104
|
"VAR %s" % self.__nexussettings_device.configVariables)
|
|
1105
|
+
self.debug("__createConfiguration: Update Config Varialels: %s"
|
|
1106
|
+
% self.__oddmntgrp)
|
|
973
1107
|
self.__command(self.__nexussettings_device,
|
|
974
1108
|
"updateConfigVariables")
|
|
975
1109
|
|
|
976
|
-
self.debug("Aliases: %s"
|
|
977
|
-
|
|
1110
|
+
self.debug("__createConfiguration: Aliases: %s"
|
|
1111
|
+
% str(self.__aliases))
|
|
1112
|
+
self.debug("__createConfiguration: Switching to STEP mode: %s"
|
|
1113
|
+
% stepdss)
|
|
978
1114
|
oldtoswitch = self.__getServerVar("stepdatasources", "[]", False)
|
|
979
1115
|
stepdss = str(json.dumps(list(toswitch)))
|
|
1116
|
+
self.debug("__createConfiguration: Set STEP datasources: %s"
|
|
1117
|
+
% self.__oddmntgrp)
|
|
980
1118
|
self.__nexussettings_device.stepdatasources = stepdss
|
|
1119
|
+
self.debug("__createConfiguration: Set LINK datasources: %s"
|
|
1120
|
+
% self.__oddmntgrp)
|
|
981
1121
|
if hasattr(self.__nexussettings_device, "linkdatasources"):
|
|
982
1122
|
self.__nexussettings_device.linkdatasources = stepdss
|
|
1123
|
+
self.debug("__createConfiguration: "
|
|
1124
|
+
"Create Writer configuration: %s" % self.__oddmntgrp)
|
|
983
1125
|
cnfxml = self.__command(
|
|
984
1126
|
self.__nexussettings_device, "createWriterConfiguration",
|
|
985
1127
|
nexuscomponents)
|
|
986
1128
|
finally:
|
|
1129
|
+
self.debug("__createConfiguration: Reset variables: %s"
|
|
1130
|
+
% self.__oddmntgrp)
|
|
987
1131
|
self.__nexussettings_device.configVariables = json.dumps(
|
|
988
1132
|
nexusvariables)
|
|
989
1133
|
if oldtoswitch is not None:
|
|
990
1134
|
self.__nexussettings_device.stepdatasources = oldtoswitch
|
|
991
1135
|
|
|
1136
|
+
self.debug("__createConfiguration: End: %s" % self.__oddmntgrp)
|
|
992
1137
|
return cnfxml
|
|
993
1138
|
|
|
994
1139
|
def _startRecordList(self, recordlist):
|
|
@@ -999,12 +1144,17 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
999
1144
|
:type recordlist: :class:`sardana.macroserver.scan.scandata.RecordList`
|
|
1000
1145
|
"""
|
|
1001
1146
|
try:
|
|
1147
|
+
self.debug('_startRecordList: Start %s' % self.__base_filename)
|
|
1002
1148
|
self.__env = self.__macro().getAllEnv() if self.__macro else {}
|
|
1003
1149
|
if self.__base_filename is None:
|
|
1004
1150
|
return
|
|
1005
1151
|
self.__udata = None
|
|
1006
1152
|
|
|
1153
|
+
self.debug('_startRecordList: Set NeXus %s'
|
|
1154
|
+
% self.__base_filename)
|
|
1007
1155
|
self.__setNexusDevices()
|
|
1156
|
+
self.debug('_startRecordList: Set Variables %s'
|
|
1157
|
+
% self.__base_filename)
|
|
1008
1158
|
|
|
1009
1159
|
appendentry = self.__getConfVar("AppendEntry", True)
|
|
1010
1160
|
appendscanid = not self.__setFileName(
|
|
@@ -1030,7 +1180,11 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1030
1180
|
self.__vars["vars"]["filename"] = str(self.filename)
|
|
1031
1181
|
|
|
1032
1182
|
envrecord = self.__appendRecord(self.__vars, 'INIT')
|
|
1183
|
+
self.debug('_startRecordList: Create Configuration %s'
|
|
1184
|
+
% self.__base_filename)
|
|
1033
1185
|
cnfxml = self.__createConfiguration(envrecord["data"])
|
|
1186
|
+
self.debug('_startRecordList: Set Remove dynamic components %s'
|
|
1187
|
+
% self.__base_filename)
|
|
1034
1188
|
rec = json.dumps(
|
|
1035
1189
|
envrecord, cls=NXS_FileRecorder.numpyEncoder)
|
|
1036
1190
|
# self.debug('XML: %s' % str(cnfxml))
|
|
@@ -1048,24 +1202,31 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1048
1202
|
self.__vars["data"]["beamtime_id"] = \
|
|
1049
1203
|
self.__vars["vars"]["beamtime_id"]
|
|
1050
1204
|
|
|
1205
|
+
self.debug('_startRecordList: Init writer %s'
|
|
1206
|
+
% self.__base_filename)
|
|
1051
1207
|
if hasattr(self.__nexuswriter_device, 'Init'):
|
|
1052
1208
|
self.__command(self.__nexuswriter_device, "Init")
|
|
1053
1209
|
self.__nexuswriter_device.fileName = str(self.filename)
|
|
1054
1210
|
self.__command(self.__nexuswriter_device, "openFile")
|
|
1055
1211
|
self.__nexuswriter_device.xmlsettings = cnfxml
|
|
1056
1212
|
|
|
1057
|
-
|
|
1213
|
+
if "DEBUG_INIT_DATA" in self.writerModes:
|
|
1214
|
+
self.debug('_startRecordList: INIT_DATA: %s' % str(envRec))
|
|
1058
1215
|
|
|
1216
|
+
self.debug('_startRecordList: Set JSON %s' % self.__base_filename)
|
|
1059
1217
|
self.__nexuswriter_device.jsonrecord = rec
|
|
1060
1218
|
self.writerModes = self.__variableList(
|
|
1061
1219
|
"NeXusWriterModes")
|
|
1062
1220
|
if "NOINIT" in self.writerModes:
|
|
1063
1221
|
self.__nexuswriter_device.skipAcquisition = True
|
|
1064
1222
|
|
|
1223
|
+
self.debug('_startRecordList SE: Open Entry %s' %
|
|
1224
|
+
self.__base_filename)
|
|
1065
1225
|
self.__command(self.__nexuswriter_device, "openEntry")
|
|
1066
1226
|
except Exception:
|
|
1067
1227
|
self.__removeDynamicComponent()
|
|
1068
1228
|
raise
|
|
1229
|
+
self.debug('_startRecordList SE: END %s' % self.__base_filename)
|
|
1069
1230
|
|
|
1070
1231
|
def __appendRecord(self, var, mode=None):
|
|
1071
1232
|
""" merges userdata with variable dictionary
|
|
@@ -1151,9 +1312,10 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1151
1312
|
if "NOSTEP" in self.writerModes:
|
|
1152
1313
|
self.__nexuswriter_device.skipAcquisition = True
|
|
1153
1314
|
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1315
|
+
if "DEBUG_STEP_DATA" in self.writerModes:
|
|
1316
|
+
self.debug('_writeRecord DATA: {"data":%s}' % json.dumps(
|
|
1317
|
+
record.data,
|
|
1318
|
+
cls=NXS_FileRecorder.numpyEncoder))
|
|
1157
1319
|
|
|
1158
1320
|
jsonString = '{"data":%s}' % json.dumps(
|
|
1159
1321
|
record.data,
|
|
@@ -1217,7 +1379,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1217
1379
|
self.__env = self.__macro().getAllEnv() if self.__macro else {}
|
|
1218
1380
|
envRec = recordlist.getEnviron()
|
|
1219
1381
|
|
|
1220
|
-
|
|
1382
|
+
if "DEBUG_FINAL_DATA" in self.writerModes:
|
|
1383
|
+
self.debug('_endRecordList: FINAL_DATA: %s ' % str(envRec))
|
|
1221
1384
|
|
|
1222
1385
|
tzone = self.__getConfVar("TimeZone", self.__timezone)
|
|
1223
1386
|
self.__vars["data"]["end_time"] = \
|
|
@@ -1286,7 +1449,7 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1286
1449
|
if isinstance(msvar, str):
|
|
1287
1450
|
msvar = re.split(r"[-;,.\s]\s*", msvar)
|
|
1288
1451
|
if msvar:
|
|
1289
|
-
self.debug('%s: %s' % (variable, str(msvar)))
|
|
1452
|
+
self.debug('__variableList: %s: %s' % (variable, str(msvar)))
|
|
1290
1453
|
return msvar
|
|
1291
1454
|
|
|
1292
1455
|
def __rawfilename(self, serial):
|
|
@@ -1491,7 +1654,8 @@ class NXS_FileRecorder(BaseFileRecorder):
|
|
|
1491
1654
|
(pdir, fname, entryname), rt, sname)
|
|
1492
1655
|
else:
|
|
1493
1656
|
h5writer.link("%s:/%s" % (fname, entryname), rt, sname)
|
|
1494
|
-
self.debug("
|
|
1657
|
+
self.debug("__createMeasurementFile: "
|
|
1658
|
+
"Link '%s' in '%s' created " % (sname, mntname))
|
|
1495
1659
|
rt.close()
|
|
1496
1660
|
fl.close()
|
|
1497
1661
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
{sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/not-zip-safe
RENAMED
|
File without changes
|
{sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/requires.txt
RENAMED
|
File without changes
|
{sardana-nxsrecorder-3.29.1 → sardana-nxsrecorder-3.33.0}/sardana_nxsrecorder.egg-info/top_level.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|