{"action":"created","issue":{"url":"https://api.github.com/repos/rust-lang-nursery/rust-clippy/issues/2882","repository_url":"https://api.github.com/repos/rust-lang-nursery/rust-clippy","labels_url":"https://api.github.com/repos/rust-lang-nursery/rust-clippy/issues/2882/labels{/name}","comments_url":"https://api.github.com/repos/rust-lang-nursery/rust-clippy/issues/2882/comments","events_url":"https://api.github.com/repos/rust-lang-nursery/rust-clippy/issues/2882/events","html_url":"https://github.com/rust-lang-nursery/rust-clippy/issues/2882","id":336926787,"node_id":"MDU6SXNzdWUzMzY5MjY3ODc=","number":2882,"title":"Clippy Python scripts portablility","user":{"login":"mati865","id":1174646,"node_id":"MDQ6VXNlcjExNzQ2NDY=","avatar_url":"https://avatars2.githubusercontent.com/u/1174646?v=4","gravatar_id":"","url":"https://api.github.com/users/mati865","html_url":"https://github.com/mati865","followers_url":"https://api.github.com/users/mati865/followers","following_url":"https://api.github.com/users/mati865/following{/other_user}","gists_url":"https://api.github.com/users/mati865/gists{/gist_id}","starred_url":"https://api.github.com/users/mati865/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mati865/subscriptions","organizations_url":"https://api.github.com/users/mati865/orgs","repos_url":"https://api.github.com/users/mati865/repos","events_url":"https://api.github.com/users/mati865/events{/privacy}","received_events_url":"https://api.github.com/users/mati865/received_events","type":"User","site_admin":false},"labels":[{"id":889597791,"node_id":"MDU6TGFiZWw4ODk1OTc3OTE=","url":"https://api.github.com/repos/rust-lang-nursery/rust-clippy/labels/help-wanted","name":"help-wanted","color":"0e8a16","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":10,"created_at":"2018-06-29T09:23:08Z","updated_at":"2018-07-22T09:11:59Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"<!--\r\nHi there! Whether you've come to make a suggestion for a new lint, an improvement to an existing lint or to report a bug or a false positive in Clippy, you've come to the right place.\r\n\r\nIf you want to report that Clippy does not compile, please be sure to be using the *latest version* of *Rust nightly*! Compiler plugins are highly unstable and will only work with a nightly Rust for now. If you are but still have a problem, please let us now!\r\n\r\nThank you for using Clippy!\r\n\r\nWrite your comment below this line: -->\r\nCurrently all Python scripts in this repository use shebang `#!/usr/bin/env python`.\r\n\r\n### The problem\r\nThis is bad because `python` means default system Python which is Python 3 for Arch and scripts don't work.\r\nOther distributions are going to follow it sooner or later because Python 2 won't be maintained since 2020, for an example: [Fedora proposal](https://fedoraproject.org/wiki/FinalizingFedoraSwitchtoPython3). Also many distributions like Ubuntu, OpenSUSE, Fedora want to ship only with Python 3 preinstalled.\r\n\r\n### Behaviour on different platforms\r\nI've checked many Linux distributions and all of them had `python2`, `python2.7`, `python3`, `python3.X` (X differs based on the version).\r\nAll I know about OSX is it doesn't have `python2` but has `python2.7`, it would be great if somebody could reply with list of all variants.\r\nMSYS2 (aka windows-gnu) does it just like Linux, no idea about windows-msvc (does `#!/usr/bin/env` even work there?).\r\n\r\n### Possible solutions\r\n1. Use `#!/usr/bin/env python2`; probably would work everywhere (sometimes it's not installed but available in repo) but note that, Python 2 is almost dead already.\r\n2. Port scrips to Python 3; I have no idea about OSX and MSVC, should work everywhere else.\r\n3. **RIIR; everything will work on every supported platform, it's win-win but takes more effort.**\r\n\r\ncc `no idea`"},"comment":{"url":"https://api.github.com/repos/rust-lang-nursery/rust-clippy/issues/comments/406852017","html_url":"https://github.com/rust-lang-nursery/rust-clippy/issues/2882#issuecomment-406852017","issue_url":"https://api.github.com/repos/rust-lang-nursery/rust-clippy/issues/2882","id":406852017,"node_id":"MDEyOklzc3VlQ29tbWVudDQwNjg1MjAxNw==","user":{"login":"llogiq","id":4200835,"node_id":"MDQ6VXNlcjQyMDA4MzU=","avatar_url":"https://avatars1.githubusercontent.com/u/4200835?v=4","gravatar_id":"","url":"https://api.github.com/users/llogiq","html_url":"https://github.com/llogiq","followers_url":"https://api.github.com/users/llogiq/followers","following_url":"https://api.github.com/users/llogiq/following{/other_user}","gists_url":"https://api.github.com/users/llogiq/gists{/gist_id}","starred_url":"https://api.github.com/users/llogiq/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/llogiq/subscriptions","organizations_url":"https://api.github.com/users/llogiq/orgs","repos_url":"https://api.github.com/users/llogiq/repos","events_url":"https://api.github.com/users/llogiq/events{/privacy}","received_events_url":"https://api.github.com/users/llogiq/received_events","type":"User","site_admin":false},"created_at":"2018-07-22T09:11:58Z","updated_at":"2018-07-22T09:11:58Z","author_association":"COLLABORATOR","body":"No, just `str::split` and friends. But using `regex` is fine, too."}}
{"actor":{"display_login":"llogiq"}}