{"action":"created","issue":{"url":"https://api.github.com/repos/jaor/geiser/issues/51","labels_url":"https://api.github.com/repos/jaor/geiser/issues/51/labels{/name}","comments_url":"https://api.github.com/repos/jaor/geiser/issues/51/comments","events_url":"https://api.github.com/repos/jaor/geiser/issues/51/events","html_url":"https://github.com/jaor/geiser/issues/51","id":58075236,"number":51,"title":"Read from stdin in REPL","user":{"login":"pasja","id":472806,"avatar_url":"https://avatars.githubusercontent.com/u/472806?v=3","gravatar_id":"","url":"https://api.github.com/users/pasja","html_url":"https://github.com/pasja","followers_url":"https://api.github.com/users/pasja/followers","following_url":"https://api.github.com/users/pasja/following{/other_user}","gists_url":"https://api.github.com/users/pasja/gists{/gist_id}","starred_url":"https://api.github.com/users/pasja/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pasja/subscriptions","organizations_url":"https://api.github.com/users/pasja/orgs","repos_url":"https://api.github.com/users/pasja/repos","events_url":"https://api.github.com/users/pasja/events{/privacy}","received_events_url":"https://api.github.com/users/pasja/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-02-18T14:37:42Z","updated_at":"2015-02-19T19:23:59Z","closed_at":null,"body":"Today i tried to run the following simple program in geiser, but when i send my buffer with `C-c C-a` to the repl, it hangs. I have to kill racket to get back control over my emacs. I played with `read-line` and i've got no question, but an empty string.\r\n\r\nIt worked well in drracket and from cli.\r\n\r\n```racket\r\n#lang racket\r\n\r\n(define test (display (string-append \"Hello \" (read))))\r\n```\r\n```\r\nracket --version \r\nWelcome to Racket v6.1.\r\n\r\nM-x geiser-version\r\nGeiser 0.7\r\n\r\nM-x emacs-version\r\nGNU Emacs 24.4.1 (x86_64-pc-linux-gnu, GTK+ Version 3.4.2) of 2015-01-11 on maritornes, modified by Debian\r\n```\r\n\r\nContent of the *geiser-messages* buffer\r\n```\r\nWARNING: <25> Droping result for request \",geiser-eval \\\"/tmp/teszt.rkt\\\" racket (begin (define myname (read))\r\n\r\n(display (string-append \\\"Hello \\\" myname))\r\n)\": ((error (key . struct:exn:break:terminate)) (output . terminate break\r\n\r\n))\r\n\r\nWARNING: <2> Droping result for request \",geiser-eval \\\"/tmp/teszt.rkt\\\" racket (define test (display (string-append \\\"Hello \\\" (read))))\": ((error (key . struct:exn:break:terminate)) (output . terminate break\r\n\r\n))\r\n\r\nWARNING: <3> Droping result for request \",geiser-eval \\\"/tmp/teszt.rkt\\\" racket (define test (display (string-append \\\"Hello \\\" (read))))\": ((error (key . struct:exn:break:terminate)) (output . terminate break\r\n\r\n))\r\n```\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/jaor/geiser/issues/comments/75117977","html_url":"https://github.com/jaor/geiser/issues/51#issuecomment-75117977","issue_url":"https://api.github.com/repos/jaor/geiser/issues/51","id":75117977,"user":{"login":"jaor","id":80719,"avatar_url":"https://avatars.githubusercontent.com/u/80719?v=3","gravatar_id":"","url":"https://api.github.com/users/jaor","html_url":"https://github.com/jaor","followers_url":"https://api.github.com/users/jaor/followers","following_url":"https://api.github.com/users/jaor/following{/other_user}","gists_url":"https://api.github.com/users/jaor/gists{/gist_id}","starred_url":"https://api.github.com/users/jaor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jaor/subscriptions","organizations_url":"https://api.github.com/users/jaor/orgs","repos_url":"https://api.github.com/users/jaor/repos","events_url":"https://api.github.com/users/jaor/events{/privacy}","received_events_url":"https://api.github.com/users/jaor/received_events","type":"User","site_admin":false},"created_at":"2015-02-19T19:23:59Z","updated_at":"2015-02-19T19:23:59Z","body":"\nThis is expected behaviour.  Evaluation of buffers in Geiser (as\ntriggered for instance by C-c C-a) sends the code to Racket and expects\na response back with a repl prompt, which in this case never happens\nbecause of the (read).\n\nThe equivalent of DrRacket's \"Run\" or execution via cli can be achieved\nin Geiser by evaluation performed *in* the REPL (as opposed to in the\nRacket buffer), for instance by requiring the file:\n\n```\nracket@> (require (file \"/home/jao/tmp/test.rkt\"))\n\"World\"\nHello Worldracket@> \n```\n\nDoes this answer your question?\n"}}