[GeoNode-users] Layers are not shown in maps' preview for not-registered users

Chiara Sammarco chiara.sammarco at geodatalab.it
Wed Dec 11 08:37:06 PST 2019


Hi guys,
I'm writing again for user permissions on layers' view.

Desired behavior: I want that all the users to be able to see the layers in
the maps' preview, also those which did not register and did not log in yet.

Actual Behavior: If I clear the cache of my browser and try to access my
geonode installation, I cannot see any layers on the Map's Detail page.
If I log in and then log out, I can see them. BUT I want all the people to
see the maps' preview in the map's detail pages.

Other Details:
- in the layers' permission is set that " all the user are able to see this
layer"

>From the output I noticed the following errors:

> Internal Server Error: /maps/version.txt
> django_1 | Traceback (most recent call last):
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/core/handlers/exception.py",
> line 41, in inner
> django_1 | response = get_response(request)
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/core/handlers/base.py",
> line 249, in _*legacy*_get_response
> django_1 | response = self._get_response(request)
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/core/handlers/base.py",
> line 187, in _*get*_response
> django_1 | response = self.process_exception_by_middleware(e, request)
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/core/handlers/base.py",
> line 185, in _*get*_response
> django_1 | response = wrapped_callback(request, **callback_args, **
> callback_kwargs)
> django_1 | File "./geonode/maps/views.py", line 126, in map_detail
> django_1 | _*PERMISSION*_MSG_VIEW)
> django_1 | File "./geonode/maps/views.py", line 114, in _*resolve*_map
> django_1 | permission_msg=msg, **kwargs)
> django_1 | File "./geonode/utils.py", line 820, in resolve_object
> django_1 | obj = get_object_or_404(model, **query)
> django_1 | File "/usr/local/lib/python2.7/site-packages/django/
> shortcuts.py", line 85, in get_object_or_404
> django_1 | return queryset.get(**args, **kwargs)
> django_1 | File "/usr/local/lib/python2.7/site-packages/django/db/models/
> query.py", line 371, in get
> django_1 | clone = self.filter(**args, **kwargs)
> django_1 | File "/usr/local/lib/python2.7/site-packages/django/db/models/
> query.py", line 787, in filter
> django_1 | return self._filter_or_exclude(False, **args, **kwargs)
> django_1 | File "/usr/local/lib/python2.7/site-packages/polymorphic/
> query.py", line 173, in _*filter*_or_exclude
> django_1 | negate, **(list(q_objects) + additional_args), **kwargs
> django_1 | File "/usr/local/lib/python2.7/site-packages/modeltranslation/
> manager.py", line 307, in _*filter*_or_exclude
> django_1 | return super(MultilingualQuerySet,
> self)._filter_or_exclude(negate, **args, **kwargs)
> django_1 | File "/usr/local/lib/python2.7/site-packages/django/db/models/
> query.py", line 805, in _*filter*_or_exclude
> django_1 | clone.query.add_q(Q(**args, **kwargs))
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/db/models/sql/query.py",
> line 1250, in add_q
> django_1 | clause, _* = self.*_add_q(q_object, self.used_aliases)
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/db/models/sql/query.py",
> line 1276, in _*add*_q
> django_1 | allow_joins=allow_joins, split_subq=split_subq,
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/db/models/sql/query.py",
> line 1206, in build_filter
> django_1 | condition = lookup_class(lhs, value)
> django_1 | File "/usr/local/lib/python2.7/site-packages/django/db/models/
> lookups.py", line 24, in _*init*_
> django_1 | self.rhs = self.get_prep_lookup()
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/db/models/fields/related_
> lookups.py", line 112, in get_prep_lookup
> django_1 | self.rhs = target_field.get_prep_value(self.rhs)
> django_1 | File
> "/usr/local/lib/python2.7/site-packages/django/db/models/fields/__init__.py",
> line 966, in get_prep_value
> django_1 | return int(value)
>


Maybe this can help understanding the issue???
Can someone help in troubleshooting?
Thanks in advance,
Chiara
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geonode-users/attachments/20191211/d14e4e7c/attachment-0001.html>


More information about the geonode-users mailing list