Software > WeeWX
Nueva versión weewx 4.0.0
pachu:
Pues estaba haciendo unas pruebas para una segunda raspi con weewx y el script automático de jantoni y durante la instalación he visto pasar 4.0.0 :o :o
Novedades para los entendidos *+*
--------------------
weewx change history
--------------------
4.0.0 (30 Apr 2020)
Ported to Python 3. WeeWX should now run under Python 3.5 and greater, as
well as Python 2.7. Support for Python 2.5 and 2.6 has been dropped.
New facility for creating new user-defined derived types. See the Wiki
article https://github.com/weewx/weewx/wiki/WeeWX-V4-user-defined-types
WeeWX now uses the Python 'logging' facility. This means log, formats, and
other things can now be customized. Fixes issue #353.
Strings appearing in the data stream no longer cause a TypeError if they
can be converted to a number.
Strings can now be accumulated and extracted in the accumulators, making it
possible to include them in the database schemas.
The utility wee_reports now loads services, allowing it to use
user-supplied extensions. Fixes issue #95.
New default schema ("wview_extended") that offers many new types. The old
schema is still supported. Fixes issue #115.
Optional, more flexible, way of specifying schemas for the daily summaries.
The old way is still supported.
The install process now offers to register a user's station with weewx.com.
The package MySQL-python, which we used previously, is not always available
on Python 3. Ported the MySQL code to use the package mysqlclient as an
alternative.
The default for WOW no longer throttles posting frequency (the default used
to be no more than once every 15 minutes).
Added new aggregate types minsum, minsumtime, sum_le. PR #382.
Unit group group_distance is now a first-class group.
Added new tag $python_version.
Ported to Python2-PyMySQL package on OpenSUSE.
Added new aggregation types 'first' (similar to 'last'), 'diff' (the
difference between last and first value in the aggregation interval), and
'tderiv' (the difference divided by the time difference).
Created new unit group 'group_energy2', defined as watt-seconds. Useful for
high resolution energy monitors.
An observation type known to the system, but not in a record, will now
return a proper ValueTuple, rather than UnknownType.
Type "stormStart" was added to the unit system. Fixes issue #380.
Added new aggregation type 'growdeg'. Similar to 'heatdeg', or 'cooldeg',
it measures growing degree-days. Basically, cooldeg, but with a different
base. Fixes issue #367. Thanks to user Clay Jackson for guidance!
Ported OS uptime to OpenBSD. Fixes issue #428. Thanks to user Jeff Ross!
Catch SSL certificate errors in uploaders. Retry after an hour. Fixes issue
#413.
Wunderfixer has been ported to the new WU API. This API requires an API
key, which you can get from the WU. Put it in weewx.conf. Added option
--upload-only. Thanks to user Leon Shaner! Fixes issues #414 and #445.
Wee_import can now import Weather Display monthly log files.
Fixed problem where sub-sections DegreeDays and Trend were located under
the wrong weewx.conf section. Fixes issue #432. Thanks to user mph for
spotting this!
Added new parameters to the Weather Underground uploader. Fixes issue #435.
Added new air quality types pm1_0, pm2_5, and pm10_0 to the unit system.
Added new unit microgram_per_meter_cubed. Added new unit group,
group_concentration.
Plist for the Mac launcher now includes a log file for stderr.
Night-day transition in plots now uses shortest travel distance around
color wheel to minimize extra colors. Fixes issue #457. Thanks to user Alex
Edwards!
Fixed bug that causes plots to fail when both min and max are zero. Fixes
issue #463.
Fixed problem with sqlite driver that can lead to memory growth. See PR
#467. Thanks to user Rich Bell!
Fixed bug that caused windrun to be calculated wrongly under METRICWX unit
system. Fixes issue #452.
If a bad value of 'interval' is encountered in a record, the program will
simply ignore it, rather than stopping. Address issue #375.
Change in how the archive timespan is calculated in the engine. This allows
oddball archive intervals. Fixes issue #469.
NOAA reports are now more tolerant of missing data. Fixes issue #300.
Use of strftime() date and time format codes in template file names is now
supported as an alternative to the legacy 'YYYY', 'MM' and 'DD'. The legacy
codes continue to be supported for backwards compatibility. Fixes issue
#415.
New --calc-missing action added to wee_database to calculate and store
derived observations.
wee_import now calculates missing derived observations once all imported
data has been saved to archive. Fixes issue #443.
wee_import now tolerates periods that contain no source data. Fixes issue
#499.
wee_import now accepts strings representing cardinal, intercardinal and
secondary intercardinal directions in CSV imports. Partially fixes issue
#238.
The field delimiter character may now be defined for wee_import CSV
imports.
Ignore historical records if the timestamp is in the future.
Can now recover from MariaDB-specific database connection error 1927.
Changed the name of the unit "litre" to "liter", making its spelling more
consistent with "meter". The spelling "litre" is still accepted.
Systemd type changed from "simple" to "forking". Thanks to user Jaap de
Munck for figuring this one out!
The configuration file is now an optional argument when running weewxd
directly. This means most users will be able to use the simple command line
'sudo weewxd'.
Use correct log path for netbsd and openbsd in logger setup.
StdWXCalculate no longer calculates anything by default. Instead, types to
be calculated must be listed in weewx.conf. See the Upgrade Guide.
setup.py install no longer saves the old 'bin' subdirectory. Instead, it
simply overwrites it.
jantoni:
Muchos cambios.
Si vais a actualizar, recordad hacer primero una copia de seguridad y luego una imagen de tarjeta SD.....por si hay que volver atrás.
Históricamente a la X.0.0 le ha seguido una X.0.0-1 muy rápido, je je
jmviper:
Bueno pues anoche actualicé weewx a la versión 4.0.0 y estas fueron mis experiencias....
Me lo comentó jantoni por lo que actualicé con sudo apt update y ya salió que se había cambiado a la versión 4 de weewx en el repositorio de weewx.
En la página de configuración de weewx han cambiado / añadido repositorios... el antiguo apuntaba a squeeze con la versión 3.9.2 de weewx en Python 2
Ahora ha añadido un nuevo repositorio en el que ya van a estar las nuevas versiones >=4 de weewx:
http://weewx.com/apt/
Borré el repositorio de weewx de squeeze con sudo rm /etc/apt/sources.list.d/weewx.list y después instalé el nuevo que ya va con debian 10 (buster) o futuros debian con
--- Código: ---curl -s http://weewx.com/apt/weewx-python3.list | sudo tee /etc/apt/sources.list.d/weewx.list
--- Fin del código ---
Con eso al actualizar con sudo apt update ya verá si hay nuevas versiones en el último repositorio.
Al reiniciar weewx vi algo que no me cuadraba:
orangepipc python[1995]: weewx[1995] INFO __main__: Initializing weewx version 4.0.0
orangepipc python[1995]: weewx[1995] INFO __main__: Using Python 2.7.16 (default, Oct 10 2019, 22:02:15)
Automáticamente no se pone a funcionar en Python 3 sino que usa la versión de Python que está por defecto activada en el sistema operativo, en mi caso la que usaba weewx 3.9.2 que es Python 2.7.16.
Weewx 4 puede usar indistintamente Python 2 ó 3.
Para hacerlo funcionar con la 3 ya que la 2 está obsoleta y hay que migrar a Python 3 preparé primero weewx 4 con los paquetes que le hacen falta:
sudo apt install python3-configobj python3-cheetah python3-pil python3-serial python3-usb python3-ephem
Con eso ya weewx 4 está listo para cambiar a Python 3
Hay que comprobar las versiones de Python que tenemos con ls -l /usr/bin/python*
yo en mi orange pi tengo la 2.7 y la 3.7 así que si no son las mismas en vuestro caso hay que poner la correcta en las próximas 2 líneas que pongo.
sudo update-alternatives --install /usr/bin/python python /usr/bin/python2.7 1
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3.7 2
sudo update-alternatives --config python
y nos saldrán las versiones de Python que tenemos y cuál está por defecto:
--- Código: --- There are 2 choices for the alternative python (providing /usr/bin/python).
Selection Path Priority Status
------------------------------------------------------------
0 /usr/bin/python2.7 2 auto mode
1 /usr/bin/python2.7 2 manual mode
* 2 /usr/bin/python3.7 1 manual mode
Press <enter> to keep the current choice[*], or type selection number:
--- Fin del código ---
En mi caso sale así ya que tengo activado Python 3 por defecto pero para activar la versión que se quiera correr por defecto se pone el número de la opción y ya está.
Se comprueba la versión en el terminal con python -V
root@orangepipc:~# python -V
Python 3.7.3
y cuando reiniciemos weewx tendremos:
orangepipc python[1995]: weewx[1995] INFO __main__: Initializing weewx version 4.0.0
orangepipc python[1995]: weewx[1995] INFO __main__: Using Python 3.7.3 (default, Dec 20 2019, 18:57:59)
Si no tenemos fallos ya tendremos weewx 4.0.0 funcionando con Python 3 :) :)
jantoni:
Yo creo que esperaré unos días.
El driver para TE923 parece ser que no funciona con Python3
Xavi-EA5ZF:
Buenos días, como incauto que ha hecho la instalación y ahora tiene problemas aviso:
El driver para las Davis parece no funcionar bien, si paras y relanzas weewx, en ocasiones no arranca porque pierde la comunicación con el data-loger.
Tampoco me funciona bien la generación de las pantallas, me da un error:
Reason: 'utf8' codec can't decode byte 0xed in position 5: invalid continuation byte
Creo que tiene algo que ver con los carácteres no ASCII de algún sitio, estoy investigando pero como veo que va para largo, creo que voy a desinstalar y volver a la versión antigua.
Saludos.
PD.- Una vez probado indicar que con la 3.9.2 todo vuelve a funcionar bien, creo que me voy a esperar unos días a volver intentar la actualización.
Ya estamos mayores y no andamos para mas sustos...
Xavi, EA5ZF
Navegación
[#] Página Siguiente
Ir a la versión completa