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

Inconsistency between .summary() and .name() #2927

Closed
duncanwp opened this issue Dec 19, 2017 · 1 comment
Closed

Inconsistency between .summary() and .name() #2927

duncanwp opened this issue Dec 19, 2017 · 1 comment

Comments

@duncanwp
Copy link
Contributor

For Cubes with no identifier other than a stash code the Cube.summary() method will fall back on printing the STASH attribute, if it's present. I would suggest this is done in the CFVariableMixin.name() method instead so that this logic is consistent used more widely. I'm happy to put together a pull request if this would be useful.

duncanwp added a commit to duncanwp/cis_plugins that referenced this issue Dec 19, 2017
@pelson
Copy link
Member

pelson commented Jan 3, 2018

Sounds good to me. The relevant line is https://github.com/SciTools/iris/blob/master/lib/iris/_cube_coord_common.py#L96:

return self.standard_name or self.long_name or self.var_name or default

There is nothing CF-like about the .name() method, so let's make it a little more useful for UM data. 👍

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

No branches or pull requests

3 participants