Skip to content

Support for *non* proxy sites #10

@hamhands

Description

@hamhands

We are not running proxies and agsview has been returning an internal server error for the services we're working with. Logs below:

[Thu Aug 17 17:46:37.620186 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] data-module-path="{{ h.with_proxy(resource_view.get('ags_url') or resource.url) }}"
[Thu Aug 17 17:46:37.620188 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] File '/usr/lib/ckan/default/src/ckanext-agsview/ckanext/agsview/plugin.py', line 31 in w$
[Thu Aug 17 17:46:37.620190 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] proxies = json.loads(ags_view_proxy())
[Thu Aug 17 17:46:37.620192 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] File '/usr/lib/python2.7/json/init.py', line 338 in loads
[Thu Aug 17 17:46:37.620194 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] return _default_decoder.decode(s)
[Thu Aug 17 17:46:37.620195 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] File '/usr/lib/python2.7/json/decoder.py', line 366 in decode
[Thu Aug 17 17:46:37.620197 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] obj, end = self.raw_decode(s, idx=_w(s, 0).end())
[Thu Aug 17 17:46:37.620199 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] File '/usr/lib/python2.7/json/decoder.py', line 385 in raw_decode
[Thu Aug 17 17:46:37.620201 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] raise ValueError("No JSON object could be decoded")
[Thu Aug 17 17:46:37.620203 2017] [:error] [pid 17045:tid 140527971874560] [remote 127.0.0.1:42818] ValueError: No JSON object could be decoded

Rolled back to ac26b9e and now the plugin works. Are proxies required or is this a bug?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions