{"action":"created","issue":{"url":"https://api.github.com/repos/stan-dev/stan/issues/2351","repository_url":"https://api.github.com/repos/stan-dev/stan","labels_url":"https://api.github.com/repos/stan-dev/stan/issues/2351/labels{/name}","comments_url":"https://api.github.com/repos/stan-dev/stan/issues/2351/comments","events_url":"https://api.github.com/repos/stan-dev/stan/issues/2351/events","html_url":"https://github.com/stan-dev/stan/issues/2351","id":241541565,"number":2351,"title":"stan::lang::compile should not require access to the filesystem (for #include)","user":{"login":"ariddell","id":19950,"avatar_url":"https://avatars2.githubusercontent.com/u/19950?v=4","gravatar_id":"","url":"https://api.github.com/users/ariddell","html_url":"https://github.com/ariddell","followers_url":"https://api.github.com/users/ariddell/followers","following_url":"https://api.github.com/users/ariddell/following{/other_user}","gists_url":"https://api.github.com/users/ariddell/gists{/gist_id}","starred_url":"https://api.github.com/users/ariddell/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ariddell/subscriptions","organizations_url":"https://api.github.com/users/ariddell/orgs","repos_url":"https://api.github.com/users/ariddell/repos","events_url":"https://api.github.com/users/ariddell/events{/privacy}","received_events_url":"https://api.github.com/users/ariddell/received_events","type":"User","site_admin":false},"labels":[{"id":27472628,"url":"https://api.github.com/repos/stan-dev/stan/labels/feature","name":"feature","color":"84b6eb","default":false},{"id":39670600,"url":"https://api.github.com/repos/stan-dev/stan/labels/language","name":"language","color":"d4c5f9","default":false}],"state":"open","locked":false,"assignee":{"login":"bob-carpenter","id":3383807,"avatar_url":"https://avatars1.githubusercontent.com/u/3383807?v=4","gravatar_id":"","url":"https://api.github.com/users/bob-carpenter","html_url":"https://github.com/bob-carpenter","followers_url":"https://api.github.com/users/bob-carpenter/followers","following_url":"https://api.github.com/users/bob-carpenter/following{/other_user}","gists_url":"https://api.github.com/users/bob-carpenter/gists{/gist_id}","starred_url":"https://api.github.com/users/bob-carpenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bob-carpenter/subscriptions","organizations_url":"https://api.github.com/users/bob-carpenter/orgs","repos_url":"https://api.github.com/users/bob-carpenter/repos","events_url":"https://api.github.com/users/bob-carpenter/events{/privacy}","received_events_url":"https://api.github.com/users/bob-carpenter/received_events","type":"User","site_admin":false},"assignees":[{"login":"bob-carpenter","id":3383807,"avatar_url":"https://avatars1.githubusercontent.com/u/3383807?v=4","gravatar_id":"","url":"https://api.github.com/users/bob-carpenter","html_url":"https://github.com/bob-carpenter","followers_url":"https://api.github.com/users/bob-carpenter/followers","following_url":"https://api.github.com/users/bob-carpenter/following{/other_user}","gists_url":"https://api.github.com/users/bob-carpenter/gists{/gist_id}","starred_url":"https://api.github.com/users/bob-carpenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bob-carpenter/subscriptions","organizations_url":"https://api.github.com/users/bob-carpenter/orgs","repos_url":"https://api.github.com/users/bob-carpenter/repos","events_url":"https://api.github.com/users/bob-carpenter/events{/privacy}","received_events_url":"https://api.github.com/users/bob-carpenter/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/stan-dev/stan/milestones/29","html_url":"https://github.com/stan-dev/stan/milestone/29","labels_url":"https://api.github.com/repos/stan-dev/stan/milestones/29/labels","id":2747006,"number":29,"title":"2.17.1++","description":"","creator":{"login":"seantalts","id":805356,"avatar_url":"https://avatars1.githubusercontent.com/u/805356?v=4","gravatar_id":"","url":"https://api.github.com/users/seantalts","html_url":"https://github.com/seantalts","followers_url":"https://api.github.com/users/seantalts/followers","following_url":"https://api.github.com/users/seantalts/following{/other_user}","gists_url":"https://api.github.com/users/seantalts/gists{/gist_id}","starred_url":"https://api.github.com/users/seantalts/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seantalts/subscriptions","organizations_url":"https://api.github.com/users/seantalts/orgs","repos_url":"https://api.github.com/users/seantalts/repos","events_url":"https://api.github.com/users/seantalts/events{/privacy}","received_events_url":"https://api.github.com/users/seantalts/received_events","type":"User","site_admin":false},"open_issues":29,"closed_issues":10,"state":"open","created_at":"2017-09-06T02:58:43Z","updated_at":"2018-02-16T20:22:06Z","due_on":null,"closed_at":null},"comments":3,"created_at":"2017-07-09T17:57:59Z","updated_at":"2018-02-20T14:09:34Z","closed_at":null,"author_association":"MEMBER","body":"#### Summary:\r\n\r\nstan::lang::compile cannot be used by interfaces which do not have access to the filesystem when the stan program contains ``#include <filename>``.\r\n\r\n\r\n#### Description:\r\n\r\nThere should be a way to use stan::lang::compile with stan code which contains ``#include``s. Naturally all interfaces which do not have a (full) file system available (e.g., httpstan, jupyter notebook) will need this. But having Stan C++ reach into the filesystem breaks the isolation between Stan and the interfaces.\r\n\r\nSeparating out preprocessing and compilation might do the trick. Most compilers follow this strategy, I assume.\r\n\r\nAnother option would be to allow the interface to provide (``<filename>``, ``<contents>``) pairs to stan::lang::compile.\r\n\r\n#### Reproducible Steps:\r\n\r\nCall stan::lang::compile without access to the filesystem.\r\n\r\n#### Current Version:\r\nv2.16.0\r\n\r\nEdit: add another example of a \"filesystem-less\" setup.\r\n"},"comment":{"url":"https://api.github.com/repos/stan-dev/stan/issues/comments/366988330","html_url":"https://github.com/stan-dev/stan/issues/2351#issuecomment-366988330","issue_url":"https://api.github.com/repos/stan-dev/stan/issues/2351","id":366988330,"user":{"login":"bob-carpenter","id":3383807,"avatar_url":"https://avatars1.githubusercontent.com/u/3383807?v=4","gravatar_id":"","url":"https://api.github.com/users/bob-carpenter","html_url":"https://github.com/bob-carpenter","followers_url":"https://api.github.com/users/bob-carpenter/followers","following_url":"https://api.github.com/users/bob-carpenter/following{/other_user}","gists_url":"https://api.github.com/users/bob-carpenter/gists{/gist_id}","starred_url":"https://api.github.com/users/bob-carpenter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bob-carpenter/subscriptions","organizations_url":"https://api.github.com/users/bob-carpenter/orgs","repos_url":"https://api.github.com/users/bob-carpenter/repos","events_url":"https://api.github.com/users/bob-carpenter/events{/privacy}","received_events_url":"https://api.github.com/users/bob-carpenter/received_events","type":"User","site_admin":false},"created_at":"2018-02-20T14:09:34Z","updated_at":"2018-02-20T14:09:34Z","author_association":"CONTRIBUTOR","body":"I'd be surprised if virtual machines or things like Docker containers can't mimic file systems.  \n\nStan doesn't care where the bits come from, just that it can associate a name to content.\n\n> On Feb 20, 2018, at 9:04 AM, Allen Riddell <notifications@github.com> wrote:\n> \n> I still think this is an excellent idea. Stan C++ shouldn't reach into the filesystem because filesystems vary too much by platform. And there are some settings where filesystems don't really exist or cannot be written to (virtual machines, containers, ...).\n> \n> —\n> You are receiving this because you were assigned.\n> Reply to this email directly, view it on GitHub, or mute the thread.\n> \n\n"}}
{"actor":{"display_login":"bob-carpenter"}}