These are chat archives for getredash/redash

10th
Jun 2016
Arik Fraimovich
@arikfr
Jun 10 2016 03:37
@szaddam reinstalling requirements fixed the template not found issue?
Teguh Nugraha
@teguhn_twitter
Jun 10 2016 04:53
Is there any documentation on how to create "Organizations"? Thanks
getredash/redash#724
Antoine Augusti
@AntoineAugusti
Jun 10 2016 07:52
@teguhn_twitter If you go to admin/organization/ I guess you'll be able to do it ;)
szaddam
@szaddam
Jun 10 2016 12:30
@arikfr Yes. The install script stopped with error. It said: this module and that module is missing. I don't know python, so I installed them by hand with pip, but I did not watch the versions. I just installed the most recent versions. This cause the template not found error.
After that I reinstall the dependencies with the txt file and it worked.
Jon Scott
@solutionrooms
Jun 10 2016 13:33

Hi,
New here and new to redash.
Yesterday the http api was working for me just fine.

Now – the api fails (error 500) for any new queries + any new runs of existing queries. (but it still works for old runs!)

The error:

[2016-06-10 13:23:09,667][PID:3913][ERROR][redash] Exception on /api/queries/7/results.json [GET] Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1475, in full_dispatch_request rv = self.dispatch_request() File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1461, in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) File "/usr/local/lib/python2.7/dist-packages/flask_restful/__init__.py", line 477, in wrapper resp = resource(*args, **kwargs) File "/usr/local/lib/python2.7/dist-packages/flask_login.py", line 792, in decorated_view return func(*args, **kwargs) File "/usr/local/lib/python2.7/dist-packages/flask/views.py", line 84, in view return self.dispatch_request(*args, **kwargs) File "/opt/redash/redash.0.10.1.b1834/redash/handlers/base.py", line 25, in dispatch_request return super(BaseResource, self).dispatch_request(*args, **kwargs) File "/usr/local/lib/python2.7/dist-packages/flask_restful/__init__.py", line 587, in dispatch_request resp = meth(*args, **kwargs) File "/opt/redash/redash.0.10.1.b1834/redash/permissions.py", line 40, in decorated return fn(*args, **kwargs) File "/opt/redash/redash.0.10.1.b1834/redash/handlers/query_results.py", line 108, in get if query_result: UnboundLocalError: local variable 'query_result' referenced before assignment

I am on using version 0.10.1+b1836.

Applogies if I have posted this in the wrong place?

Any ideas to try?

Jon.

Jon Scott
@solutionrooms
Jun 10 2016 16:44
OK - re the above ive got it. the error 500 occurs if there are no saved query executions. it looks like you have to press the save button after you execute the query for it to be able to be picked up by the api (perhaps this is only when you use a parameter?). Can anyone confirm that this is the case? should this be changed? if so I will look at doing this if someone can point me in the right direction?
Teguh Nugraha
@teguhn_twitter
Jun 10 2016 17:02
@AntoineAugusti Thanks :+1:
Mike Lopez
@Mikodes
Jun 10 2016 19:02
Hello , does anione work with mongo datasource , how i can create a new Date Object () into query ?? Thx !
Arik Fraimovich
@arikfr
Jun 10 2016 19:37
@IronistM looks like they are using the same library.
@Mikodes you can use Mongo extended JSON (writing from the phone but just Google for this it's documented in Mongo's docs).
Arik Fraimovich
@arikfr
Jun 10 2016 19:43
@solutionrooms the api you were using is intended for retrieving existing resultsresults. But it should still give meaningful message. Can you open an issue for this on GitHub? Thanks
Mike Lopez
@Mikodes
Jun 10 2016 19:59
@arikfr i saw that u can use Mongo extended Json but i cant get current time