There are small typos in:
- closure/goog/base.js
- core/contextmenu_items.js
- core/insertion_marker_manager.js
- core/toolbox/collapsible_category.js
- demos/blockfactory/workspacefactory/wfactory_controller.js
- demos/blockfactory/workspacefactory/wfactory_view.js
- tests/mocha/field_colour_test.js
Fixes:
- Should read `updates` rather than `udpates`.
- Should read `unhighlighting` rather than `unhiglighting`.
- Should read `then` rather than `tehn`.
- Should read `modified` rather than `modifed`.
- Should read `different` rather than `diffferent`.
- Should read `currently` rather than `currenly`.
- Should read `browser` rather than `broswer`.
... by not ever posting such comments from this workflow.
There will be a separate PR for the other workflow that does post
comments, because it needs to be in the master branch.
Part of #5659.
There are only 10 instances of ++x in our codebase, compared with over 500 instances of x++. The stlye guide has no opinion on which to use, nor do I. But the lack of consistency was making regex searches for bugs more difficult.
* refactor: Inline assign_reviewers script to avoid checkout
Per https://securitylab.github.com/research/github-actions-preventing-pwn-requests/
it is not safe to do a checkout of the submitter-supplied code
AND THEN RUN IT (via require). This is pretty bad.
We want to give this script more permissions by running it
`on: [pull_request_target]` (instead of `pull_request`); this would
give it permission to modify the PR (e.g. add comments, change
assignment). While it would be OK to do a checkout with default
parameters (which in `pull_request_target` would check out *our*
branch rather than the submitted one) it simplest just to inline
this small script and thereby obviate the need to do a checkout at all.
* chore: Give assign_reviewers action required permissions
Changing it from `on: [pull_request]` to `on: [pull_request_review]`
will give the action write access to our repository, allowing it to
change the assignment of the PR.
This is now safe as the script does not ever check out any
submitter-supplied code.
* docs: Comment tweaks for assign_reviewers.yml
* chore: update generators/javascript.js to const and let
* chore: update generators/lua.js to const and let
* chore: update generators/php.js to const and let
* chore: update generators/python.js to const and let
* chore: fix uses of var in core/block_dragger
* chore: fix uses of var in core/extensions.js
* chore: fix uses of var in core/field_multilineinput.js
* chore: fix uses of var in assorted core files
* chore: fix uses of var in node test runner and playground screenshot code
* fix: undefined return from measureFontMetrics
* fix: violations of no-const-assign
* chore: only one variable declaration per line
* chore: use const and let in blocks/lists.js
* chore: use const and let in blocks/logic.js
* chore: use const and let in blocks/loops.js
* chore: use const and let in blocks/math.js
* chore: use const and let in blocks/procedures.js
* chore: use const and let in blocks/text.js
* chore: use const and let in blocks/variables_dynamic.js
* chore: use const and let in blocks/variables.js
* fix: updateShape_ variable scoping
* fix: declarations in switch clauses
* other: change while loops to for loops
* fix: fix violation of no-cond-assign
* Bump google-closure-compiler from 20210601.0.0 to 20211006.0.0
Bumps [google-closure-compiler](https://github.com/google/closure-compiler-npm) from 20210601.0.0 to 20211006.0.0.
- [Release notes](https://github.com/google/closure-compiler-npm/releases)
- [Commits](https://github.com/google/closure-compiler-npm/compare/v20210601.0.0...v20211006.0.0)
---
updated-dependencies:
- dependency-name: google-closure-compiler
dependency-type: direct:development
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
* Remove deleted option from Closure Compiler arguments
The closure compiler no longer supports the undefinedNames warning
group (and indeed even prior to deletion it didn't do anything for
some time).
Per @lauraharker, enabling checkVars, missingProperties and
strictMissingProperties gives about the same check coverage; we
already enable the first two, while the third was already listed
but commented out for the time being.
* Provide externs for base.js functions
Per comment: fixes compiler errors from build:debug.
* Fix erroneous import
Blockly.serialization.ISerializer uses named exports, so we need to
destructure the import.
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Christopher Allen <cpcallen+git@google.com>
In compiled mode we don't need to add exports to the global Blockly
object because they'll already be there - and attempting to do so
causes problems when a project imports multiple separate copies of
Blockly (which it shouldn't, but many plugins do).
This is part of the fix for google/blockly-samples#902.
Our files are up to a decade old, and have churned so much, that the initial author of the file no longer has much meaning.
Furthermore, this will encourage developers to post to the developer group, rather than emailing Googlers (usually me) directly.