These are chat archives for getredash/redash

4th
Apr 2017
Debyani
@Debyani
Apr 04 2017 04:33
cool, thanks @arikfr for answering the multiple datasource question. I have another issue I am running into. I have a local setup with docker containers.
I am trying to connect to our athena source and followed instructions about adding the REDASH_ADDITIONAL_QUERY_RUNNERS and ATHENA_PROXY_URL. I am still getting
[2017-04-04 04:17:51,377: ERROR/MainProcess] Task redash.tasks.execute_query[e754b9e8-9443-4fd5-826c-f40cb70d625e] raised unexpected: AttributeError("'NoneType' object has no attribute 'annotate_query'",)
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/celery/app/trace.py", line 240, in trace_task
code R = retval = fun(args, **kwargs)
File "/app/redash/worker.py", line 68, in call
return TaskBase.call(self,
args, kwargs)
File "/usr/local/lib/python2.7/dist-packages/celery/app/trace.py", line 438, in protected_call
return self.run(*args,
kwargs)
File "/app/redash/tasks/queries.py", line 496, in execute_query
scheduled_query).run()
File "/app/redash/tasks/queries.py", line 418, in run
annotated_query = self._annotate_query(query_runner)
File "/app/redash/tasks/queries.py", line 459, in _annotate_query
if query_runner.annotate_query():
AttributeError: 'NoneType' object has no attribute 'annotate_query'
I restarted the worker container as well as tried to manually start the celery process using
code exec /usr/local/bin/celery worker --app=redash.worker --beat -c1 -Qqueries,scheduled_queries,celery -linfo --maxtasksperchild=10 -Ofair
any help with be very appreciated! thanks @arikfr .
Matt Ryall
@mryall_twitter
Apr 04 2017 06:24
I'm looking for the best place to report a suggestion for Redash. Plotly has recently fixed an issues where stacked charts with negative numbers can be properly shown with barmode: 'relative' (instead of 'stacked'). I'd like to get this supported in Redash
here's the Plotly ticket: plotly/plotly.js#475
Rotem Hermon
@rore
Apr 04 2017 06:30
question regarding Elasticsearch - I'm doing a simple aggregation aggregation by timestamp :
{
    "index": "eu1-trace-*",
    "query": {
        "match_all": {}
    },
    "aggregations": {
        "day": {
            "date_histogram": {
                "field": "@timestamp",
                "interval": "day",
                "format": "yyyy-MM-dd"
            }
        }
    }
}
the response from Elasticsearch returns the count of documents per each bucket (day). But the query result in redash shows only the day column, and no count column. Is there something you need to configure for redash to parse the result correctly?
Arik Fraimovich
@arikfr
Apr 04 2017 06:47
@Debyani you need to recreate the container for the env changes to take effect.

@mryall_twitter here or the forum are good places. if it's a bug, github issues is also good.

specially about the plotly thing -- there's an open pull request to upgrade Plotly, and now that we released a stable version I'm going to merge it. so next release will have newer plotly version.

@rore strange. did you log how the response from ES looks like?
Rotem Hermon
@rore
Apr 04 2017 06:50
@arikfr the response from ES looks like this (this is the aggregation part):
 "aggregations": {
    "day": {
      "buckets": [
        {
          "key_as_string": "2017-03-05",
          "key": 1488672000000,
          "doc_count": 285858615
        },
        {
          "key_as_string": "2017-03-06",
          "key": 1488758400000,
          "doc_count": 328244112
        },
        { ...
Capture.JPG
the result in redash:
Arik Fraimovich
@arikfr
Apr 04 2017 07:18
There is some unclear logic around this in the parser. Can you send the full response and the mapping response, so I can debug it?
Gurbir Singh
@logicerp1993_twitter
Apr 04 2017 07:37
Error running query: database error: not authorized for query on
My database based authentication successfully working.
Sandeep Sreenath
@ssandeep
Apr 04 2017 09:57
@logicerp1993_twitter have you granted required permissions?
have you setup redash from root user?
I have setup redash from a non-root user
and I am having trouble connecting the to db
I keep getting this error:
ProgrammingError: (psycopg2.ProgrammingError) permission denied for relation organizations
how do I configure which postgres user redash has to use?
where can I find the config file for this?
Gurbir Singh
@logicerp1993_twitter
Apr 04 2017 11:05
@ssandeep I am using Mlab mongodb database
so my database on Mlab
たけしー
@takeshi_ok_desu_twitter
Apr 04 2017 11:34
hi!
Thank you very cool Product

I want to host re: dash on the URL http://example.com/redash, is it possible?

Re: dash only accepts the root path?

Location / redash { Proxy_pass http: // redash: 5000; }

Gurbir Singh
@logicerp1993_twitter
Apr 04 2017 12:39
@arikfr I am using Mlab for mongodb database. I have successfully added datasource and when click on test connection and get result success. But the problem is when i run the Query then i am getting "Error running query: database error: not authorized for query on [databasename.Collectionname]"
Sandeep Sreenath
@ssandeep
Apr 04 2017 12:48
@logicerp1993_twitter seems like the user you have specified doesn't have required authorization to run queries?
*the mongo db user
Gurbir Singh
@logicerp1993_twitter
Apr 04 2017 13:29
@ssandeep can you share connection sample . username:password@123466.mlab.com : port
I am using above
But getting some error
Debyani
@Debyani
Apr 04 2017 13:30
@arikfr : I assume you mean restart the container. thats what I did. both the server and the worker, after I added a new data source of type Athena.
Gurbir Singh
@logicerp1993_twitter
Apr 04 2017 13:31
Reserved characters such as ':' must be escaped according RFC 2396. An IPv6 address literal must be enclosed in '[' and ']' according to RFC 2732.
Debyani
@Debyani
Apr 04 2017 21:06
@arikfr : nevermind- my proxy server was running on a container and i didnt link it properly to the worker. Athena's working now. Neat add-on
たけしー
@takeshi_ok_desu_twitter
Apr 04 2017 23:51
@deecay Thanks!