Skip to content

Commit

Permalink
Merge branch 'master' into lily/add-verbose-map-to-dataset
Browse files Browse the repository at this point in the history
  • Loading branch information
Lily Kuang committed Apr 25, 2023
2 parents 0afc61f + 6d55955 commit e02c80d
Show file tree
Hide file tree
Showing 93 changed files with 3,941 additions and 541 deletions.
116 changes: 57 additions & 59 deletions .github/workflows/docker-ephemeral-env.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Push ephmereral env image
name: Push ephemeral env image

on:
workflow_run:
Expand All @@ -17,12 +17,10 @@ jobs:
id: check
shell: bash
run: |
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
if [ -n "${{ (secrets.AWS_ACCESS_KEY_ID != '' &&
secrets.AWS_ACCESS_KEY_ID != '' &&
secrets.AWS_SECRET_ACCESS_KEY != '' &&
secrets.AWS_SECRET_ACCESS_KEY != '') || '' }}" ]; then
secrets.AWS_ACCESS_KEY_ID != '' &&
secrets.AWS_SECRET_ACCESS_KEY != '' &&
secrets.AWS_SECRET_ACCESS_KEY != '') || '' }}" ]; then
echo "has-secrets=1" >> "$GITHUB_OUTPUT"
fi
Expand All @@ -33,66 +31,66 @@ jobs:
runs-on: ubuntu-latest

steps:
- name: 'Download artifact'
uses: actions/github-script@v3.1.0
with:
script: |
const artifacts = await github.actions.listWorkflowRunArtifacts({
owner: context.repo.owner,
repo: context.repo.repo,
run_id: ${{ github.event.workflow_run.id }},
});
- name: "Download artifact"
uses: actions/github-script@v3.1.0
with:
script: |
const artifacts = await github.actions.listWorkflowRunArtifacts({
owner: context.repo.owner,
repo: context.repo.repo,
run_id: ${{ github.event.workflow_run.id }},
});
core.info('*** artifacts')
core.info(JSON.stringify(artifacts))
core.info('*** artifacts')
core.info(JSON.stringify(artifacts))
const matchArtifact = artifacts.data.artifacts.filter((artifact) => {
return artifact.name == "build"
})[0];
if(!matchArtifact) return core.setFailed("Build artifacts not found")
const matchArtifact = artifacts.data.artifacts.filter((artifact) => {
return artifact.name == "build"
})[0];
if(!matchArtifact) return core.setFailed("Build artifacts not found")
const download = await github.actions.downloadArtifact({
owner: context.repo.owner,
repo: context.repo.repo,
artifact_id: matchArtifact.id,
archive_format: 'zip',
});
var fs = require('fs');
fs.writeFileSync('${{github.workspace}}/build.zip', Buffer.from(download.data));
const download = await github.actions.downloadArtifact({
owner: context.repo.owner,
repo: context.repo.repo,
artifact_id: matchArtifact.id,
archive_format: 'zip',
});
var fs = require('fs');
fs.writeFileSync('${{github.workspace}}/build.zip', Buffer.from(download.data));
- run: unzip build.zip
- run: unzip build.zip

- name: Display downloaded files (debug)
run: ls -la
- name: Display downloaded files (debug)
run: ls -la

- name: Get SHA
id: get-sha
run: echo "::set-output name=sha::$(cat ./SHA)"
- name: Get SHA
id: get-sha
run: echo "::set-output name=sha::$(cat ./SHA)"

- name: Get PR
id: get-pr
run: echo "::set-output name=num::$(cat ./PR-NUM)"
- name: Get PR
id: get-pr
run: echo "::set-output name=num::$(cat ./PR-NUM)"

- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-west-2
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: us-west-2

- name: Login to Amazon ECR
id: login-ecr
uses: aws-actions/amazon-ecr-login@v1
- name: Login to Amazon ECR
id: login-ecr
uses: aws-actions/amazon-ecr-login@v1

