{"action":"created","issue":{"url":"https://api.github.com/repos/hylang/hy/issues/1457","repository_url":"https://api.github.com/repos/hylang/hy","labels_url":"https://api.github.com/repos/hylang/hy/issues/1457/labels{/name}","comments_url":"https://api.github.com/repos/hylang/hy/issues/1457/comments","events_url":"https://api.github.com/repos/hylang/hy/issues/1457/events","html_url":"https://github.com/hylang/hy/issues/1457","id":273507740,"number":1457,"title":"Hy not working from cron","user":{"login":"madhat2r","id":4122449,"avatar_url":"https://avatars0.githubusercontent.com/u/4122449?v=4","gravatar_id":"","url":"https://api.github.com/users/madhat2r","html_url":"https://github.com/madhat2r","followers_url":"https://api.github.com/users/madhat2r/followers","following_url":"https://api.github.com/users/madhat2r/following{/other_user}","gists_url":"https://api.github.com/users/madhat2r/gists{/gist_id}","starred_url":"https://api.github.com/users/madhat2r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/madhat2r/subscriptions","organizations_url":"https://api.github.com/users/madhat2r/orgs","repos_url":"https://api.github.com/users/madhat2r/repos","events_url":"https://api.github.com/users/madhat2r/events{/privacy}","received_events_url":"https://api.github.com/users/madhat2r/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2017-11-13T17:11:58Z","updated_at":"2017-11-14T15:34:35Z","closed_at":null,"author_association":"NONE","body":"Hy does not appear to be working when called as a cron job. Below is a simple test file I wrote when my real script would not execute via cron. I have verified that it is being called, but nothing appears to happen as the log file stays empty.\r\n\r\nI wrote a fairly complex application for a client that needs to be scheduled via cron, so any help is much appreciated.\r\n\r\n```\r\n$ python --version\r\nPython 3.6.2\r\n\r\n$ hy --version\r\nhy 0.13.0\r\n\r\n```\r\n\r\ntest.hy:\r\n```\r\n#! /usr/bin/env hy\r\n\r\n(import\r\n  logging)\r\n(def log-format \"%(asctime)-15s %(levelname)-8s %(filename)-15s:%(lineno)-3s %(message)s\")\r\n(defn cli []\r\n  (.basicConfig logging\r\n                :filename \"crontest.log\"\r\n                :level (. logging DEBUG)\r\n                :format log-format)\r\n  (setv l (.getLogger logging))\r\n  (.info l \"Running\"))\r\n\r\n(when (= --name-- \"__main__\")\r\n  (cli))\r\n\r\n```\r\ncron log entries:\r\n```\r\nNov 13 10:51:01 ArchNemesis CROND[29713]: (micah) CMD (/tmp/test.hy)\r\nNov 13 10:52:01 ArchNemesis CROND[31133]: (micah) CMD (/tmp/test.hy)\r\nNov 13 10:54:01 ArchNemesis CROND[3467]: (micah) CMD (/tmp/test.hy)\r\nNov 13 10:57:01 ArchNemesis CROND[9210]: (micah) CMD (/tmp/test.hy)\r\n\r\n```\r\n"},"comment":{"url":"https://api.github.com/repos/hylang/hy/issues/comments/344296702","html_url":"https://github.com/hylang/hy/issues/1457#issuecomment-344296702","issue_url":"https://api.github.com/repos/hylang/hy/issues/1457","id":344296702,"user":{"login":"madhat2r","id":4122449,"avatar_url":"https://avatars0.githubusercontent.com/u/4122449?v=4","gravatar_id":"","url":"https://api.github.com/users/madhat2r","html_url":"https://github.com/madhat2r","followers_url":"https://api.github.com/users/madhat2r/followers","following_url":"https://api.github.com/users/madhat2r/following{/other_user}","gists_url":"https://api.github.com/users/madhat2r/gists{/gist_id}","starred_url":"https://api.github.com/users/madhat2r/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/madhat2r/subscriptions","organizations_url":"https://api.github.com/users/madhat2r/orgs","repos_url":"https://api.github.com/users/madhat2r/repos","events_url":"https://api.github.com/users/madhat2r/events{/privacy}","received_events_url":"https://api.github.com/users/madhat2r/received_events","type":"User","site_admin":false},"created_at":"2017-11-14T15:34:35Z","updated_at":"2017-11-14T15:34:35Z","author_association":"NONE","body":"Why would then need to be equivalent.\r\n\r\nHy is breaking on importing logger."}}
{"actor":{"display_login":"madhat2r"}}