Open jywarren opened 2 years ago
Confirmed purpleAirMarker layer shows a 302 error on the demo, message at https://purpleair-over-quota-2.appspot.com/
jquery.min.js:2 GET https://www.purpleair.com/data.json?fetchData=true&minimize=true&sensorsActive2=10080&orderby=L&nwlat=39.2173592639196&selat=38.47186888757717&nwlng=-77.65136718750001&selng=-76.24374389648439 net::ERR_FAILED 302
Should look at the PurpleAir API again to see what's up.
The AQICN layer looks fine though - markers appear normally. But, the error had been:
Aqicn layer
has circle markers in minimal mode:
AssertionError: Timed out retrying: Too many elements found. Found '1143', expected '2'.
Plus it failing to find a marker labeled "Spain".
It searches in this region: https://publiclab.github.io/leaflet-environmental-layers/example/index.html#lat=51.15&lon=13.45&zoom=4&layers=Standard
The FracTracker Mobile layer is a spreadsheet layer: https://spreadsheets.google.com/feeds/list/19j4AQmjWuELuzn1GIn0TFRcK42HjdHF_fsIa8jtM1yw/o4rmdye/public/values?alt=json and the Google Sheets spreadsheet API v3 was deprecated -- see:
For PurpleAir, the API is v1.8 now, not sure what it had been at the time the Cypress test was written, but the URL for markers is now:
vs the one we had:
PurpleAir changed their API
support for changes to historical API here: https://community.purpleair.com/t/purpleair-data-migration-to-bigquery-and-a-new-api/295
They dropped the /data.json style calls a little before?: https://community.purpleair.com/t/discontinuation-of-the-json-and-data-json-urls/713/2
We had expected this format: https://github.com/publiclab/leaflet-environmental-layers/blob/main/cypress/fixtures/purpleMarker.json
Basically we need to begin using the new API:
On the AQICN front, it's supposed to be checking data from this fixtures file, which we intercept via a spy: https://github.com/publiclab/leaflet-environmental-layers/blob/main/cypress/fixtures/aqicn.json
For whatever reason, the test is no longer properly finding the fixture data...?
Cypress has deprecated cy.server()
and cy.route()
in v6, but we're on v4... https://docs.cypress.io/api/commands/intercept https://docs.cypress.io/api/commands/server
Some recent PRs that should be unrelated to tests like http-server are failing cypress tests: https://github.com/publiclab/leaflet-environmental-layers/runs/6688364021?check_suite_focus=true
no test runs on recent PRs have succeeded; some have limited layer-specific failures like #667
while others like the http-server one above are failing ALL cypress tests with the error:
I'm re-running https://github.com/publiclab/leaflet-environmental-layers/pull/662 just to see if it's intermittent.
Those with limited layer-specific failures include:
The tests failing are:
aqicn.spec.js
fractrackerMobile.spec.js
purpleAirMarker