Opened 3 years ago

Closed 3 years ago

#13118 closed Patch - Bug Fix (fixed)

Mythweather Canada script is broken

Reported by: David Hampton <mythtv@…> Owned by: Stuart Auchterlonie
Priority: minor Milestone: 30.0
Component: Plugin - MythWeather Version: Master Head
Severity: medium Keywords:
Cc: Ticket locked: no


When I go into Setup -> InfoCenter? -> Weather -> Screen I see the following error message in the log:

WeatherSource::ProbeInfo?(/usr/local/share/mythtv/mythweather/scripts/ca_envcan/ -v): Cannot run script

Running the script by hand yields:

\C no longer supported in regex; marked by <-- HERE in m/Temperature:\</b\>\s*(-?\d*\.?\d*)\&deg\;\ <-- HERE C\s*\<br/\>/ at /usr/local/share/mythtv/mythweather/scripts/ca_envcan/ line 114. Compilation failed in require at /usr/local/share/mythtv/mythweather/scripts/ca_envcan/ line 24. BEGIN failed--compilation aborted at /usr/local/share/mythtv/mythweather/scripts/ca_envcan/ line 24.

Change History (3)

comment:1 Changed 3 years ago by David Hampton <mythtv@…>

comment:2 Changed 3 years ago by Stuart Auchterlonie

Milestone: needs_triage30.0
Owner: set to Stuart Auchterlonie
Status: newaccepted

comment:3 Changed 3 years ago by David Hampton <mythtv@…>

Resolution: fixed
Status: acceptedclosed

In 8f27146d1e3155bef2298b0033f804f23b8178bf/mythtv:

Make the Canadian weather scripts work again.

Fix the parsing code that is looking for the letter 'C' in the
temperature and dew-point lines. This was unnecessarily escaped as
'\C' which causes Perl to complain about a no longer supported regex.
Removing the escaping solves the problem.

github: closes #152
trac: fixes #13118

Note: See TracTickets for help on using tickets.