From ead2603219e9c6caa139301e631154e0ea567176 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 17 Dec 2020 21:22:42 +0000 Subject: [PATCH 1/5] Bump ini from 1.3.5 to 1.3.8 Bumps [ini](https://github.com/isaacs/ini) from 1.3.5 to 1.3.8. - [Release notes](https://github.com/isaacs/ini/releases) - [Commits](https://github.com/isaacs/ini/compare/v1.3.5...v1.3.8) Signed-off-by: dependabot[bot] --- package-lock.json | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/package-lock.json b/package-lock.json index 4e8984484..6857cdbe6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -3344,12 +3344,6 @@ "dev": true, "optional": true }, - "ini": { - "version": "1.3.5", - "bundled": true, - "dev": true, - "optional": true - }, "is-fullwidth-code-point": { "version": "1.0.0", "bundled": true, @@ -4542,9 +4536,9 @@ "dev": true }, "ini": { - "version": "1.3.5", - "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.5.tgz", - "integrity": "sha512-RZY5huIKCMRWDUqZlEi72f/lmXKMvuszcMBduliQ3nnWbx9X/ZBQO7DijMEYS9EhHBb2qacRUMtC7svLwe0lcw==", + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", "dev": true }, "interpret": { From edd475f37b02888819b87ddfca1d6eeebe68898a Mon Sep 17 00:00:00 2001 From: Neil Fraser Date: Tue, 5 Jan 2021 11:00:22 -0800 Subject: [PATCH 2/5] Update Blockly Games URL. (#4557) Currently there's a double-redirect (Blockly sends the user to appspot, Blockly Games then sends the user to its own domain). --- appengine/redirect.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/appengine/redirect.html b/appengine/redirect.html index 9c29bac59..110a56aa3 100644 --- a/appengine/redirect.html +++ b/appengine/redirect.html @@ -49,13 +49,13 @@ if (loc.match('/apps/plane/plane.html')) { if (loc.match('/apps/puzzle/')) { // Puzzle moved to Blockly Games on 15 Oct 2014. - loc = 'https://blockly-games.appspot.com/puzzle'; + loc = 'https://blockly.games/puzzle'; } else if (loc.match('/apps/maze/')) { // Maze moved to Blockly Games on 10 Nov 2014. - loc = 'https://blockly-games.appspot.com/maze'; + loc = 'https://blockly.games/maze'; } else if (loc.match('/apps/turtle/')) { // Turtle moved to Blockly Games on 10 Nov 2014. - loc = 'https://blockly-games.appspot.com/turtle'; + loc = 'https://blockly.games/turtle'; } else if (loc.match('/apps/')) { // Remaining apps moved to demos on 20 Nov 2014. loc = loc.replace('/apps/', '/demos/'); From 791ce2b7fb2fd78c0e3548a84623edabe79c386c Mon Sep 17 00:00:00 2001 From: alschmiedt Date: Tue, 9 Feb 2021 12:57:27 -0800 Subject: [PATCH 3/5] Migrate our tests to use github actions (#4614) (#4626) --- .github/workflows/build.yml | 41 +++++++++++++++++++ .travis.yml | 25 ----------- tests/generators/run_generators_in_browser.js | 4 +- tests/mocha/run_mocha_tests_in_browser.js | 4 +- tests/run_all_tests.sh | 13 +++--- tests/scripts/setup_linux_env.sh | 6 +-- 6 files changed, 54 insertions(+), 39 deletions(-) create mode 100644 .github/workflows/build.yml delete mode 100644 .travis.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 000000000..fba74a7d7 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,41 @@ +# This workflow will do a clean install, start the selenium server, and run +# all of our tests. + +name: Node.js CI + +on: push + +jobs: + build: + # TODO (#2114): re-enable osx build. + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [10.x, 12.x, 14.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v2 + + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v1 + with: + node-version: ${{ matrix.node-version }} + + - name: Npm Install + run: npm install + + - name: Linux Test Setup + if: runner.os == 'Linux' + run: source ./tests/scripts/setup_linux_env.sh + + - name: MacOS Test Setup + if: runner.os == 'macOS' + run: source ./tests/scripts/setup_osx_env.sh + + - name: Run + run: npm run test:run + + env: + CI: true diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 8384ecd53..000000000 --- a/.travis.yml +++ /dev/null @@ -1,25 +0,0 @@ -language: node_js -os: linux -dist: xenial -node_js: - - 10 - - 12 - - 14 -addons: - chrome: stable - firefox: latest - # TODO (#2114): re-enable osx build. - # - os: osx - # node_js: stable - # osx_image: xcode8.3 - # addons: - # firefox: latest -env: - - TRAVIS_CI=true -before_script: - - export DISPLAY=:99.0 - - if [ "${TRAVIS_OS_NAME}" == "linux" ]; then ( tests/scripts/setup_linux_env.sh ) fi - - if [ "${TRAVIS_OS_NAME}" == "osx" ]; then ( tests/scripts/setup_osx_env.sh ) fi - - sleep 2 -script: - - npm run test:run diff --git a/tests/generators/run_generators_in_browser.js b/tests/generators/run_generators_in_browser.js index 0a1692a7c..f0bafe10c 100644 --- a/tests/generators/run_generators_in_browser.js +++ b/tests/generators/run_generators_in_browser.js @@ -44,8 +44,8 @@ async function runGeneratorsInBrowser() { }, path: '/wd/hub' }; - // Run in headless mode on Travis. - if (process.env.TRAVIS_CI) { + // Run in headless mode on Github Actions. + if (process.env.CI) { options.capabilities['moz:firefoxOptions'] = { args: ['-headless'] }; diff --git a/tests/mocha/run_mocha_tests_in_browser.js b/tests/mocha/run_mocha_tests_in_browser.js index af89bd7c0..5adeabc2d 100644 --- a/tests/mocha/run_mocha_tests_in_browser.js +++ b/tests/mocha/run_mocha_tests_in_browser.js @@ -24,8 +24,8 @@ async function runMochaTestsInBrowser() { }, path: '/wd/hub' }; - // Run in headless mode on Travis. - if (process.env.TRAVIS_CI) { + // Run in headless mode on Github Actions. + if (process.env.CI) { options.capabilities['goog:chromeOptions'] = { args: ['--headless', '--no-sandbox', '--disable-dev-shm-usage'] }; diff --git a/tests/run_all_tests.sh b/tests/run_all_tests.sh index 78044ea24..2ab36c251 100755 --- a/tests/run_all_tests.sh +++ b/tests/run_all_tests.sh @@ -1,18 +1,17 @@ #!/bin/bash -if [ ! -z $TRAVIS ]; then echo "Executing run_all_tests.sh from $(pwd)"; fi +if [ ! -z $CI ]; then echo "Executing run_all_tests.sh from $(pwd)"; fi # ANSI colors BOLD_GREEN='\033[1;32m' BOLD_RED='\033[1;31m' ANSI_RESET='\033[0m' -travis_fold () { +gh_actions_fold () { local startOrEnd=$1 # Either "start" or "end" - local id=$2 # The fold id. No spaces. - if [ ! -z $TRAVIS ]; then - echo "travis_fold:$startOrEnd:$id" + if [ ! -z $CI ]; then + echo "::$startOrEnd::" fi } @@ -37,10 +36,10 @@ run_test_command () { echo "=======================================" echo "== $test_id" - travis_fold start $test_id + gh_actions_fold group $command local test_result=$? - travis_fold end $test_id + gh_actions_fold endgroup if [ $test_result -eq 0 ]; then echo -e "${BOLD_GREEN}SUCCESS:${ANSI_RESET} ${test_id}" else diff --git a/tests/scripts/setup_linux_env.sh b/tests/scripts/setup_linux_env.sh index 6e21e87e3..3a24ac784 100755 --- a/tests/scripts/setup_linux_env.sh +++ b/tests/scripts/setup_linux_env.sh @@ -1,8 +1,8 @@ #!/bin/bash -if [ "${TRAVIS_OS_NAME}" == "linux" ] +if [ "${RUNNER_OS}" == "Linux" ] then - export CHROME_BIN="/usr/bin/google-chrome" - sh -e /etc/init.d/xvfb start & + Xvfb :99 & + export DISPLAY=:99 & npm run test:prepare > /dev/null & fi From 26872cdcf67cecc94bcd58aa9b8b35633cbbdbe6 Mon Sep 17 00:00:00 2001 From: alschmiedt Date: Tue, 9 Feb 2021 14:20:12 -0800 Subject: [PATCH 4/5] Update pull request template (#4625) --- .github/PULL_REQUEST_TEMPLATE.md | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index 211fff419..53c7091aa 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -20,6 +20,14 @@ +#### Behavior Before Change + + + +#### Behavior After Change + + + ### Reason for Changes @@ -31,7 +39,7 @@ - uncomment the systems in the list below. --> -Tested on: + From d7e9eaff0fd533e8bfda905c8eb02a16722af89d Mon Sep 17 00:00:00 2001 From: Maribeth Bottorff Date: Wed, 10 Feb 2021 16:40:17 -0800 Subject: [PATCH 5/5] Reorganize README.md and add more links (#4620) * Update README.md * Copied the introductory statement from the dev site. The devsite introduction makes it more clear that Blockly is a library, not a standalone application. but I can change this back if we are attached to the original statement. * Kept the image at the top, despite it not showing in the diff preview * Added an explicit Getting Started section with links to the main resources and where to get help * Added info on blockly-samples * Fleshed out the Contributing section * Added info on beta channel * Updated date of next release, definition of major and patch update, and some other minor release info (it said we were on major version 2) * Switched the order of "branches" and "new APIs" so they reference each other in a logical order --- README.md | 68 +++++++++++++++++++++++++++++++++++++++---------------- 1 file changed, 48 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index 202aa636a..0b95ca1c7 100644 --- a/README.md +++ b/README.md @@ -1,41 +1,58 @@ # Blockly [![Build Status]( https://travis-ci.org/google/blockly.svg?branch=master)](https://travis-ci.org/google/blockly) - -Google's Blockly is a web-based, visual programming editor. Users can drag -blocks together to build programs. All code is free and open source. - -**The project page is https://developers.google.com/blockly/** +Google's Blockly is a library that adds a visual code editor to web and mobile apps. The Blockly editor uses interlocking, graphical blocks to represent code concepts like variables, logical expressions, loops, and more. It allows users to apply programming principles without having to worry about syntax or the intimidation of a blinking cursor on the command line. All code is free and open source. ![](https://developers.google.com/blockly/images/sample.png) -Blockly has an active [developer forum](https://groups.google.com/forum/#!forum/blockly). Please drop by and say hello. Show us your prototypes early; collectively we have a lot of experience and can offer hints which will save you time. We actively monitor the forums and typically respond to questions within 2 working days. +## Getting Started with Blockly + +Blockly has many resources for learning how to use the library. Start at our [Google Developers Site](https://developers.google.com/blockly) to read the documentation on how to get started, configure Blockly, and integrate it into your application. The developers site also contains links to: + +* [Getting Started article](https://developers.google.com/blockly/guides/get-started/web) +* [Getting Started codelab](https://blocklycodelabs.dev/codelabs/getting-started/index.html#0) +* [More codelabs](https://blocklycodelabs.dev/) +* [Demos and plugins](https://google.github.io/blockly-samples/) Help us focus our development efforts by telling us [what you are doing with Blockly](https://developers.google.com/blockly/registration). The questionnaire only takes a few minutes and will help us better support the Blockly community. -Cross-browser Testing Platform and Open Source <3 Provided by [Sauce Labs](https://saucelabs.com) +### Installing Blockly -We support IE11 and test it using [BrowserStack](https://browserstack.com) +Blockly is [available on npm](https://www.npmjs.com/package/blockly). -Want to contribute? Great! First, read [our guidelines for contributors](https://developers.google.com/blockly/guides/modify/contributing). - -## Releases - -The next major release will be **December 17th, 2020**. - -We release by pushing the latest code to the master branch, followed by updating our [docs](https://developers.google.com/blockly) and [demo pages](https://blockly-demo.appspot.com). We typically release a new version of Blockly once a quarter (every 3 months). If there are breaking bugs, such as a crash when performing a standard action or a rendering issue that makes Blockly unusable, we will cherry-pick fixes to master between releases to fix them. The [releases page](https://github.com/google/blockly/releases) has a list of all releases. - -Releases are tagged by the release date (YYYYMMDD) with a leading '2.' and a trailing '.0' in case we ever need a major or minor version (such as [2.20190722.1](https://github.com/google/blockly/tree/2.20190722.1)). If you're using npm, you can install the ``blockly`` package on npm: ```bash npm install blockly ``` -### New APIs +For more information on installing and using Blockly, see the [Getting Started article](https://developers.google.com/blockly/guides/get-started/web). -Once a new API is merged into master it is considered beta until the following release. We generally try to avoid changing an API after it has been merged to master, but sometimes we need to make changes after seeing how an API is used. If an API has been around for at least two releases we'll do our best to avoid breaking it. +### Getting Help +* [Report a bug](https://developers.google.com/blockly/guides/modify/contribute/write_a_good_issue) or file a feature request on GitHub +* Ask a question, or search others' questions, on our [developer forum](https://groups.google.com/forum/#!forum/blockly). You can also drop by to say hello and show us your prototypes; collectively we have a lot of experience and can offer hints which will save you time. We actively monitor the forums and typically respond to questions within 2 working days. -Unreleased APIs may change radically. Anything that is in `develop` but not `master` is subject to change without warning. +### blockly-samples + +We have a number of resources such as example code, demos, and plugins in another repository called [blockly-samples](https://github.com/google/blockly-samples/). A plugin is a self-contained piece of code that adds functionality to Blockly. Plugins can add fields, define themes, create renderers, and much more. For more information, see the [Plugins documentation](https://developers.google.com/blockly/guides/plugins/overview). + +## Contributing to Blockly + +Want to make Blockly better? We welcome contributions to Blockly in the form of pull requests, bug reports, documentation, answers on the forum, and more! Check out our [Contributing Guidelines](https://developers.google.com/blockly/guides/modify/contributing) for more information. You might also want to look for issues tagged "[Help Wanted](https://github.com/google/blockly/labels/help%20wanted)" which are issues we think would be great for external contributors to help with. + +## Releases + +The next major release will be **March 25th, 2021**. + +We release by pushing the latest code to the master branch, followed by updating the npm package, our [docs](https://developers.google.com/blockly), and [demo pages](https://google.github.io/blockly-samples/). We typically release a new version of Blockly once a quarter (every 3 months). If there are breaking bugs, such as a crash when performing a standard action or a rendering issue that makes Blockly unusable, we will cherry-pick fixes to master between releases to fix them. The [releases page](https://github.com/google/blockly/releases) has a list of all releases. + +Releases are tagged by the release date (YYYYMMDD) with a leading '4.' and a trailing '.0' in case we ever need a major or patch version (such as [2.20190722.1](https://github.com/google/blockly/tree/2.20190722.1)). Releases that have breaking changes or are otherwise not backwards compatible will have a new major version. Patch versions are reserved for bug-fix patches between scheduled releases. + +We now have a [beta release on npm](https://www.npmjs.com/package/blockly?activeTab=versions). If you'd like to test the upcoming release, or try out a not-yet-released new API, you can use the beta channel with: + +```bash +npm install blockly@beta +``` +As it is a beta channel, it may be less stable, and the APIs there are subject to change. ### Branches @@ -47,6 +64,12 @@ There are two main branches for Blockly. **other branches:** - Larger changes may have their own branches until they are good enough for people to try out. These will be developed separately until we think they are almost ready for release. These branches typically get merged into develop immediately after a release to allow extra time for testing. +### New APIs + +Once a new API is merged into master it is considered beta until the following release. We generally try to avoid changing an API after it has been merged to master, but sometimes we need to make changes after seeing how an API is used. If an API has been around for at least two releases we'll do our best to avoid breaking it. + +Unreleased APIs may change radically. Anything that is in `develop` but not `master` is subject to change without warning. + ## Issues and Milestones We typically triage all bugs within 2 working days, which includes adding any appropriate labels and assigning it to a milestone. Please keep in mind, we are a small team so even feature requests that everyone agrees on may not be prioritized. @@ -58,3 +81,8 @@ We typically triage all bugs within 2 working days, which includes adding any ap **Bug Bash Backlog** - These are bugs that we're still prioritizing. They haven't been added to a specific release yet, but we'll consider them for each release depending on relative priority and available time. **Icebox** - These are bugs that we do not intend to spend time on. They are either too much work or minor enough that we don't expect them to ever take priority. We are still happy to accept pull requests for these bugs. + +## Good to Know + +* Cross-browser Testing Platform and Open Source <3 Provided by [Sauce Labs](https://saucelabs.com) +* We support IE11 and test it using [BrowserStack](https://browserstack.com)