Skip to content

Can't access self.service_url in ScienceBaseResource._get #2

Description

@nikmolnar

The ._get method of ScienceBase resource needs to access self.service_url in order to correctly generate (or not) an ArcGIS server token:

server_admin = ArcGISSecureResource.generate_token(self.service_url, arcgis_user, arcgis_pass)

However, due to circular resource loading logic, the service_url getter method returns ._url as a default because trying to load ._service_url results in an attribute error.

Likewise, trying to use ._service_url directly in in the ScienceBaseResource._get method causes an AttributeError and resource loading fails.

This issue can be observed in 1589ea8, which contains a shim to work around it. Without the extra call to self.service_url, it will end up using ._url to try generate an ArcGIS server token.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions