Absent a spec on area forecast matrices, and absent any problem reports on 
point forecast matrices, there isn’t much to go on here.

> On Oct 7, 2020, at 2:35 PM, Michael Bruski <michael.bru...@gmail.com> wrote:
> 
> 
> Hi John,
> 
> I've looked at several forecast matrices from my local and surrounding NWS 
> forecast offices and haven't seen anything format wise that would lead me to 
> think they would cause a problem for the forecast extension.  I have selected 
> several different AFMs and see they parse fine.  But I ran into this issue 
> with my local AFM and spent several hours trying to track down the cause.   
> The issue is not with the matrix itself but with text preceeding the DTG.   
> To test further, I put a cheap hack into the parse loop so that date2ts() 
> isn't called if the first word in 'line' is 'Including'.  This actually works 
> (in this specific instance) and a valid forecast is produced.  What other 
> lines of text might NWS put in the header preceeding the DTG, I just don't 
> know.    The URLs mentioned in forecast.py are dead links so I couldn't find 
> any specifics on decoding the reports.
> 
> I'm not terribly comfortable programming in python so I'm not sure the best 
> approach to work this issue but sending bad data to time.mktime() via 
> date2ts() is probably bad unless there is a way to trap the error.  Not meant 
> to criticize...  just my thoughts on how to make it better.
> 
> Mike/AJ9X
> 
>> On Wednesday, October 7, 2020 at 4:24:56 PM UTC-4 jo...@johnkline.com wrote:
>> Perhaps Area Forecast Matrix responses can’t be treated just like Point 
>> Forecast Matrix responses.  AFMs are only supported to the extent that they 
>> provide an identically formatted response as the PFM response.
>> 
>> What do you know about AFMs and the differences between them and PFMs?
>> 
>>>> On Oct 7, 2020, at 12:18 PM, Michael Bruski <michael...@gmail.com> wrote:
>>>> 
>>> 
>> 
>>> 
>>> Hi all,
>>> 
>>> First of all, I am running WeeWX 4.1.1 with forecast extension 3.4.0b10.
>>> 
>>> I had recently managed to use a Area Forecast Matrix for one location and 
>>> that is working fine.   Recently I tried to setup a second location to use 
>>> the AFM (different LID and FOID) and it fails to get a forecast even though 
>>> I see it in the web browser using the URL that forecast.py uses.  After 
>>> careful application of some trace print statements, I see the forecast is 
>>> succesfully download from the FOID and that the forecast for the specified 
>>> LID is also located and extracted but nothing gets parsed.  Below is a copy 
>>> of my trace output from the log:
>>> 
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> forecast downloaded successfully from 
>>> 'http://forecast.weather.gov/product.php?site=NWS&product=AFM&format=txt&issuedby=LWX'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'MDZ005-072100-'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Carroll-'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Including the cities of Eldersburg and Westminster'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: '137 
>>> PM EDT Wed Oct 7 2020'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: ''
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Date             Wed 10/07/20            Thu 10/08/20            Fri 
>>> 10/09/20'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'EDT 
>>> 3hrly     05 08 11 14 17 20 23 02 05 08 11 14 17 20 23 02 05 08 11 14 17 20'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'UTC 
>>> 3hrly     09 12 15 18 21 00 03 06 09 12 15 18 21 00 03 06 09 12 15 18 21 00'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: ''
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Max/Min                75 77 80    47 48 52    65 67 70    42 44 48    68 
>>> 70 73'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Temp                   76 76 68 61 56 51 50 60 65 64 55 50 47 45 45 61 68 
>>> 67 59'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Dewpt                  52 52 53 50 48 46 45 45 43 42 43 42 41 40 41 45 45 
>>> 46 47'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'RH  
>>>                    43 43 59 67 74 83 83 58 45 45 64 74 79 82 86 56 43 47 64'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Wind dir                W  W NW NW NW NW NW NW NW NW NW NW  W  W  W SW SW 
>>> SW  S'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Wind spd               19 17 10  6  5  5  6 11 12 10  5  3  1  2  1  4  6  
>>> 8  4'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Wind gust              33 31'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Clouds                 CL CL SC FW FW CL CL FW CL CL CL CL FW FW FW FW FW 
>>> FW SC'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'PoP 
>>> 12hr                     20          20           0           0           0'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'QPF 
>>> 12hr                      0           0           0           0           0'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Rain shwrs                 S  S'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: ''
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: ''
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Date          Sat 10/10/20  Sun 10/11/20  Mon 10/12/20  Tue 10/13/20'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'EDT 
>>> 6hrly     02 08 14 20   02 08 14 20   02 08 14 20   02 08 14 20'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'UTC 
>>> 6hrly     06 12 18 00   06 12 18 00   06 12 18 00   06 12 18 00'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: ''
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Min/Max          54    75      56    69      53    66      54    68'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Temp          55 56 73 66   61 58 66 60   56 55 63 59   56 56 65 61'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Dewpt         50 54 59 60   59 56 55 54   54 53 56 56   56 56 58 57'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'PWind dir         S    SW      SW    SE       E     E       E    SE'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Wind char        LT    GN      LT    LT      GN    GN      LT    LT'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'Avg 
>>> clouds    SC B1 B1 B1   B1 B1 B1 B1   B2 B2 B2 B2   B2 B2 B2 B1'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 'PoP 
>>> 12hr          5    20      30    30      40    40      30    30'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> 'Rain shwrs              S    C  C  C  C    C  C  C  C    C  C  C  C'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: ''
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: '$$'
>>> Oct  7 14:36:45 server weewx[3014] INFO user.forecast: NWSThread: NWS: 
>>> successfully extracted forecast for 'MDZ005'
>>> 
>>> Examining NWSParseForecast, nothing is parsed until the Date/Time Group (a 
>>> line with 7 tokens) is located.  In the above AFM another line preceeds the 
>>> DTG which also happens to have 7 tokens.  I think this line is being passed 
>>> to date2ts() which in turn fails and causes the parser to stop looking for 
>>> further input.  I didn't see a way to raise the issue on GitHub so I 
>>> thought I would bring this up here.
>>> 
>>> Mike/AJ9X
>>> 
>> 
>>> -- 
>>> You received this message because you are subscribed to the Google Groups 
>>> "weewx-user" group.
>>> To unsubscribe from this group and stop receiving emails from it, send an 
>>> email to weewx-user+...@googlegroups.com.
>>> To view this discussion on the web visit 
>>> https://groups.google.com/d/msgid/weewx-user/05fa293c-659c-4619-9b06-9ed97a30efa4o%40googlegroups.com.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "weewx-user" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to weewx-user+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/weewx-user/3936dc80-0d29-414f-a5b9-5f286bd659b1n%40googlegroups.com.

-- 
You received this message because you are subscribed to the Google Groups 
"weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to weewx-user+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/weewx-user/85F7E477-9A8C-4AF3-8713-4A121E5AE3A3%40johnkline.com.

Reply via email to