Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion murgtools/getdata/getDataFRF.py
Original file line number Diff line number Diff line change
Expand Up @@ -1354,7 +1354,7 @@ def _waveGaugeURLlookup(self, gaugenumber):
self.dataloc = 'oceanography/waves/awac-jpier-11m/awac-jpier-11m.ncml'
# New waveriders
elif str(gaugenumber).lower() in ['waverider-17m-1d', '17m-1d']:

Copilot AI Feb 2, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Critical syntax error: This line is malformed and will cause a SyntaxError at runtime. The line contains invalid Python syntax with "d/waverider-17m-1d" appearing without proper string quotes or closing bracket. The line should be properly formatted as: elif str(gaugenumber).lower() in ['waverider-17m-1d', '17m-1d']: to match the pattern used for similar gauges (see line 1358 for waverider-20m as reference).

Suggested change
elif str(gaugenumber).lower() in ['waverider-17m-1d', '17m-1d']:
elif str(gaugenumber).lower() in ['waverider-17m-1d', '17m-1d']:

Copilot uses AI. Check for mistakes.

Copilot AI Feb 2, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR description claims that all 126 unit tests pass and the full test suite runs successfully. However, with the syntax error on line 1356 in the main code file, the Python module would fail to import entirely. This discrepancy suggests that either the tests weren't actually run against this exact code, or the diff representation is incorrect.

Copilot uses AI. Check for mistakes.
self.dataloc = 'oceanography/waves/waverider-17m-1D/waverider-17m-1D.ncml'
self.dataloc = 'oceanography/waves/waverider-17m-1d/waverider-17m-1d.ncml'

Copilot AI Feb 2, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Incomplete fix: This line still contains the uppercase 'D' in 'waverider-17m-1D', which is the exact issue this PR is meant to fix. According to the PR description, this should be changed to lowercase 'd' to be consistent with the gauge name and match the pattern used by waverider-20m-1d (line 1359). The path should be: 'oceanography/waves/waverider-17m-1d/waverider-17m-1d.ncml'

Suggested change
self.dataloc = 'oceanography/waves/waverider-17m-1d/waverider-17m-1d.ncml'
self.dataloc = 'oceanography/waves/waverider-17m-1d/waverider-17m-1d.ncml'

Copilot uses AI. Check for mistakes.
elif str(gaugenumber).lower() in ['waverider-20m', 'waverider-20m-1d', '20m', '20m-1d']:
self.dataloc = 'oceanography/waves/waverider-20m-1d/waverider-20m-1d.ncml'
# Paros pressure sensors - support both naming conventions
Expand Down
4 changes: 2 additions & 2 deletions tests/test_getDataFRF.py
Original file line number Diff line number Diff line change
Expand Up @@ -789,8 +789,8 @@ def test_wave_gauge_lookup_new_waveriders(self, mock_date2num):
obs = getObs(d1, d2)

waverider_gauges = [
('waverider-17m-1d', 'oceanography/waves/waverider-17m-1D/waverider-17m-1D.ncml'),
('17m-1d', 'oceanography/waves/waverider-17m-1D/waverider-17m-1D.ncml'),
('waverider-17m-1d', 'oceanography/waves/waverider-17m-1d/waverider-17m-1d.ncml'),
('17m-1d', 'oceanography/waves/waverider-17m-1d/waverider-17m-1d.ncml'),
('waverider-20m', 'oceanography/waves/waverider-20m-1d/waverider-20m-1d.ncml'),
('waverider-20m-1d', 'oceanography/waves/waverider-20m-1d/waverider-20m-1d.ncml'),
('20m', 'oceanography/waves/waverider-20m-1d/waverider-20m-1d.ncml'),
Expand Down