Skip to content

Allow non-standard params on WmsTileLayer #420

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

Closed

Conversation

bielfrontera
Copy link

I've tried to add a WMS layer with some non-standard params, but it failed because WmsTileLayer got an unexpected keyword argument.

I propose to pass any other kwarg as an option of the WMS layer that is created by folium.

{% if this.attribution %} attribution: '{{this.attribution}}'{% endif %}
version: '{{ this.version }}'
{% if this.attribution %}, attribution: '{{this.attribution}}'{% endif %}
{% for param in this.extra_params %}, {{param.0}}: '{{param.1}}'{% endfor %}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bielfrontera thanks for the PR!

I wonder if you should be explicit here about the extra parameter instead of looping over the kwargs. What do you think @BibMartin?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some of the extra parameters are those included in ncWMS.

But at SOCIB we have extended that library with parameters as markerscale and markerspacing.

Copy link
Member

@ocefpaf ocefpaf Apr 28, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bielfrontera I am 👍 to all that. I am just concerned if we should be explicit here, by naming every option, instead of looping over the kwargs.

Copy link
Member

@ocefpaf ocefpaf Aug 24, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@bielfrontera where do you stand on adding those parameters explicitly instead of looping over them? We also need to update the docs to describe them. At least the most important subset you expect to use frequently.

@ocefpaf
Copy link
Member

ocefpaf commented Aug 19, 2016

@bielfrontera do you mind rebasing this so we can merge it?

@bielfrontera
Copy link
Author

Hi @ocefpaf , rebase done!

@ocefpaf
Copy link
Member

ocefpaf commented Aug 24, 2016

Hi @ocefpaf , rebase done!

Thanks!

@ocefpaf ocefpaf added this to the v0.4.0 milestone Mar 6, 2017
@ocefpaf
Copy link
Member

ocefpaf commented Aug 26, 2017

@bielfrontera I have to apologize but this PR feel under the cracks and I merged #644 which is quite similar. Closing this but we can work out the details to get the same functionalities you expected from this one.

@ocefpaf ocefpaf closed this Aug 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants