changeset 452:ec97c29768e7

fetch_weather: Improve some debug messages.
author Matti Hamalainen <ccr@tnsp.org>
date Fri, 06 Oct 2017 17:30:06 +0300
parents a7249db002bd
children c69368f97c10
files fetch_weather.pl
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/fetch_weather.pl	Thu Sep 28 15:25:12 2017 +0300
+++ b/fetch_weather.pl	Fri Oct 06 17:30:06 2017 +0300
@@ -513,7 +513,8 @@
           if (scalar(@fmatches) != scalar(@fmitems))
           {
             print STDERR "Not enough items in scalar line #".$nline." (".
-              scalar(@fmatches). " vs ".scalar(@fmitems)."): ".$dline."\n";
+              scalar(@fmatches). " vs ".scalar(@fmitems)."): ".$dline."\n"
+              if (opt_get_int("debug") > 0);
           }
           else
           {
@@ -538,7 +539,8 @@
       }
       else
       {
-        print STDERR "Position and data line counts do not match.\n";
+        print STDERR "Position and data line counts do not match ".
+          scalar(@position_lines)." <> ".scalar(@data_lines)."\n";
         goto skip_it;
       }
       # XXX Hashify the array into lat/long keys