-
Notifications
You must be signed in to change notification settings - Fork 130
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Json server fixes #649
Merged
Merged
Json server fixes #649
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ded when get_weather is called. Bug hollie#631
Updated Harmon Documentation
Doorbird merge
Fixes for broken code due to NOAA site changes. Bug hollie#631
Merge with Master
# Conflicts: # lib/site/Geo/WeatherNOAA.pm
…rrd ini params by default. Also fixed an issue which can cause a crash.
Thanks for this pull request! |
Since were changing the default weather RRD name, we should to check what name gets created on a fresh install. I also thought it might be nice to have a JSON option to pass another rrd as an option. This could be useful for folks that have more than one RRD on their system
|
weather_data.rrd is the default on a new install with no config settings,
just tested with my dev system and weather_rrd_update.pl.
I left the json config setting that was already there as the last option so
it will override the mh.private.ini if its configured, is that what you
mean?
my $rrd_file = "weather_data.rrd";
$rrd_file = $config_parms{weather_data_rrd}
if ( defined $config_parms{weather_data_rrd} );
if ( $rrd_file =~ m/.*\/(.*\.rrd)/ ) {
$rrd_file = $1;
}
$rrd_file = $json_data{'rrd_config'}->{'prefs'}->{'default_rrd'}
if ( defined $json_data{'rrd_config'}->{'prefs'}->{'default_rrd'}
);
_Wayne
…On Sat, Dec 17, 2016 at 2:54 PM, hplato ***@***.***> wrote:
Since were changing the default weather RRD name, we should to check what
name gets created on a fresh install.
I also thought it might be nice to have a JSON option to pass another rrd
as an option. This could be useful for folks that have more than one RRD on
their system
-
my $rrd_file = "weather.rrd";
-
my $rrd_file = "weather_data.rrd";
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#649 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AFZ3ea466bsklHq06IQmJFT_4Qxd-6sgks5rJEwVgaJpZM4LO1hf>
.
|
Perfect, thanks for checking that out.
I was thinking something like:
$rrd_file = $args{rrd_file}[0] if ( defined $args{rrd_file}[0] );
This would allow different sources to be graphed with a URL like this:
http://mh/ia7/#path=/rrd?now-6hour?indoor?rrd_file=doors.rrd
Of course, that’s just theory, I haven’t really tested this out yet as I just have one RRD source...
… On Dec 17, 2016, at 5:40 PM, Wayne Gatlin ***@***.***> wrote:
weather_data.rrd is the default on a new install with no config settings,
just tested with my dev system and weather_rrd_update.pl.
I left the json config setting that was already there as the last option so
it will override the mh.private.ini if its configured, is that what you
mean?
my $rrd_file = "weather_data.rrd";
$rrd_file = $config_parms{weather_data_rrd}
if ( defined $config_parms{weather_data_rrd} );
if ( $rrd_file =~ m/.*\/(.*\.rrd)/ ) {
$rrd_file = $1;
}
$rrd_file = $json_data{'rrd_config'}->{'prefs'}->{'default_rrd'}
if ( defined $json_data{'rrd_config'}->{'prefs'}->{'default_rrd'}
);
_Wayne
On Sat, Dec 17, 2016 at 2:54 PM, hplato ***@***.***> wrote:
> Since were changing the default weather RRD name, we should to check what
> name gets created on a fresh install.
>
> I also thought it might be nice to have a JSON option to pass another rrd
> as an option. This could be useful for folks that have more than one RRD on
> their system
>
> -
>
> my $rrd_file = "weather.rrd";
>
>
>
> -
>
> my $rrd_file = "weather_data.rrd";
>
>
> —
> You are receiving this because you authored the thread.
> Reply to this email directly, view it on GitHub
> <#649 (comment)>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/AFZ3ea466bsklHq06IQmJFT_4Qxd-6sgks5rJEwVgaJpZM4LO1hf>
> .
>
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub <#649 (comment)>, or mute the thread <https://github.com/notifications/unsubscribe-auth/AExbSFUR9C2u6GaMlPVIbknAL274erOCks5rJIDvgaJpZM4LO1hf>.
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fix for rrd file path not being pulled from rrd_dir and weather_data_rrd ini params by default in json_server.pl. Also fixed an issue which can cause MH to crash.