]>
ToastFreeware Gitweb - chrisu/seepark.git/log
gregor herrmann [Wed, 3 Oct 2018 16:46:04 +0000 (18:46 +0200)]
loaddays: wrap .flush in a setTimeout
depending on location and browser, I still see empty charts.
gregor herrmann [Wed, 3 Oct 2018 16:45:51 +0000 (18:45 +0200)]
drop a commented out .flush
gregor herrmann [Wed, 12 Sep 2018 21:47:44 +0000 (23:47 +0200)]
add seepark_webapp
script to start/stop seepark webapp (i.e. waitress)
gregor herrmann [Mon, 10 Sep 2018 14:23:37 +0000 (16:23 +0200)]
partially revert previous commit re windy widget size
don't hardcode small width/height but set max-width for dynamic size
gregor herrmann [Sun, 9 Sep 2018 14:19:19 +0000 (16:19 +0200)]
resize windy iframe
(and update lat/long + zoom)
gregor herrmann [Fri, 7 Sep 2018 22:20:52 +0000 (00:20 +0200)]
experiment again with re-loading chart data
add unload:true, and add back .flush() which got lost in the refactoring
gregor herrmann [Thu, 6 Sep 2018 21:44:14 +0000 (23:44 +0200)]
add back .flush after chart creation.
another incidence of empty charts (timing issues?) after a manual reload of
the page ...
gregor herrmann [Thu, 6 Sep 2018 19:47:33 +0000 (21:47 +0200)]
turn on x grid lines on chrisu's request
gregor herrmann [Thu, 6 Sep 2018 16:19:19 +0000 (18:19 +0200)]
fix strftime format in current air/water updates
gregor herrmann [Thu, 6 Sep 2018 15:58:39 +0000 (17:58 +0200)]
fix updating current air/water: strftime expects a "new Date"
gregor herrmann [Thu, 6 Sep 2018 15:58:06 +0000 (17:58 +0200)]
don't ignore errors from fetch().then()
gregor herrmann [Thu, 6 Sep 2018 15:39:33 +0000 (17:39 +0200)]
deduplicate reloading; we already had an unused function for that
gregor herrmann [Thu, 6 Sep 2018 15:35:24 +0000 (17:35 +0200)]
reload from the correct different API endpoints for air and water
gregor herrmann [Wed, 5 Sep 2018 21:34:58 +0000 (23:34 +0200)]
reload and replace current air/water temperatures at top from js
gregor herrmann [Wed, 5 Sep 2018 21:33:52 +0000 (23:33 +0200)]
add 2 new routes /api/<version>/current{air,water}temperature
to get timestamp and value of current temperatures
gregor herrmann [Wed, 5 Sep 2018 21:33:09 +0000 (23:33 +0200)]
template: add spans with IDs fur current values
as a preparation for replacing them
gregor herrmann [Wed, 5 Sep 2018 21:24:42 +0000 (23:24 +0200)]
remove flush after creation, add flush after reload
gregor herrmann [Tue, 4 Sep 2018 20:56:50 +0000 (22:56 +0200)]
add windy widget in page template and minimal css
gregor herrmann [Tue, 4 Sep 2018 20:10:40 +0000 (22:10 +0200)]
typo in comment
gregor herrmann [Tue, 4 Sep 2018 20:09:49 +0000 (22:09 +0200)]
reload chart data in javascript instead of rereshing the whole page
gregor herrmann [Mon, 3 Sep 2018 16:38:16 +0000 (18:38 +0200)]
add workaround for not rendered points after reload
cf. e.g. https://github.com/c3js/c3/issues/975
gregor herrmann [Mon, 3 Sep 2018 16:37:36 +0000 (18:37 +0200)]
simplify onzoomend function
but leave it commented out because we never get fully back
gregor herrmann [Mon, 3 Sep 2018 16:02:08 +0000 (18:02 +0200)]
use strftime js library
that way we get german day/month names, and with a well-known formatting
gregor herrmann [Mon, 3 Sep 2018 15:53:02 +0000 (17:53 +0200)]
add strftime library
version v0.10.0
from https://github.com/samsonjs/strftime
gregor herrmann [Mon, 3 Sep 2018 15:48:22 +0000 (17:48 +0200)]
html template: use minified js/css for c3 and d3
gregor herrmann [Mon, 3 Sep 2018 15:36:08 +0000 (17:36 +0200)]
js: factor out width calculation into a function
gregor herrmann [Mon, 3 Sep 2018 15:03:51 +0000 (17:03 +0200)]
js: resize charts on window resize
gregor herrmann [Mon, 3 Sep 2018 14:30:33 +0000 (16:30 +0200)]
css: add some margin to the body
!important because otherwise the owm-css overrides it
gregor herrmann [Thu, 30 Aug 2018 16:49:44 +0000 (18:49 +0200)]
editorial change: move a def() around
gregor herrmann [Thu, 30 Aug 2018 16:45:39 +0000 (18:45 +0200)]
for datetime intervals, don't return lowest value (min()) but avg()
needs a conversion to/from unix timestamp
cf. https://dev.mysql.com/doc/refman/5.7/en/group-by-functions.html
and https://dev.mysql.com/doc/refman/5.7/en/date-and-time-functions.html
gregor herrmann [Thu, 30 Aug 2018 16:06:45 +0000 (18:06 +0200)]
add link to source code in html template
gregor herrmann [Wed, 29 Aug 2018 12:43:37 +0000 (14:43 +0200)]
merge master/owm.py into web
gregor herrmann [Sun, 26 Aug 2018 19:45:08 +0000 (21:45 +0200)]
js: comment out onzoomed
never really worked, and now is confusing with consolidated data
gregor herrmann [Sun, 26 Aug 2018 18:06:01 +0000 (20:06 +0200)]
README: remove obsolete waitress exploration results
Philipp Spitzer [Sun, 26 Aug 2018 18:01:09 +0000 (20:01 +0200)]
Add waitress configuration to README.
gregor herrmann [Fri, 24 Aug 2018 22:49:17 +0000 (00:49 +0200)]
change x tick labels for month charts, as requested by chrisu
gregor herrmann [Thu, 23 Aug 2018 14:32:41 +0000 (16:32 +0200)]
add notes about waitress to README
Philipp Spitzer [Wed, 22 Aug 2018 21:29:59 +0000 (23:29 +0200)]
Fix begin and end in select_openweatherdata_grouped.
Philipp Spitzer [Wed, 22 Aug 2018 21:10:58 +0000 (23:10 +0200)]
Implement grouping of openweathermapdata.
Philipp Spitzer [Wed, 22 Aug 2018 20:47:44 +0000 (22:47 +0200)]
Include timestamp and value label so that those columns appear in the output.
Philipp Spitzer [Wed, 22 Aug 2018 20:32:23 +0000 (22:32 +0200)]
Convert dict key to string to prevent an error (on rigel).
Philipp Spitzer [Wed, 22 Aug 2018 20:17:17 +0000 (22:17 +0200)]
Split select_sensordata and implement grouping.
Philipp Spitzer [Wed, 22 Aug 2018 19:33:41 +0000 (21:33 +0200)]
Add a sqlalchemy group by/having example
gregor herrmann [Tue, 21 Aug 2018 17:11:13 +0000 (19:11 +0200)]
update caption of new sensor
gregor herrmann [Tue, 21 Aug 2018 14:36:33 +0000 (16:36 +0200)]
add comment with URL of web colors
gregor herrmann [Tue, 21 Aug 2018 14:34:24 +0000 (16:34 +0200)]
js: add new sensor
gregor herrmann [Wed, 15 Aug 2018 22:57:17 +0000 (23:57 +0100)]
html template: more anti-caching settings
in the hopes that it helps against the refreshing problem.
spoiler: it doesn't.
gregor herrmann [Fri, 10 Aug 2018 18:04:16 +0000 (20:04 +0200)]
README: add ipv6 note
gregor herrmann [Thu, 9 Aug 2018 13:53:42 +0000 (15:53 +0200)]
format datetime in tooltip headers
gregor herrmann [Thu, 9 Aug 2018 13:22:35 +0000 (15:22 +0200)]
update c3 and d3
c3: 0.6.7
d3: 5.5.0
gregor herrmann [Thu, 9 Aug 2018 13:09:44 +0000 (15:09 +0200)]
remove import of our seeparklib
not used anymore since we get the openweathermap data from the database
gregor herrmann [Thu, 9 Aug 2018 12:56:54 +0000 (14:56 +0200)]
adjust sensor name (and tooltip regexp) again
gregor herrmann [Thu, 9 Aug 2018 01:44:27 +0000 (03:44 +0200)]
seepark_web.py: move 'mainsensor' in ini to section webapp
from section temperature which is used by seewasser.py to check all sensors,
and "mainsensor" is no a sensor name/file
gregor herrmann [Wed, 8 Aug 2018 22:58:26 +0000 (00:58 +0200)]
js: play with ordering. this all doesn't seem to work with timeseries charts.
gregor herrmann [Wed, 8 Aug 2018 22:02:36 +0000 (00:02 +0200)]
update names of sensors
gregor herrmann [Wed, 8 Aug 2018 15:42:58 +0000 (17:42 +0200)]
js: "fix" zooming
we have sensors vs. weather now, and need mor variables
gregor herrmann [Sun, 5 Aug 2018 18:54:53 +0000 (20:54 +0200)]
trailing whitespace
Philipp Spitzer [Mon, 11 Jun 2018 18:23:32 +0000 (20:23 +0200)]
Add config file command line argument.
gregor herrmann [Sun, 5 Aug 2018 17:27:49 +0000 (19:27 +0200)]
make web/README a bit more verbose
gregor herrmann [Sun, 5 Aug 2018 17:10:50 +0000 (19:10 +0200)]
resolution in consolidated mode: use <= for time intervals
gregor herrmann [Sun, 5 Aug 2018 17:08:30 +0000 (19:08 +0200)]
finally drop old "API" with random data
gregor herrmann [Sun, 5 Aug 2018 16:54:23 +0000 (18:54 +0200)]
change water (sensor) colours
gregor herrmann [Sun, 5 Aug 2018 16:43:01 +0000 (18:43 +0200)]
update regexp for extrating label names
gregor herrmann [Sun, 5 Aug 2018 16:41:26 +0000 (18:41 +0200)]
update sensorids and names
gregor herrmann [Fri, 3 Aug 2018 23:09:08 +0000 (01:09 +0200)]
js: make points on line chart smaller
gregor herrmann [Thu, 2 Aug 2018 11:27:27 +0000 (13:27 +0200)]
xtick format: fix year labels (month year)
still doesn't make a lot of sense with not enough data
gregor herrmann [Thu, 2 Aug 2018 11:23:40 +0000 (13:23 +0200)]
format tooltip names depending on water/air
gregor herrmann [Thu, 2 Aug 2018 11:11:43 +0000 (13:11 +0200)]
do some horribly wrong timezone magic
gregor herrmann [Thu, 2 Aug 2018 11:11:24 +0000 (13:11 +0200)]
we have air temperature charts!
gregor herrmann [Thu, 2 Aug 2018 10:10:28 +0000 (12:10 +0200)]
generalize convert_to_c3: sensors and weather have different fields
gregor herrmann [Thu, 2 Aug 2018 09:41:54 +0000 (11:41 +0200)]
oops, looks like we made a logic error when refactoring
gregor herrmann [Thu, 2 Aug 2018 09:32:07 +0000 (11:32 +0200)]
html+js: rename stuff to prepare for weather
Philipp Spitzer [Wed, 1 Aug 2018 21:12:00 +0000 (23:12 +0200)]
The air temperature is taken from the database now.
Philipp Spitzer [Wed, 1 Aug 2018 21:07:03 +0000 (23:07 +0200)]
Implement handling of ill-formatted datetime values in URL.
Philipp Spitzer [Wed, 1 Aug 2018 19:54:39 +0000 (21:54 +0200)]
Create API for openweathermap data.
Philipp Spitzer [Wed, 1 Aug 2018 19:30:34 +0000 (21:30 +0200)]
Add a working SQL example to group measurements into time slots.
Philipp Spitzer [Wed, 1 Aug 2018 19:27:17 +0000 (21:27 +0200)]
Ignore warning about duplicate key when inserting openweathermap data.
gregor herrmann [Fri, 27 Jul 2018 22:03:31 +0000 (00:03 +0200)]
remove debug print
Philipp Spitzer [Wed, 25 Jul 2018 21:09:52 +0000 (23:09 +0200)]
Implement writing openweathermap data to database.
Philipp Spitzer [Wed, 25 Jul 2018 20:03:18 +0000 (22:03 +0200)]
Make script ready for missing visibility information in JSON.
Philipp Spitzer [Wed, 18 Jul 2018 21:26:47 +0000 (23:26 +0200)]
Prepare consolidation of data.
Philipp Spitzer [Wed, 18 Jul 2018 20:56:00 +0000 (22:56 +0200)]
Split function select_sensordata().
Philipp Spitzer [Wed, 18 Jul 2018 20:24:06 +0000 (22:24 +0200)]
Move to_dict to JSONEncoder.
gregor herrmann [Thu, 5 Jul 2018 18:38:02 +0000 (20:38 +0200)]
brown paper bag commit: always test after changing variable names
(and rebase/fixup commits)
gregor herrmann [Thu, 5 Jul 2018 18:19:20 +0000 (20:19 +0200)]
first rather simple implementation of to_dict() for our Sensors object
gregor herrmann [Thu, 5 Jul 2018 17:37:59 +0000 (19:37 +0200)]
read main(water)sensor from ini file
[temperature]
mainsensor=
0316a21383ff
gregor herrmann [Thu, 5 Jul 2018 17:28:21 +0000 (19:28 +0200)]
try to be a bit more clever in finding our libraries
appending '..' to sys.path only works when seepark_web.py is started from
its directory, otherwise we get:
flask.cli.NoAppException: While importing "seepark_web", an ImportError was raised:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/flask/cli.py", line 235, in locate_app
__import__(module_name)
File "/home/gregoa/src/toastfreeware/seepark/web/seepark_web.py", line 14, in <module>
from seeparklib.openweathermap import openweathermap_json, OpenWeatherMapError
ModuleNotFoundError: No module named 'seeparklib'
gregor herrmann [Thu, 5 Jul 2018 17:19:57 +0000 (19:19 +0200)]
README: add python3-flask-sqlalchemy
(which depends on python3-flask and python3-sqlalchemy)
Philipp Spitzer [Wed, 4 Jul 2018 22:04:06 +0000 (00:04 +0200)]
Start to use sqlalchemy (not all API calls work).
Philipp Spitzer [Wed, 4 Jul 2018 19:18:11 +0000 (21:18 +0200)]
Use defaultdict to simplify code.
Philipp Spitzer [Wed, 4 Jul 2018 19:09:13 +0000 (21:09 +0200)]
Move formatting water temperature/time to template.
Philipp Spitzer [Wed, 4 Jul 2018 19:06:26 +0000 (21:06 +0200)]
Format air temperature and time values in template.
Philipp Spitzer [Wed, 4 Jul 2018 18:41:36 +0000 (20:41 +0200)]
Add command lin eparameter --debug.
Philipp Spitzer [Wed, 4 Jul 2018 18:38:09 +0000 (20:38 +0200)]
Use seeparklib.openweathermap.
Philipp Spitzer [Wed, 4 Jul 2018 18:33:27 +0000 (20:33 +0200)]
Use openweathermap module in web app.
Philipp Spitzer [Wed, 4 Jul 2018 18:33:09 +0000 (20:33 +0200)]
Create dedicated package seeparklib and add openweathermap module.
gregor herrmann [Sat, 23 Jun 2018 11:59:29 +0000 (13:59 +0200)]
html template: refresh page every 5 minutes; and don't cache
gregor herrmann [Sat, 16 Jun 2018 17:56:35 +0000 (19:56 +0200)]
show current/most recent air/water temperature on top of page
gregor herrmann [Sat, 16 Jun 2018 17:17:03 +0000 (19:17 +0200)]
remove debug rest
gregor herrmann [Fri, 15 Jun 2018 17:17:12 +0000 (19:17 +0200)]
we can have wind without degrees (only speed)