{"action":"created","issue":{"url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11117","repository_url":"https://api.github.com/repos/scikit-learn/scikit-learn","labels_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11117/labels{/name}","comments_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11117/comments","events_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11117/events","html_url":"https://github.com/scikit-learn/scikit-learn/issues/11117","id":325387086,"node_id":"MDU6SXNzdWUzMjUzODcwODY=","number":11117,"title":"Common test to check that __init__ doesn't mess with parameters","user":{"login":"amueller","id":449558,"node_id":"MDQ6VXNlcjQ0OTU1OA==","avatar_url":"https://avatars3.githubusercontent.com/u/449558?v=4","gravatar_id":"","url":"https://api.github.com/users/amueller","html_url":"https://github.com/amueller","followers_url":"https://api.github.com/users/amueller/followers","following_url":"https://api.github.com/users/amueller/following{/other_user}","gists_url":"https://api.github.com/users/amueller/gists{/gist_id}","starred_url":"https://api.github.com/users/amueller/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/amueller/subscriptions","organizations_url":"https://api.github.com/users/amueller/orgs","repos_url":"https://api.github.com/users/amueller/repos","events_url":"https://api.github.com/users/amueller/events{/privacy}","received_events_url":"https://api.github.com/users/amueller/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":5,"created_at":"2018-05-22T17:12:48Z","updated_at":"2018-06-13T15:50:21Z","closed_at":null,"author_association":"MEMBER","body":"There's ``check_dont_overwrite_parameters`` which checks that ``fit`` doesn't overwrite ``__init__`` params, and there's ``check_no_attributes_set_in_init`` that checks that only ``__init__`` attributes are set. There is not check that they are actually set to the correct value, so\r\n```python\r\nclass DumbOne(BaseEstimator):\r\n    def __init__(param=0):\r\n        param = 1\r\n```\r\nactually passes the common tests. That's not good imho."},"comment":{"url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/comments/396987897","html_url":"https://github.com/scikit-learn/scikit-learn/issues/11117#issuecomment-396987897","issue_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11117","id":396987897,"node_id":"MDEyOklzc3VlQ29tbWVudDM5Njk4Nzg5Nw==","user":{"login":"glemaitre","id":7454015,"node_id":"MDQ6VXNlcjc0NTQwMTU=","avatar_url":"https://avatars2.githubusercontent.com/u/7454015?v=4","gravatar_id":"","url":"https://api.github.com/users/glemaitre","html_url":"https://github.com/glemaitre","followers_url":"https://api.github.com/users/glemaitre/followers","following_url":"https://api.github.com/users/glemaitre/following{/other_user}","gists_url":"https://api.github.com/users/glemaitre/gists{/gist_id}","starred_url":"https://api.github.com/users/glemaitre/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/glemaitre/subscriptions","organizations_url":"https://api.github.com/users/glemaitre/orgs","repos_url":"https://api.github.com/users/glemaitre/repos","events_url":"https://api.github.com/users/glemaitre/events{/privacy}","received_events_url":"https://api.github.com/users/glemaitre/received_events","type":"User","site_admin":false},"created_at":"2018-06-13T15:50:21Z","updated_at":"2018-06-13T15:50:21Z","author_association":"CONTRIBUTOR","body":"I was checking the 0.20 milestone and step in #7738.\r\n\r\n```python\r\nclass Estimator(BaseEstimator):\r\n    def __init__(self, param=None):\r\n        self._param = param\r\n\r\n    @property\r\n    def param(self):\r\n        return some_stuff(self._param)\r\n```\r\n\r\nWould it passed the tests?"}}
{"actor":{"display_login":"glemaitre"}}