{"action":"created","issue":{"url":"https://api.github.com/repos/odoo/odoo/issues/6287","labels_url":"https://api.github.com/repos/odoo/odoo/issues/6287/labels{/name}","comments_url":"https://api.github.com/repos/odoo/odoo/issues/6287/comments","events_url":"https://api.github.com/repos/odoo/odoo/issues/6287/events","html_url":"https://github.com/odoo/odoo/issues/6287","id":68041291,"number":6287,"title":"Proposal: replacing __openerp__.py with __odoo__.yaml","user":{"login":"dreispt","id":1246629,"avatar_url":"https://avatars.githubusercontent.com/u/1246629?v=3","gravatar_id":"","url":"https://api.github.com/users/dreispt","html_url":"https://github.com/dreispt","followers_url":"https://api.github.com/users/dreispt/followers","following_url":"https://api.github.com/users/dreispt/following{/other_user}","gists_url":"https://api.github.com/users/dreispt/gists{/gist_id}","starred_url":"https://api.github.com/users/dreispt/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dreispt/subscriptions","organizations_url":"https://api.github.com/users/dreispt/orgs","repos_url":"https://api.github.com/users/dreispt/repos","events_url":"https://api.github.com/users/dreispt/events{/privacy}","received_events_url":"https://api.github.com/users/dreispt/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":22,"created_at":"2015-04-13T08:29:44Z","updated_at":"2015-04-24T03:40:32Z","closed_at":null,"body":"It's planned to replace the `__openerp__` name for the manifest file with `__odoo__`.\r\nI propose to use that opportunity to also change the type of file from .py to .yaml.\r\n\r\nMy argument is that the manifest is actually data, not code, so it can feel awkward to have it on a code file.\r\nA more pragmatic issue is that [evaluating](https://github.com/odoo/odoo/blob/8.0/openerp/modules/module.py#L251) the `__openerp__.py` file to parse is an important security risk: it's easy to inject trojan code in a module and publish it on the App store.\r\nWith YAML we could use the safer deserialization `yaml.safe_load()`.\r\n\r\nIf I know it would be welcome, I 'm willing to propose a PR for this. (cc @antonylesuisse)"},"comment":{"url":"https://api.github.com/repos/odoo/odoo/issues/comments/95789910","html_url":"https://github.com/odoo/odoo/issues/6287#issuecomment-95789910","issue_url":"https://api.github.com/repos/odoo/odoo/issues/6287","id":95789910,"user":{"login":"vaab","id":703255,"avatar_url":"https://avatars.githubusercontent.com/u/703255?v=3","gravatar_id":"","url":"https://api.github.com/users/vaab","html_url":"https://github.com/vaab","followers_url":"https://api.github.com/users/vaab/followers","following_url":"https://api.github.com/users/vaab/following{/other_user}","gists_url":"https://api.github.com/users/vaab/gists{/gist_id}","starred_url":"https://api.github.com/users/vaab/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vaab/subscriptions","organizations_url":"https://api.github.com/users/vaab/orgs","repos_url":"https://api.github.com/users/vaab/repos","events_url":"https://api.github.com/users/vaab/events{/privacy}","received_events_url":"https://api.github.com/users/vaab/received_events","type":"User","site_admin":false},"created_at":"2015-04-24T03:40:32Z","updated_at":"2015-04-24T03:40:32Z","body":"Ahah, let me add another useless stance: YAML is simple and beautiful and JSON is complex and ugly.\r\n\r\nJust try one second to convert the YAML tests to JSON and you'll understand.\r\n\r\nAnd it's the logical path to simplicity: \r\n- indentation for sub-structure (like python)\r\n- no need of quotes everywhere.\r\n- support of multiline (JSON doesn't)\r\n- terse, very.\r\n\r\nThe size of the spec is mostly for advanced features that can be avoided. If you stay with struct, sequence, and literals... no issues.\r\n\r\nPlease avoid XML.\r\n\r\nAs xmo said, JSON has no value added against python syntatically (in fact, it's worse). The only added advantage with JSON is to open these file to a well known data format with many implementation on any language, which is what they are all about.\r\n\r\nAt last, using JSON while all the tests are in YAM, is adding a third data language.\r\n\r\nAnd using a generic name as ``metadata.yml`` seems wise and prevent the endless renaming of files in the future. (``__terp__.py`` -> ``__openerp__.py`` -> ``__odoo__.py`` -> ... ?)\r\n\r\nVery nice overview of JSON vs Yaml from a former Yaml hater (same rightfull start about specs being so complex)."}}