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

fix for disable_linting appending without check #699

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

vindolin
Copy link

  1. When running the disable_linting command multiple times, filename or
    window_view gets appended to the
    ANACONDA['DISABLED']/ANACONDA['DISABLED_BUFFERS'] even if it's already
    there.
    The user then has to run the enable_linting command the same number of
    times to enable it again.

  2. is_enabled looked for view.id() instead of (self.window.id(), view.id()).

Also I made the two files look more unified.

Copy link
Owner

@DamnWidget DamnWidget left a comment

Choose a reason for hiding this comment

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

Why not just use a set instead of a list? We will end with the same result but in a much cleaner way.
What do you think?

@vindolin
Copy link
Author

That was my first idea but ANACONDA['DISABLED'] is a PersistentList.

@DamnWidget
Copy link
Owner

Yeah that's true then what do you think of moving it to the PersistentList itself into the append method (just call the append method in the super class if the element is not in the list already) and make 'DISABLED_BUFFERS a set?

@vindolin
Copy link
Author

I look into this when I'm back from a vacation in about a week.

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