AAfghahi commented on a change in pull request #13443:
URL: https://github.com/apache/superset/pull/13443#discussion_r587880449



##########
File path: docker/pythonpath_dev/superset_config.py
##########
@@ -78,7 +78,95 @@ class CeleryConfig(object):
 
 CELERY_CONFIG = CeleryConfig
 SQLLAB_CTAS_NO_LIMIT = True
-
+FEATURE_FLAGS = {
+  "SHARE_QUERIES_VIA_KV_STORE": True,
+  "ESTIMATE_QUERY_COST":True,
+  "ENABLE_TEMPLATE_PROCESSING": True,
+  "THUMBNAILS": True,
+  "ENABLE_EXPLORE_JSON_CSRF_PROTECTION": False,
+  "LISTVIEWS_DEFAULT_CARD_VIEW": True,
+  "VERSIONED_EXPORT": True,
+  "SQLLAB_BACKEND_PERSISTENCE": True,
+  "SQL_VALIDATORS_BY_ENGINE": {"postgresql": "PostgreSQLValidator"},
+  "ENABLE_REACT_CRUD_VIEWS": False,
+  "SCHEDULED_QUERIES": {
+        'JSONSCHEMA': {
+            'title': 'Schedule',
+            'description': (
+                'In order to schedule a query, you need to specify when it '
+                'should start running, when it should stop running, and how '
+                'often it should run. You can also optionally specify '
+                'dependencies that should be met before the query is '
+                'executed. Please read the documentation for best practices '
+                'and more information on how to specify dependencies.'
+            ),
+            'type': 'object',
+            'properties': {
+                'output_table': {
+                    'type': 'string',
+                    'title': 'Output table name',
+                },
+                'start_date': {
+                    'type': 'string',
+                    'title': 'Start date',
+                    # date-time is parsed using the chrono library, see
+                    # https://www.npmjs.com/package/chrono-node#usage
+                    'format': 'date-time',
+                    'default': 'tomorrow at 9am',
+                },
+                'end_date': {
+                    'type': 'string',
+                    'title': 'End date',
+                    # date-time is parsed using the chrono library, see
+                    # https://www.npmjs.com/package/chrono-node#usage
+                    'format': 'date-time',
+                    'default': '9am in 30 days',
+                },
+                'schedule_interval': {
+                    'type': 'string',
+                    'title': 'Schedule interval',
+                },
+                'dependencies': {
+                    'type': 'array',
+                    'title': 'Dependencies',
+                    'items': {
+                        'type': 'string',
+                    },
+                },
+            },
+        },
+        'UISCHEMA': {
+            'schedule_interval': {
+                'ui:placeholder': '@daily, @weekly, etc.',
+            },
+            'dependencies': {
+                'ui:help': (
+                    'Check the documentation for the correct format when '
+                    'defining dependencies.'
+                ),
+            },
+        },
+        'VALIDATION': [
+            # ensure that start_date <= end_date
+            {
+                'name': 'less_equal',
+                'arguments': ['start_date', 'end_date'],
+                'message': 'End date cannot be before start date',
+                # this is where the error message is shown
+                'container': 'end_date',
+            },
+        ],
+        # link to the scheduler; this example links to an Airflow pipeline
+        # that uses the query id and the output table as its name
+        'linkback': (
+            'https://airflow.example.com/admin/airflow/tree?'
+            'dag_id=query_${id}_${extra_json.schedule_info.output_table}'
+        ),
+    },
+}
+WTF_CSRF_ENABLED = False
+ENABLE_SCHEDULED_EMAIL_REPORTS = True
+ENABLE_ALERTS = True

Review comment:
       is that a folder that I have to create? I don't see it. 




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to