Title: [fork-ffi] console: error — Upstream purescript-console maps `error :: String -> Effect Unit` to… · Issue #76 · purescript-lua/purescript-lua · GitHub
Open Graph Title: [fork-ffi] console: error — Upstream purescript-console maps `error :: String -> Effect Unit` to… · Issue #76 · purescript-lua/purescript-lua
X Title: [fork-ffi] console: error — Upstream purescript-console maps `error :: String -> Effect Unit` to… · Issue #76 · purescript-lua/purescript-lua
Description: Package: purescript-lua-console File: src/Effect/Console.lua Function: error Class: semantics Severity: low Upstream purescript-console maps error :: String -> Effect Unit to console.error, which writes to stderr in Node. The Lua FFI rou...
Open Graph Description: Package: purescript-lua-console File: src/Effect/Console.lua Function: error Class: semantics Severity: low Upstream purescript-console maps error :: String -> Effect Unit to console.error, which w...
X Description: Package: purescript-lua-console File: src/Effect/Console.lua Function: error Class: semantics Severity: low Upstream purescript-console maps error :: String -> Effect Unit to console.error, whic...
Opengraph URL: https://github.com/purescript-lua/purescript-lua/issues/76
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"[fork-ffi] console: error — Upstream purescript-console maps `error :: String -> Effect Unit` to…","articleBody":"**Package:** purescript-lua-console \n**File:** `src/Effect/Console.lua` \n**Function:** `error` \n**Class:** semantics **Severity:** low\n\nUpstream purescript-console maps `error :: String -> Effect Unit` to `console.error`, which writes to stderr in Node. The Lua FFI routes it through `print`, which writes to stdout. Consumers that separate stdout/stderr (the normal reason to call `error` rather than `log`) will see error output mixed into stdout, losing the only behavioral distinction `error` has from `log` in this port. Confirmed under Lua 5.1: `C.error(\"err-msg\")()` emits to stdout, not stderr.\n\n**Current (Lua):**\n```lua\nerror = (function(s) return function() print(s) end end),\n```\n\n**Expected:** console.error writes to stderr; the Lua equivalent is io.stderr:write(s .. \"\\n\"). print() unconditionally targets stdout.\n\n**Proposed fix:**\n```lua\nerror = (function(s) return function() io.stderr:write(tostring(s) .. \"\\n\") end end),\n```\n\n_Found by the FFI audit; reproduced under Lua 5.1._","author":{"url":"https://github.com/Unisay","@type":"Person","name":"Unisay"},"datePublished":"2026-06-15T11:23:55Z","url":"https://github.com/purescript-lua/purescript-lua/issues/76"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:358d1412-c55d-ac74-0d01-f5b385bc3247 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 96AC:2AAD2E:6002C2:821A5A:6B00D538 |
| html-safe-nonce | 4eacb2d80833c434a2cc2abbf78f8860711242b0fb4acd7de999c8ff151592a4 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5NkFDOjJBQUQyRTo2MDAyQzI6ODIxQTVBOjZCMDBENTM4IiwidmlzaXRvcl9pZCI6Ijc3NDc1Njk3MTc5MzQwNTI0MSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 252f3acd01d1173cef9ae6f07234c8244516be124b4c88433daf8cb631eb4271 |
| hovercard-subject-tag | issue:4664606597 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/purescript-lua/purescript-lua/76/issue_layout |
| twitter:image | https://opengraph.githubassets.com/aced2dceb99545aebbc63b2d1f5c189a50770b1842bdf8ec3bfca8be5871d353/purescript-lua/purescript-lua/issues/76 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/aced2dceb99545aebbc63b2d1f5c189a50770b1842bdf8ec3bfca8be5871d353/purescript-lua/purescript-lua/issues/76 |
| og:image:alt | Package: purescript-lua-console File: src/Effect/Console.lua Function: error Class: semantics Severity: low Upstream purescript-console maps error :: String -> Effect Unit to console.error, which w... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Unisay |
| hostname | github.com |
| expected-hostname | github.com |
| None | a481f62a1e04c9b9bdcb5628230682c66d59006f5b13b080f79cba84a176905b |
| turbo-cache-control | no-preview |
| go-import | github.com/purescript-lua/purescript-lua git https://github.com/purescript-lua/purescript-lua.git |
| octolytics-dimension-user_id | 131581790 |
| octolytics-dimension-user_login | purescript-lua |
| octolytics-dimension-repository_id | 587200487 |
| octolytics-dimension-repository_nwo | purescript-lua/purescript-lua |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 587200487 |
| octolytics-dimension-repository_network_root_nwo | purescript-lua/purescript-lua |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 84c8c5cc25e2fb7f2308428458538436baecc6d2 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width