* Update Cypress element selectors
* Add seed data function to Cypress
* Change Cypress setup to be part of db-seed
* Add DatabaseSource selector to Create Data Source spec
* Add getElement command to Cypress
* Fix eslint issues
* Change Cypress getElement to getByTestId
* Add Percy and test it with the CI
* Change Percy dependency for CI to Cypress' Dockerfile
* Change Percy's execution to the docker container
- add --no-save to avoid errors on Dockerfile.cypress
- pass PERCY_TOKEN from the CI to docker container
* Fix missed char on CircleCI config file
* Move Percy execution back to host on the CI
* Test adding PERCY_TOKEN to frontend-e2e-tests on CI config
* Undo add PERCY_TOKEN to config.yml
* Add Percy token and .git folder to Cypress
* Remove Percy install from config.yml
* Ignore .git folder again and use Percy env vars instead
* Update PERCY_PULL_REQUEST to be CIRCLE_PR_NUMBER
* Update cypress-server.js to handle other cypress commands
- cypress-server.js -> cypress.js
- new commands added to cypress.js
- CircleCI config updated accordingly
- added a Homepage screenshot
* Remove trailing spaces
* Add Create Query spec
* Disable Cypress videos
* Update run browser to Chrome
* Add missing --browser chrome
* display correct error message when attempting to disable yourself
* 403 (Forbidden) feels like a better status code than 400 (Bad Request)
* fix broken test
* remove redundant error title
* take the first 8 characters for frontend version, not backend version
* run `npm run build` after version has been updated in CI
* `pack` should run last
* add SQLQuery class with tests for safe queries and non-safe tautology attacks
* add test for union query injections
* split .apply calls to newline
* add tests for comment attacks
* remove double underscore
* extract complex children check to variable
* inherit from object because I'm not a lamer
Co-Authored-By: rauchy <omer@rauchy.net>
* simplify cognitive complexity
* check that additional columns are not injected
* detect appended queries
* inline .apply calls
* move SQLQuery to it's own module
* move SQLQuery tests to their own module
* serialize SQLQuery instances
* raise an exception when attempting to serialize an unsafe query
* queries without parameters are safe
* remove redundant parentheses
* use cached properties
* rename SQLInjectionException to SQLInjectionError
* support multiple word params and param negations
* refactor out methods that don't involve any state
* don't cache text()
* reduce cognitive complexity
* getredash/redash#3015 When editing a dashboard title results in the visualizations being replaced by the loading markers
* CR1
Co-Authored-By: kravets-levko <levko.ne@gmail.com>
* add git-revision-webpack-plugin
* configure git-revision-webpack-plugin
* add commit to footer
* rename version and commit to backendVersion and frontendVersion
* rename version and commit to backendVersion and frontendVersion
* disable lint error due to use of globals
* fix snapshot test
* read frontend version from VERSION file instead latest git revision
* directly require from version.json file instead of going through WebPack's DefinePlugin
* run snapshots
* Hive: fix issues in building options.
* Hive: add missing import.
* Split Hive into two query runners: one for http and a regular one.
* Upgrade pyhive to support http.
* Specific implementation for databricks:
* Different schema loader, because column names are different (or Hive's schema loader is broken).
* Simpler configuration.
* Simplify Databricks setup even more by removing username.
* Fix tag counts for dashboards to be distinct.
This also makes use of the Dashboard.all base query.
Fix#3108.
* Use Query.all_queries as the base query for Query.all_tags.
* Add test case for Dashboard.all_tags.
* Add Rockset query runner
Per REST API documented here: https://docs.rockset.com/rest/
* Update rockset.py
* Add Rockset logo
* Refactor Rockset qury runner:
* More idomatic names for configuration.
* Move API code to separate class to make it easier removing it when we
switch to official library.
* Make Test Connection work.
* apply autopep8 to rockset.py
* keep query text in local state for now (#3107)
This will be unnecessary once the queryText prop isn't managed by Angular.
* Fix: make formatQuery work