Title: disallow __new__, __init__ by youknowone · Pull Request #6446 · RustPython/RustPython · GitHub
Open Graph Title: disallow __new__, __init__ by youknowone · Pull Request #6446 · RustPython/RustPython
X Title: disallow __new__, __init__ by youknowone · Pull Request #6446 · RustPython/RustPython
Description: There are currently some code paths that use __new__ and __init__ directly instead of going through the Constructor/Initializer. I plan to change these so that they raise an error. Before doing that, we’ll need to remove any code that actually relies on this behavior. close #6448 Summary by CodeRabbit Refactor Centralized and reworked object and exception initialization to a trait-based initializer/constructor system. Many built-ins and exceptions now use the new initialization pathway (no visible behavior change; construction semantics preserved). Some previous public init implementations were removed and replaced by the new initializer-based flow (e.g., Cursor), preserving external behavior. ✏️ Tip: You can customize this high-level summary in your review settings.
Open Graph Description: There are currently some code paths that use __new__ and __init__ directly instead of going through the Constructor/Initializer. I plan to change these so that they raise an error. Before doing tha...
X Description: There are currently some code paths that use __new__ and __init__ directly instead of going through the Constructor/Initializer. I plan to change these so that they raise an error. Before doing tha...
Opengraph URL: https://github.com/RustPython/RustPython/pull/6446
X: @github
Domain: github.com
| route-pattern | /:user_id/:repository/pull/:id/checks(.:format) |
| route-controller | pull_requests |
| route-action | checks |
| fetch-nonce | v2:50b1fd79-238d-b164-9de7-c4ba3a1647d2 |
| current-catalog-service-hash | 87dc3bc62d9b466312751bfd5f889726f4f1337bdff4e8be7da7c93d6c00a25a |
| request-id | A1E4:12343F:B628F1:F6BA02:696ABD06 |
| html-safe-nonce | 2f0d30d004290632f772b3f1e62aba7387da14e8741416ad2bc8346e2a22d989 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBMUU0OjEyMzQzRjpCNjI4RjE6RjZCQTAyOjY5NkFCRDA2IiwidmlzaXRvcl9pZCI6IjMxNTAzMDc1NTM1OTc2MzU4NDYiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | fb15e1e24dff6b39d0429a1a8fb04c8edc01445a9dc634c03e1faa4d2d01727a |
| hovercard-subject-tag | pull_request:3105007513 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,checks,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/RustPython/RustPython/pull/6446/checks |
| twitter:image | https://avatars.githubusercontent.com/u/69878?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/69878?s=400&v=4 |
| og:image:alt | There are currently some code paths that use __new__ and __init__ directly instead of going through the Constructor/Initializer. I plan to change these so that they raise an error. Before doing tha... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 46ce962e0e18113ea447391b6ace8b02d4d2861e57b4fbab3658698f73d8855b |
| turbo-cache-control | no-cache |
| go-import | github.com/RustPython/RustPython git https://github.com/RustPython/RustPython.git |
| octolytics-dimension-user_id | 39710557 |
| octolytics-dimension-user_login | RustPython |
| octolytics-dimension-repository_id | 135201145 |
| octolytics-dimension-repository_nwo | RustPython/RustPython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 135201145 |
| octolytics-dimension-repository_network_root_nwo | RustPython/RustPython |
| turbo-body-classes | logged-out env-production page-responsive full-width full-width-p-0 |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 30300f30bb3949de255e84a146706a3bdb5c19c9 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width