Skip to content

removing name argument from tools #9966

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

Draft
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

fariza
Copy link
Member

@fariza fariza commented Dec 10, 2017

PR Summary

Remove name from tools.
This is part of the work on #9941

PR Checklist

  • Has Pytest style unit tests
  • Code is PEP 8 compliant
  • New features are documented, with examples if plot related
  • Documentation is sphinx and numpydoc compliant
  • Added an entry to doc/users/next_whats_new/ if major new feature (follow instructions in README.rst there)
  • Documented in doc/api/api_changes.rst if API changed in a backward-incompatible way

@fariza fariza mentioned this pull request Dec 10, 2017
6 tasks
@OceanWolf
Copy link
Member

Have you tested this @fariza? As far as I can see the code will fail.

@fariza
Copy link
Member Author

fariza commented Dec 10, 2017 via email

@OceanWolf
Copy link
Member

Ahh sorry, my mistake, I missed something. However you need to change the docstring of ToolContainerBase.add_tool.

@fariza
Copy link
Member Author

fariza commented Dec 11, 2017

Done

@fariza fariza requested review from OceanWolf and anntzer December 11, 2017 14:01
@fariza
Copy link
Member Author

fariza commented Dec 13, 2017

@OceanWolf @anntzer can you help merge?

self.data = data


class ToolTriggerEvent(ToolEvent):
"""Event to inform that a tool has been triggered"""
def __init__(self, name, sender, tool, canvasevent=None, data=None):
ToolEvent.__init__(self, name, sender, tool, data)
def __init__(self, name, sender, tool, tool_name, canvasevent=None, data=None):
Copy link
Member

Choose a reason for hiding this comment

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

This line fails PEP8 I think

Copy link
Member

Choose a reason for hiding this comment

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

It does, you just have to look at the Travis build that failed because of this PEP8 error. What's the point in having Travis if we don't use it.

Copy link
Member

Choose a reason for hiding this comment

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

Don't worry! I used Travis. I just wasn't 100% sure I'd remembered the line right, was too lazy to go back and check it, and was 99.9% sure @fariza could manage to figure it out.

Copy link
Member

Choose a reason for hiding this comment

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

Ahh, okay. I over reacted a bit though, I got an email to say that this PR had been approved, and I mistook that to mean it had been merged. I haven't got used to this new review system yet...

Copy link
Member

Choose a reason for hiding this comment

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

No problem! I didn't approve it - I don't really understand it.

@fariza
Copy link
Member Author

fariza commented Dec 14, 2017

Any other comments?

tool : tool_like
The tool to add, see `ToolManager.get_tool`.
tool_name : str
Name of the the tool to add, see `ToolManager.get_tool`.
Copy link
Member

Choose a reason for hiding this comment

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

Double 'the'

@fariza
Copy link
Member Author

fariza commented Dec 15, 2017

@QuLogic docstring corrected

@fariza
Copy link
Member Author

fariza commented Dec 21, 2017

@OceanWolf can you help merge this?

@fariza
Copy link
Member Author

fariza commented Jan 4, 2018

bump

@fariza fariza mentioned this pull request Jan 4, 2018
6 tasks
@jklymak jklymak added this to the v3.0 milestone Mar 16, 2018
@jklymak jklymak modified the milestones: v3.0, v3.1 Jul 9, 2018
"""
Adds a tool to this container

Parameters
----------
tool : tool_like
The tool to add, see `ToolManager.get_tool`.
tool_name : str
Copy link
Member

Choose a reason for hiding this comment

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

This is an API change, isn't it?

Copy link
Member

Choose a reason for hiding this comment

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

As are the added args below? Not sure if they are a problem, but prob needs an Api change note

@jklymak jklymak modified the milestones: v3.1.0, v3.2.0 Feb 25, 2019
@tacaswell tacaswell modified the milestones: v3.2.0, v3.3.0 Aug 19, 2019
@QuLogic QuLogic modified the milestones: v3.3.0, v3.4.0 Apr 30, 2020
@jklymak
Copy link
Member

jklymak commented Jul 15, 2020

@fariza f you have the stomach for a rebase I'll merge this on the merits of @anntzer's review. I don't think @OceanWolf will get a chance to review this...

@jklymak jklymak removed the request for review from OceanWolf July 15, 2020 23:00
@fariza
Copy link
Member Author

fariza commented Jul 16, 2020

@jklymak I will give it a try. If I find it too hard, would you be willing to accept a new one with the same functionality?

@jklymak
Copy link
Member

jklymak commented Jul 16, 2020

@fariza Whatever works best for you.

At some point we need to return to these MEPs and see if they are something that is really wanted. MEP 27 is actually a huge deal, and at the very least @anntzer was skeptical. I'm ignorantly skeptical because I don't understand what problems these are trying to solve and whether they are worth the maintenance burden. We are at the beginning of 3.4, and its not foolish to consider 3.5 or 4.0, so if there is still enthusiasm for these ideas it is a reasonable time to agitate.

I'm going to add MEP 27 and 22 to this weeks dev call. You are more than welcome to join if you like. I think a lot of enthusiasm and effort went into these and in my opinion you (and @OceanWolf) deserve some finality on whether this should still go ahead.

@fariza
Copy link
Member Author

fariza commented Jul 16, 2020

@jklymak sure, I'll like to join this weeks dev call

@OceanWolf
Copy link
Member

@fariza Judging from the code changed with this PR I can't imagine a rebase exists as that difficult as the PR mostly touches the new files we created.

@fariza fariza force-pushed the remove-name-tools branch from 097c9ab to ef686fc Compare July 17, 2020 02:56
@fariza
Copy link
Member Author

fariza commented Jul 17, 2020

@jklymak I did the rebase, wasn't as hard and painful as I imagined (you were right @OceanWolf )
If you want, wait until the call to decide if we merge it or not

@jklymak
Copy link
Member

jklymak commented Jul 17, 2020

The docs need to build, and I still think this needs an API note?

@fariza
Copy link
Member Author

fariza commented Jul 17, 2020

@jklymak added the api change notes. (not sure it's the format or wording that we use for that)

@jklymak jklymak marked this pull request as draft August 24, 2020 14:19
@QuLogic QuLogic modified the milestones: v3.4.0, v3.5.0 Jan 21, 2021
@QuLogic QuLogic modified the milestones: v3.5.0, v3.6.0 Aug 18, 2021
@timhoffm timhoffm modified the milestones: v3.6.0, unassigned Apr 30, 2022
@story645 story645 modified the milestones: unassigned, needs sorting Oct 6, 2022
@github-actions
Copy link

Since this Pull Request has not been updated in 60 days, it has been marked "inactive." This does not mean that it will be closed, though it may be moved to a "Draft" state. This helps maintainers prioritize their reviewing efforts. You can pick the PR back up anytime - please ping us if you need a review or guidance to move the PR forward! If you do not plan on continuing the work, please let us know so that we can either find someone to take the PR over, or close it.

@github-actions github-actions bot added the status: inactive Marked by the “Stale” Github Action label Apr 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: inactive Marked by the “Stale” Github Action status: needs rebase topic: toolbar
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants