{"action":"created","issue":{"url":"https://api.github.com/repos/mikey179/vfsStream/issues/113","labels_url":"https://api.github.com/repos/mikey179/vfsStream/issues/113/labels{/name}","comments_url":"https://api.github.com/repos/mikey179/vfsStream/issues/113/comments","events_url":"https://api.github.com/repos/mikey179/vfsStream/issues/113/events","html_url":"https://github.com/mikey179/vfsStream/issues/113","id":74597815,"number":113,"title":"error with file_get_contents","user":{"login":"marcioAlmada","id":227395,"avatar_url":"https://avatars.githubusercontent.com/u/227395?v=3","gravatar_id":"","url":"https://api.github.com/users/marcioAlmada","html_url":"https://github.com/marcioAlmada","followers_url":"https://api.github.com/users/marcioAlmada/followers","following_url":"https://api.github.com/users/marcioAlmada/following{/other_user}","gists_url":"https://api.github.com/users/marcioAlmada/gists{/gist_id}","starred_url":"https://api.github.com/users/marcioAlmada/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/marcioAlmada/subscriptions","organizations_url":"https://api.github.com/users/marcioAlmada/orgs","repos_url":"https://api.github.com/users/marcioAlmada/repos","events_url":"https://api.github.com/users/marcioAlmada/events{/privacy}","received_events_url":"https://api.github.com/users/marcioAlmada/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-05-09T05:57:23Z","updated_at":"2015-10-06T16:29:26Z","closed_at":null,"body":"The following code results in a warning:\r\n\r\n```php\r\nuse org\\bovigo\\vfs\\vfsStream as Vsf;\r\n\r\n$root = Vsf::setup('dir');\r\nVsf::newFile('foo')->at($root)->withContent('~');\r\nfile_get_contents(Vsf::url('dir/foo'));\r\n```\r\n\r\n>  Warning: file_get_contents(vfs://dir/foo): failed to open stream:\r\n\"org\\bovigo\\vfs\\vfsStreamWrapper::stream_open\" call failed\r\n\r\nAm I missing something?"},"comment":{"url":"https://api.github.com/repos/mikey179/vfsStream/issues/comments/145919849","html_url":"https://github.com/mikey179/vfsStream/issues/113#issuecomment-145919849","issue_url":"https://api.github.com/repos/mikey179/vfsStream/issues/113","id":145919849,"user":{"login":"mikey179","id":190475,"avatar_url":"https://avatars.githubusercontent.com/u/190475?v=3","gravatar_id":"","url":"https://api.github.com/users/mikey179","html_url":"https://github.com/mikey179","followers_url":"https://api.github.com/users/mikey179/followers","following_url":"https://api.github.com/users/mikey179/following{/other_user}","gists_url":"https://api.github.com/users/mikey179/gists{/gist_id}","starred_url":"https://api.github.com/users/mikey179/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mikey179/subscriptions","organizations_url":"https://api.github.com/users/mikey179/orgs","repos_url":"https://api.github.com/users/mikey179/repos","events_url":"https://api.github.com/users/mikey179/events{/privacy}","received_events_url":"https://api.github.com/users/mikey179/received_events","type":"User","site_admin":false},"created_at":"2015-10-06T16:29:26Z","updated_at":"2015-10-06T16:29:26Z","body":"Sorry for not getting back to this earlier. I just tested with your snippet code, and it works:\r\n\r\n```\r\n➜  vfsStream git:(master) ✗ cat foo.php \r\n<?php\r\nrequire 'vendor/autoload.php';\r\n\r\nuse org\\bovigo\\vfs\\vfsStream as Vsf;\r\n\r\n$root = Vsf::setup('dir');\r\nVsf::newFile('foo')->at($root)->withContent('~');\r\nvar_dump(file_get_contents(Vsf::url('dir/foo')));\r\n\r\n➜  vfsStream git:(master) ✗ php foo.php \r\nstring(1) \"~\"\r\n```\r\n\r\nCan you post more details (e.g. PHP version, probably related php.ini settings)?\r\n"}}