psolin / cleanco

Company Name Processor written in Python
MIT License
318 stars 94 forks source link

added parameter 'custom_terms' to function [clean.prepare_terms()]. #59

Closed maxu777 closed 3 years ago

maxu777 commented 3 years ago

added parameter 'custom_terms' to function [clean.prepare_terms()]. So that a user can easily construct terms including those that are missing in the module

petri commented 3 years ago

@maxu777 Thanks for the PR. I've never seen the |= operator used this way for sets. Is the applicability of the operator to sets documented somewhere? If that can be confirmed, I will then merge this before releasing 2.1.

maxu777 commented 3 years ago

Hi, i think it's described very well here: https://stackoverflow.com/questions/3929278/what-does-ior-do-in-python

Best, max

On Sat, 30 Jan 2021 at 11:43, Petri Savolainen notifications@github.com wrote:

@maxu777 https://github.com/maxu777 Thanks for the PR. I've never seen the |= operator used this way for sets. Is the applicability of the operator to sets documented somewhere? If that can be confirmed, I will then merge this before releasing 2.1.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/psolin/cleanco/pull/59#issuecomment-770192114, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACXFJLMFEQPEVRIJRB7X2GDS4PPFXANCNFSM4SLGC7QQ .

petri commented 3 years ago

Thanks @maxu777 ... I was looking for something more authoritative on the operator applicability to sets in particular and lo & behold indeed it exists here: https://docs.python.org/3.8/library/stdtypes.html#set-types-set-frozenset . Will merge.

petri commented 3 years ago

@maxu777 your PR fails on master; I had to revert it. I can take a second look if you'd like to resubmit your PR fixed so it works. Please add a test this time for the new functionality.