Closed ampprojectbot closed 3 years ago
This error exceeded the Nightly error threshold but appears to be well below thresholds for other release channels. Seems like the volume is low enough to mostly ignore this
@Enriqe: NodeList
does not have a forEach
method in all browsers. Please use src/types.js
's toArray
, or src/dom.js
's iterateCursor
Can we ban NodeList.forEach
and HTMLCollection.forEach
in our closure conformance config?
It's already banned, but it's not catching.
Could we stub it in e2e test fixtures so any call to NodeList#forEach
throws and fails the tests?
It's already banned, but it's not catching.
Could this be because our closure warning_level
is currently set to QUIET
?
// TODO(amphtml): Change 'QUIET' to 'DEFAULT' after ampproject/amphtml#32875 is merged.
warning_level: argv.warning_level || 'QUIET',
Notes:
warning_level
to DEFAULT
or VERBOSE
, but we still need to split up and merge that PR.QUIET
in the first place: https://github.com/ampproject/amphtml/pull/30987A lot of work has been done by @kristoferbaxter and @dvoytenko in ampproject/amphtml#32875 to fix existing errors that will let us set warning_level to DEFAULT or VERBOSE, but we still need to split up and merge that PR.
I keep trying to work on splitting apart that massive PR (mostly per analytics vendor) and not having the time.
Would there be someone else who can take this on?
To realistically being able to do that, I think we need to find a way to restrict errors/warnings to only src/
and extensions/
folders at first and we can expand the coverage once those are properly reported. Can we do that? If yes, I can volunteer to take on fixing errors (or reapplying fixes from #32875) to src/
and extensions/
.
We can add an option for warning_level
to the type checker and surface errors only for src/
and extensions/
. Should be easy since they're already checked in a single step.
Edit: Done in https://github.com/ampproject/amphtml/pull/33469.
Would there be someone else who can take this on?
I just chatted with @samouri, who is interested in driving the merging of these fixes and the switching of the default level from QUIET
to DEFAULT
or better.
Details
Error report: link First seen: Feb 25, 2021 Frequency: ~ 2,636/day
Stacktrace
Notes
@Enriqe
modifiedextensions/amp-story/1.0/amp-story-page.js:356-374
in #27367 (Mar 25, 2020)Seen in:
Possible assignees:
@Enriqe
/cc @ampproject/release-on-duty