{"action":"created","issue":{"url":"https://api.github.com/repos/nortikin/sverchok/issues/839","repository_url":"https://api.github.com/repos/nortikin/sverchok","labels_url":"https://api.github.com/repos/nortikin/sverchok/issues/839/labels{/name}","comments_url":"https://api.github.com/repos/nortikin/sverchok/issues/839/comments","events_url":"https://api.github.com/repos/nortikin/sverchok/issues/839/events","html_url":"https://github.com/nortikin/sverchok/issues/839","id":173610313,"number":839,"title":"ScriptNode MK3","user":{"login":"zeffii","id":619340,"avatar_url":"https://avatars.githubusercontent.com/u/619340?v=3","gravatar_id":"","url":"https://api.github.com/users/zeffii","html_url":"https://github.com/zeffii","followers_url":"https://api.github.com/users/zeffii/followers","following_url":"https://api.github.com/users/zeffii/following{/other_user}","gists_url":"https://api.github.com/users/zeffii/gists{/gist_id}","starred_url":"https://api.github.com/users/zeffii/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zeffii/subscriptions","organizations_url":"https://api.github.com/users/zeffii/orgs","repos_url":"https://api.github.com/users/zeffii/repos","events_url":"https://api.github.com/users/zeffii/events{/privacy}","received_events_url":"https://api.github.com/users/zeffii/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":{"login":"ly29","id":6241382,"avatar_url":"https://avatars.githubusercontent.com/u/6241382?v=3","gravatar_id":"","url":"https://api.github.com/users/ly29","html_url":"https://github.com/ly29","followers_url":"https://api.github.com/users/ly29/followers","following_url":"https://api.github.com/users/ly29/following{/other_user}","gists_url":"https://api.github.com/users/ly29/gists{/gist_id}","starred_url":"https://api.github.com/users/ly29/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ly29/subscriptions","organizations_url":"https://api.github.com/users/ly29/orgs","repos_url":"https://api.github.com/users/ly29/repos","events_url":"https://api.github.com/users/ly29/events{/privacy}","received_events_url":"https://api.github.com/users/ly29/received_events","type":"User","site_admin":false},"assignees":[{"login":"ly29","id":6241382,"avatar_url":"https://avatars.githubusercontent.com/u/6241382?v=3","gravatar_id":"","url":"https://api.github.com/users/ly29","html_url":"https://github.com/ly29","followers_url":"https://api.github.com/users/ly29/followers","following_url":"https://api.github.com/users/ly29/following{/other_user}","gists_url":"https://api.github.com/users/ly29/gists{/gist_id}","starred_url":"https://api.github.com/users/ly29/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ly29/subscriptions","organizations_url":"https://api.github.com/users/ly29/orgs","repos_url":"https://api.github.com/users/ly29/repos","events_url":"https://api.github.com/users/ly29/events{/privacy}","received_events_url":"https://api.github.com/users/ly29/received_events","type":"User","site_admin":false}],"milestone":null,"comments":63,"created_at":"2016-08-27T18:59:46Z","updated_at":"2016-09-01T15:30:19Z","closed_at":null,"body":"We learnt a lot from MK1, MK2, iojson and Monads, i'm tempted to think about the interface for ScriptNode MK3, and features. For all intents and purposes it should be a way to define a full-on first-class node, but without some of the boilerplate that gets in the way of experimentation/prototyping.\r\n\r\n- optional override of `self.draw()`\r\n- define non socket properties (bools, enums, whatever..)\r\n- define operators / callbacks / button actions\r\n- define softmin/softmax/defaults/etc for properties / sockets\r\n\r\nIdeally i'd like it to provide a simple MK1 like interface, or MK2 (whatever the preference) , but I'll focus on MK1-simulacra perhaps @ly29 will provide MK2-simulacra or introduce redux concepts like type annotations? we can have various loaders which share common functions.\r\n\r\nmaybe a nice mix is possible. \r\n"},"comment":{"url":"https://api.github.com/repos/nortikin/sverchok/issues/comments/244116809","html_url":"https://github.com/nortikin/sverchok/issues/839#issuecomment-244116809","issue_url":"https://api.github.com/repos/nortikin/sverchok/issues/839","id":244116809,"user":{"login":"zeffii","id":619340,"avatar_url":"https://avatars.githubusercontent.com/u/619340?v=3","gravatar_id":"","url":"https://api.github.com/users/zeffii","html_url":"https://github.com/zeffii","followers_url":"https://api.github.com/users/zeffii/followers","following_url":"https://api.github.com/users/zeffii/following{/other_user}","gists_url":"https://api.github.com/users/zeffii/gists{/gist_id}","starred_url":"https://api.github.com/users/zeffii/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zeffii/subscriptions","organizations_url":"https://api.github.com/users/zeffii/orgs","repos_url":"https://api.github.com/users/zeffii/repos","events_url":"https://api.github.com/users/zeffii/events{/privacy}","received_events_url":"https://api.github.com/users/zeffii/received_events","type":"User","site_admin":false},"created_at":"2016-09-01T15:30:19Z","updated_at":"2016-09-01T15:30:19Z","body":"```python\r\nfrom collections import OrderedDict\r\nhide = 'Hidden'\r\n\r\nclass uInt:\r\n    def __init__(self, *args, **kw):\r\n        ...\r\n\r\nclass Float:\r\n    def __init__(self, *args, **kw):\r\n        ...\r\n\r\nclass Bool:\r\n    def __init__(self, *args, **kw):\r\n        ...\r\n\r\n\r\nclass SN_dict:\r\n\r\n    def __init__(self):\r\n        self.__dict__ = OrderedDict()\r\n\r\n    def __setattr__(self, key, val):\r\n        self.__dict__[key] = val\r\n\r\n    def __getattr__(self, key):\r\n        return self.__dict__[key]\r\n    \r\n    def keys(self):\r\n        return self.__dict__.keys()\r\n\r\n    def value(self):\r\n        return self.__dict__.values()\r\n\r\n    def items(self):\r\n        return zip(self.__dict__.keys(), self.__dict__.values())\r\n\r\n\r\ni = SN_dict()\r\ni.n_petals = uInt(\"Nm petals\", 8)\r\ni.vp_petal = uInt(\"herts per Petal\", 20)\r\ni.profile_radius = Float('Profile Radius', 1.3)\r\ni.amp = Float(\"Amp\", 1.0)\r\ni.some_bool = Bool(\"Switch me\", True), hide   # for use with `def draw()`\r\n\r\n\r\nprint(i.__dict__.items())\r\n```\r\n\r\nbut have seen smarter people (I assume they're smarter) take much more verbose approaches:\r\nhttp://stackoverflow.com/a/14048352/1243487"}}
{"actor":{"display_login":"zeffii"}}