Process List Editor Enhancements: The process list editor has been refactored and improved, with a new Vue.js-based UI that supports group selection, copying, pasting of input processes. Thanks to @nchaveiro for the initial implementation which I then converted to Vue.js.
Support for input and feed processes with multiple arguments, e.g Power to kWh / custom minutes, which writes kWh per custom period such as half hourly. Thanks to @nchaveiro again for the initial work on this.
Feed Data Verification: A new feature to return the sha256sum of feed data for replication, ensuring data integrity. Used mostly to verify integrity of Emoncms.org replication and backups so far.
Email: The SwiftMailer dependency has been removed and replaced with a new native SMTP email class.
DevContainer Integration: The repository now includes .devcontainer files to simplify the development environment setup, thanks to @alexandrecuer
Improvements & Bug Fixes
PHP 8 & Deprecation Fixes: Fixes for PHP 8+ compatibility. Better handling of null values in input processing etc.
Code Formatting & Standards: Partial application (so far) of PSR2/12 coding standards for improved code consistency and readability.
It is probably best done as a post process. There are already max and min daily value input processors for input processors .. but not post processed I guess.
I’ve pushed a couple more features today to help with input management:
Simple button to clean inactive & un-configured inputs and devices: useful for clearing lots of spurious inputs, click on the leaf icon button on the top-right of the inputs page (this button only appears if there are inactive and un-configured inputs present):
Option to disable further input creation: Great for stopping continuous creation of spurious inputs and devices - if this issue is present. Button to disable further input creation can be found below the input list. Input creation can then be enabled easily by clicking on the ‘Enable Input Creation’ button.
@Trystan - I did the update from the admin page from the previous release and sadly now get
Fatal error: Uncaught Error: Call to undefined function tr() in /var/www/emoncms/Modules/app/app_menu.php:70 Stack trace: #0 /var/www/emoncms/core.php(284): require() #1 /var/www/emoncms/index.php(384): load_menu() #2 {main} thrown in /var/www/emoncms/Modules/app/app_menu.php on line 70
Hello @Bramco it sounds like the app module did not update to the latest version. Is there a chance that you had local changes that blocked the update of that module?
To resolve via SSH:
cd /var/www/emoncms/Modules/app
git status
If it’s stable do (alternatively git pull origin master).
git pull origin stable
If there are local changes you may need to remove them with:
No local changes, can’t remember now if I built it using the instructions, or just downloaded the image.
I’m already on stable, so the git pull stable tells me I’m already on stable and doesn’t do anything. So I still get the error.
pi@emonpi:/var/www/emoncms/Modules/app $ git status
On branch stable
Your branch is up to date with 'origin/stable'.
nothing to commit, working tree clean
pi@emonpi:/var/www/emoncms/Modules/app $ git pull origin stable
From https://github.com/emoncms/app
* branch stable -> FETCH_HEAD
Already up to date.
Simon
PS Apologies for the slow response, we’ve family here this weekend - so a little busy.
Trystan, any further thoughts on this? I could do with either fixing it or doing a rebuild - which obviously I’m not keen on doing again….
Simon
EDIT -
Not sure if this helps but here is something that an AI assistant had to say about the tr() function on line 70.
The `tr()` function is not a part of PHP; it is actually a function used in the Qt framework for internationalization, allowing applications to support multiple languages. In PHP, there is no built-in `tr()` function for this purpose.
Running apt-get update
Get:1 http://raspbian.raspberrypi.org/raspbian bullseye InRelease [15.0 kB]
Get:2 http://archive.raspberrypi.org/debian bullseye InRelease [39.0 kB]
Get:3 https://download.docker.com/linux/raspbian bullseye InRelease [26.6 kB]
Get:4 https://packages.sury.org/php bullseye InRelease [7,551 B]
Get:5 http://raspbian.raspberrypi.org/raspbian bullseye/main armhf Packages [13.2 MB]
Get:6 http://archive.raspberrypi.org/debian bullseye/main armhf Packages [330 kB]
Get:7 https://download.docker.com/linux/raspbian bullseye/stable armhf Packages [59.8 kB]
Err:4 https://packages.sury.org/php bullseye InRelease
The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key <[email protected]>
Fetched 13.7 MB in 15s (887 kB/s)
Reading package lists...
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: https://packages.sury.org/php bullseye InRelease: The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key <[email protected]>
W: Failed to fetch https://packages.sury.org/php/dists/bullseye/InRelease The following signatures were invalid: EXPKEYSIG B188E2B695BD4743 DEB.SURY.ORG Automatic Signing Key <[email protected]>
W: Some index files failed to download. They have been ignored, or old ones used instead.
Can’t see anything - all I get is the error the fatal error as above
Fatal error: Uncaught Error: Call to undefined function tr() in /var/www/emoncms/Modules/app/app_menu.php:70 Stack trace: #0 /var/www/emoncms/core.php(284): require() #1 /var/www/emoncms/index.php(384): load_menu() #2 {main} thrown in /var/www/emoncms/Modules/app/app_menu.php on line 70
pi@emonpi:/var/www/emoncms $ git status
On branch stable
Your branch is up to date with 'origin/stable'.
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: default-settings.ini
no changes added to commit (use "git add" and/or "git commit -a")
pi@emonpi:/var/www/emoncms $ git pull origin stable
remote: Enumerating objects: 1455, done.
remote: Counting objects: 100% (293/293), done.
remote: Compressing objects: 100% (107/107), done.
remote: Total 1455 (delta 200), reused 186 (delta 186), pack-reused 1162 (from 4)
Receiving objects: 100% (1455/1455), 1.37 MiB | 1.53 MiB/s, done.
Resolving deltas: 100% (920/920), completed with 30 local objects.
From https://github.com/emoncms/emoncms
* branch stable -> FETCH_HEAD
efcf93c3..995555e1 stable -> origin/stable
Updating efcf93c3..995555e1
error: Your local changes to the following files would be overwritten by merge:
default-settings.ini
Please commit your changes or stash them before you merge.
Aborting
Is it a problem with default settings?
Simon
PS Thanks for the help so far
EDIT - think we may begetting somewhere…..
I wanted to use the email functionality and put in a default email address. As far as I remember, I followed the instructions on the pop up for the email process.