Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot open metadata detail with thesaurus #9861

Closed
mattiagiupponi opened this issue Aug 17, 2022 · 0 comments
Closed

Cannot open metadata detail with thesaurus #9861

mattiagiupponi opened this issue Aug 17, 2022 · 0 comments
Assignees
Labels
4.0.x master minor A low priority issue which might affect only some users and /or not the main functionality regression Issues related to regressions.
Milestone

Comments

@mattiagiupponi
Copy link
Contributor

mattiagiupponi commented Aug 17, 2022

Expected Behavior

Open the metadata editor with some thesaurus installed should work

Actual Behavior

The page raises an issue since the method remove_country_from_languagecode is declared as a static method.
Probably a regression of this issue #9799 since it was introduced here

Internal Server Error: /datasets/geonode_data:geonode:malga_70f2ed645b1b775f20a9a20e875f9dfb/metadata
Traceback (most recent call last):
  File "/home/mattia/.virtualenvs/metamedia/lib/python3.8/site-packages/django/core/handlers/exception.py", line 47, in inner
    response = get_response(request)
  File "/home/mattia/.virtualenvs/metamedia/lib/python3.8/site-packages/django/core/handlers/base.py", line 181, in _get_response
    response = wrapped_callback(request, *callback_args, **callback_kwargs)
  File "/home/mattia/.virtualenvs/metamedia/lib/python3.8/site-packages/django/contrib/auth/decorators.py", line 21, in _wrapped_view
    return view_func(request, *args, **kwargs)
  File "/opt/core/geonode/geonode/decorators.py", line 213, in _inner
    return function(request, *args, **kwargs)
  File "/opt/core/geonode/geonode/layers/views.py", line 590, in dataset_metadata
    tkeywords_form = ThesaurusAvailableForm(prefix='tkeywords')
  File "/opt/core/geonode/geonode/base/forms.py", line 314, in __init__
    self.fields[f"{item.id}"] = self._define_multifield(item, False, tname, lang)
  File "/opt/core/geonode/geonode/base/forms.py", line 330, in _define_multifield
    choices=self._get_thesauro_keyword_label(item, lang),
  File "/opt/core/geonode/geonode/base/forms.py", line 354, in _get_thesauro_keyword_label
    lang = remove_country_from_lanugecode(lang)
TypeError: 'staticmethod' object is not callable

Steps to Reproduce the Problem

  1. Load a thesaurus in geonode
  2. open the metadata editor

Specifications

  • GeoNode version: master, 4.x
  • Installation method (manual, GeoNode Docker, SPCGeoNode Docker): all
  • Platform: all
  • Additional details:

FYI: @mwallschlaeger

@mattiagiupponi mattiagiupponi added regression Issues related to regressions. major A high priority issue which might affect a lot of people or large parts of the codebase master 4.0.x labels Aug 17, 2022
@mattiagiupponi mattiagiupponi added this to the 4.0.1 milestone Aug 17, 2022
@mattiagiupponi mattiagiupponi self-assigned this Aug 17, 2022
@mattiagiupponi mattiagiupponi added minor A low priority issue which might affect only some users and /or not the main functionality and removed major A high priority issue which might affect a lot of people or large parts of the codebase labels Aug 17, 2022
github-actions bot pushed a commit that referenced this issue Aug 24, 2022
…#9864)

* [Fixes #9861]Cannot open metadata detail with thesaurus installed

* [Fixes #9862] Thesaurus label are not available with default language

Co-authored-by: Giovanni Allegri <giohappy@gmail.com>
Co-authored-by: Alessio Fabiani <alessio.fabiani@geosolutionsgroup.com>
afabiani added a commit that referenced this issue Aug 24, 2022
…#9864) (#9904)

* [Fixes #9861]Cannot open metadata detail with thesaurus installed

* [Fixes #9862] Thesaurus label are not available with default language

Co-authored-by: Giovanni Allegri <giohappy@gmail.com>
Co-authored-by: Alessio Fabiani <alessio.fabiani@geosolutionsgroup.com>

Co-authored-by: mattiagiupponi <51856725+mattiagiupponi@users.noreply.github.com>
Co-authored-by: Giovanni Allegri <giohappy@gmail.com>
Co-authored-by: Alessio Fabiani <alessio.fabiani@geosolutionsgroup.com>
afabiani pushed a commit that referenced this issue Aug 26, 2022
…anel (#9840)

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9861]Cannot open metadata detail with thesaurus installed

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] Fix wrong subtype in case of timeserie dataset

* [Fixes #9821] Fix circleci build
github-actions bot pushed a commit that referenced this issue Aug 26, 2022
…anel (#9840)

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9861]Cannot open metadata detail with thesaurus installed

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] Fix wrong subtype in case of timeserie dataset

* [Fixes #9821] Fix circleci build
afabiani pushed a commit that referenced this issue Aug 26, 2022
…anel (#9840) (#9914)

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] add new attribute to time series

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9861]Cannot open metadata detail with thesaurus installed

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] Time serie selection handled by the advanced metadata panel

* [Fixes #9821] Fix wrong subtype in case of timeserie dataset

* [Fixes #9821] Fix circleci build

Co-authored-by: mattiagiupponi <51856725+mattiagiupponi@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4.0.x master minor A low priority issue which might affect only some users and /or not the main functionality regression Issues related to regressions.
Projects
None yet
Development

No branches or pull requests

1 participant