- name: Load, tag and push image to ECR
id: push-image
env:
ECR_REGISTRY: ${{ steps.login-ecr.outputs.registry }}
ECR_REPOSITORY: superset-ci
SHA: ${{ steps.get-sha.outputs.sha }}
IMAGE_TAG: pr-${{ steps.get-pr.outputs.num }}
run: |
docker load < $SHA.tar.gz
docker tag $SHA $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG
docker tag $SHA $ECR_REGISTRY/$ECR_REPOSITORY:$SHA
docker push -a $ECR_REGISTRY/$ECR_REPOSITORY
- name: Load, tag and push image to ECR
id: push-image
env:
ECR_REGISTRY: ${{ steps.login-ecr.outputs.registry }}
ECR_REPOSITORY: superset-ci
SHA: ${{ steps.get-sha.outputs.sha }}
IMAGE_TAG: pr-${{ steps.get-pr.outputs.num }}
run: |
docker load < $SHA.tar.gz
docker tag $SHA $ECR_REGISTRY/$ECR_REPOSITORY:$IMAGE_TAG
docker tag $SHA $ECR_REGISTRY/$ECR_REPOSITORY:$SHA
docker push -a $ECR_REGISTRY/$ECR_REPOSITORY
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ FEATURE_FLAGS = {
}
```
If you want to use the same flag in the client code, also add it to the FeatureFlag TypeScript enum in [@superset-ui/core](https://github.com/apache-superset/superset-ui/blob/master/packages/superset-ui-core/src/utils/featureFlags.ts). For example,
If you want to use the same flag in the client code, also add it to the FeatureFlag TypeScript enum in [@superset-ui/core](https://github.com/apache/superset/blob/master/superset-frontend/packages/superset-ui-core/src/utils/featureFlags.ts). For example,
```typescript
export enum FeatureFlag {
Expand Down
3 changes: 2 additions & 1 deletion RESOURCES/FEATURE_FLAGS.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ These features are **finished** but currently being tested. They are usable, but
- DASHBOARD_EDIT_CHART_IN_NEW_TAB
- DASHBOARD_FILTERS_EXPERIMENTAL
- DASHBOARD_VIRTUALIZATION
- DRILL_BY
- DRILL_TO_DETAIL
- DYNAMIC_PLUGINS: [(docs)](https://superset.apache.org/docs/installation/running-on-kubernetes)
- ENABLE_JAVASCRIPT_CONTROLS
Expand All @@ -76,7 +77,6 @@ These features flags are **safe for production**. They have been tested and will
- ALLOW_ADHOC_SUBQUERY
- DASHBOARD_CROSS_FILTERS
- DASHBOARD_RBAC [(docs)](https://superset.apache.org/docs/creating-charts-dashboards/first-dashboard#manage-access-to-dashboards)
- DASHBOARD_NATIVE_FILTERS
- DATAPANEL_CLOSED_BY_DEFAULT
- DISABLE_LEGACY_DATASOURCE_EDITOR
- DRUID_JOINS
Expand All @@ -98,4 +98,5 @@ These features flags currently default to True and **will be removed in a future

[//]: # "PLEASE KEEP THE LIST SORTED ALPHABETICALLY"

- DASHBOARD_NATIVE_FILTERS
- GENERIC_CHART_AXES
1 change: 1 addition & 0 deletions UPDATING.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ assists people when migrating to a new version.
- [22798](https://github.com/apache/superset/pull/22798): To make the welcome page more relevant in production environments, the last tab on the welcome page has been changed from to feature all charts/dashboards the user has access to (previously only examples were shown). To keep current behavior unchanged, add the following to your `superset_config.py`: `WELCOME_PAGE_LAST_TAB = "examples"`
- [22328](https://github.com/apache/superset/pull/22328): For deployments that have enabled the "THUMBNAILS" feature flag, the function that calculates dashboard digests has been updated to consider additional properties to more accurately identify changes in the dashboard metadata. This change will invalidate all currently cached dashboard thumbnails.
- [21765](https://github.com/apache/superset/pull/21765): For deployments that have enabled the "ALERT_REPORTS" feature flag, Gamma users will no longer have read and write access to Alerts & Reports by default. To give Gamma users the ability to schedule reports from the Dashboard and Explore view like before, create an additional role with "can read on ReportSchedule" and "can write on ReportSchedule" permissions. To further give Gamma users access to the "Alerts & Reports" menu and CRUD view, add "menu access on Manage" and "menu access on Alerts & Report" permissions to the role.
- [22325](https://github.com/apache/superset/pull/22325): "RLS_FORM_QUERY_REL_FIELDS" is replaced by "RLS_BASE_RELATED_FIELD_FILTERS" feature flag. Its value format stays same.

### Potential Downtime

Expand Down
37 changes: 37 additions & 0 deletions docs/docs/databases/ocient.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
---
title: Ocient DB
hide_title: true
sidebar_position: 20
version: 1
---

## Ocient DB

The recommended connector library for Ocient is [sqlalchemy-ocient](https://pypi.org/project/sqlalchemy-ocient).

## Install the Ocient Driver

```
pip install sqlalchemy-ocient
```

## Connecting to Ocient

The format of the Ocient DSN is:

```shell
ocient://user:password@[host][:port][/database][?param1=value1&...]
```

The DSN for connecting to an `exampledb` database hosted at `examplehost:4050` with TLS enabled is:
```shell
ocient://admin:abc123@examplehost:4050/exampledb?tls=on
```

**NOTE**: You must enter the `user` and `password` credentials. `host` defaults to localhost,
port defaults to 4050, database defaults to `system` and `tls` defaults
to `unverified`.

## User Access Control

Make sure the user has privileges to access and use all required databases, schemas, tables, views, and warehouses, as the Ocient SQLAlchemy engine does not test for user or role rights by default.
2 changes: 1 addition & 1 deletion docs/docs/miscellaneous/country-map-tools.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ The Country Maps visualization already ships with the maps for the following cou
## Adding a New Country

To add a new country to the list, you'd have to edit files in
[@superset-ui/legacy-plugin-chart-country-map](https://github.com/apache-superset/superset-ui/tree/master/plugins/legacy-plugin-chart-country-map).
[@superset-ui/legacy-plugin-chart-country-map](https://github.com/apache/superset/tree/master/superset-frontend/plugins/legacy-plugin-chart-country-map).

1. Generate a new GeoJSON file for your country following the guide in [this Jupyter notebook](https://github.com/apache/superset/blob/master/superset-frontend/plugins/legacy-plugin-chart-country-map/scripts/Country%20Map%20GeoJSON%20Generator.ipynb).
2. Edit the countries list in [legacy-plugin-chart-country-map/src/countries.ts](https://github.com/apache/superset/blob/master/superset-frontend/plugins/legacy-plugin-chart-country-map/src/countries.ts).
Expand Down
4 changes: 4 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,10 @@ def get_git_sha() -> str:
"kylin": ["kylinpy>=2.8.1, <2.9"],
"mssql": ["pymssql>=2.1.4, <2.2"],
"mysql": ["mysqlclient>=2.1.0, <3"],
"ocient": [
"sqlalchemy-ocient>=1.0.0",
"pyocient>=1.0.15",
],
"oracle": ["cx-Oracle>8.0.0, <8.1"],
"pinot": ["pinotdb>=0.3.3, <0.4"],
"postgres": ["psycopg2-binary==2.9.5"],
Expand Down
3 changes: 2 additions & 1 deletion superset-embedded-sdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,8 @@
},
"repository": {
"type": "git",
"url": "git+https://github.com/apache/superset.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-embedded-sdk"
},
"homepage": "https://github.com/apache/superset#readme",
"bugs": {
Expand Down
3 changes: 2 additions & 1 deletion superset-frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
},
"repository": {
"type": "git",
"url": "git+https://github.com/apache/superset.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-frontend"
},
"license": "Apache-2.0",
"author": {
Expand Down
3 changes: 2 additions & 1 deletion superset-frontend/packages/generator-superset/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
},
"repository": {
"type": "git",
"url": "git+https://github.com/apache/superset.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-frontend/packages/generator-superset"
},
"license": "Apache-2.0",
"author": "Superset",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@
"keywords": [
"superset"
],
"homepage": "https://github.com/apache-superset/superset-ui#readme",
"homepage": "https://github.com/apache/superset/tree/master/superset-frontend/packages/superset-ui-chart-controls#readme",
"bugs": {
"url": "https://github.com/apache-superset/superset-ui/issues"
"url": "https://github.com/apache/superset/issues"
},
"repository": {
"type": "git",
"url": "git+https://github.com/apache-superset/superset-ui.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-frontend/packages/superset-ui-chart-controls"
},
"license": "Apache-2.0",
"author": "Superset",
Expand Down
7 changes: 4 additions & 3 deletions superset-frontend/packages/superset-ui-core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@
"keywords": [
"superset"
],
"homepage": "https://github.com/apache-superset/superset-ui#readme",
"homepage": "https://github.com/apache/superset/tree/master/superset-frontend/packages/superset-ui-core#readme",
"bugs": {
"url": "https://github.com/apache-superset/superset-ui/issues"
"url": "https://github.com/apache/superset/issues"
},
"repository": {
"type": "git",
"url": "git+https://github.com/apache-superset/superset-ui.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-frontend/packages/superset-ui-core"
},
"license": "Apache-2.0",
"author": "Superset",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ console.log(formatNumber('my_format', 1000));
```
It also define constants for common d3 formats. See the full list of formats in
[NumberFormats.js](https://github.com/apache-superset/superset-ui/blob/master/packages/superset-ui-number-format/src/NumberFormats.js).
[NumberFormats.js](https://github.com/apache/superset/blob/master/superset-frontend/packages/superset-ui-core/src/number-format/NumberFormats.ts).
```js
import { NumberFormats } from '@superset-ui-number-format';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ console.log(formatTime('my_format', new Date(2018)));
```
It also define constants for common d3 time formats. See
[TimeFormats.js](https://github.com/apache-superset/superset-ui/blob/master/packages/superset-ui-time-format/src/TimeFormats.js).
[TimeFormats.js](https://github.com/apache/superset/blob/master/superset-frontend/packages/superset-ui-core/src/time-format/TimeFormats.ts).
```js
import { TimeFormats } from '@superset-ui/core';
Expand Down
7 changes: 4 additions & 3 deletions superset-frontend/packages/superset-ui-demo/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
},
"repository": {
"type": "git",
"url": "git+https://github.com/apache-superset/superset-ui.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-frontend/packages/superset-ui-demo"
},
"keywords": [
"storybook",
Expand All @@ -26,9 +27,9 @@
],
"license": "Apache-2.0",
"bugs": {
"url": "https://github.com/apache-superset/superset-ui/issues"
"url": "https://github.com/apache/superset/issues"
},
"homepage": "https://github.com/apache-superset/superset-ui#readme",
"homepage": "https://github.com/apache/superset/tree/master/superset-frontend/packages/superset-ui-demo#readme",
"dependencies": {
"@data-ui/event-flow": "^0.0.84",
"@emotion/cache": "^11.4.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
],
"repository": {
"type": "git",
"url": "git+https://github.com/apache/superset.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-frontend/packages/superset-ui-switchboard"
},
"keywords": [
"switchboard",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,14 @@
"keywords": [
"superset"
],
"homepage": "https://github.com/apache-superset/superset-ui#readme",
"homepage": "https://github.com/apache/superset/tree/master/superset-frontend/plugins/legacy-plugin-chart-calendar#readme",
"bugs": {
"url": "https://github.com/apache-superset/superset-ui/issues"
"url": "https://github.com/apache/superset/issues"
},
"repository": {
"type": "git",
"url": "git+https://github.com/apache-superset/superset-ui.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-frontend/plugins/legacy-plugin-chart-calendar"
},
"license": "Apache-2.0",
"author": "Superset",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,18 @@
],
"repository": {
"type": "git",
"url": "git+https://github.com/apache-superset/superset-ui.git"
"url": "https://github.com/apache/superset.git",
"directory": "superset-frontend/plugins/legacy-plugin-chart-chord"
},
"keywords": [
"superset"
],
"author": "Superset",
"license": "Apache-2.0",
"bugs": {
"url": "https://github.com/apache-superset/superset-ui/issues"
"url": "https://github.com/apache/superset/issues"
},
"homepage": "https://github.com/apache-superset/superset-ui#readme",
"homepage": "https://github.com/apache/superset/tree/master/superset-frontend/plugins/legacy-plugin-chart-chord#readme",
"publishConfig": {
"access": "public"
},
Expand Down
Loading

0 comments on commit e02c80d

Please sign in to comment.