Title: Support for pyproj: cpython.pythread APIs cause runtime crash · Issue #590 · oracle/graalpython · GitHub
Open Graph Title: Support for pyproj: cpython.pythread APIs cause runtime crash · Issue #590 · oracle/graalpython
X Title: Support for pyproj: cpython.pythread APIs cause runtime crash · Issue #590 · oracle/graalpython
Description: Summary pyproj builds successfully on GraalPy but crashes at runtime with SystemError: internal exception occurred due to unsupported cpython.pythread Cython APIs. Environment GraalPy 25.0.0 (Python 3.12.8), macOS ARM64 pyproj 3.7.2, PRO...
Open Graph Description: Summary pyproj builds successfully on GraalPy but crashes at runtime with SystemError: internal exception occurred due to unsupported cpython.pythread Cython APIs. Environment GraalPy 25.0.0 (Pytho...
X Description: Summary pyproj builds successfully on GraalPy but crashes at runtime with SystemError: internal exception occurred due to unsupported cpython.pythread Cython APIs. Environment GraalPy 25.0.0 (Pytho...
Opengraph URL: https://github.com/oracle/graalpython/issues/590
X: @github
Domain: patch-diff.githubusercontent.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Support for pyproj: cpython.pythread APIs cause runtime crash","articleBody":"# Summary\n\npyproj builds successfully on GraalPy but crashes at runtime with `SystemError: internal exception occurred` due to unsupported `cpython.pythread` Cython APIs.\n\n# Environment\n\n- GraalPy 25.0.0 (Python 3.12.8), macOS ARM64\n- pyproj 3.7.2, PROJ 9.7.1\n\n# Reproduction\n\n```bash\ngraalpy -m venv .venv \u0026\u0026 source .venv/bin/activate\nPROJ_DIR=/path/to/proj pip install pyproj\npython -c \"from pyproj import CRS\" # crashes\nError\n\nFile \"pyproj/_crs.pyx\", line 22, in init pyproj._crs\nSystemError: internal exception occurred\n```\n\n# Root Cause\npyproj's _context.pyx uses CPython thread-local storage APIs:\n\nfrom cpython.pythread cimport PyThread_tss_create, PyThread_tss_get, PyThread_tss_set\nThese are used unconditionally (no fallback for non-CPython implementations).\n\n# What I Tried\nPatched _compat.pyx to remove cpython cimport array, this worked\nBut _context.pyx still crashes due to the cpython.pythread imports above\n\n# Suggested Fix\nEither:\n\n- GraalPy patches for pyproj (similar to numpy/pandas patches)\n- Implement cpython.pythread APIs: PyThread_tss_create, PyThread_tss_get, PyThread_tss_set\n\n# Impact\npyproj is required by geopandas and the broader geospatial Python ecosystem.","author":{"url":"https://github.com/shrynx","@type":"Person","name":"shrynx"},"datePublished":"2026-01-13T20:33:56.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/590/graalpython/issues/590"}
| 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:994bd711-240e-0d08-b310-2de36f98b4bc |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | C572:337619:13AAC10:1B6A38E:696F4657 |
| html-safe-nonce | d9e3f831edb1bfd2d21bbe52b0f50365e80f7ee15e996269b1d9bf5f4bf2f410 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDNTcyOjMzNzYxOToxM0FBQzEwOjFCNkEzOEU6Njk2RjQ2NTciLCJ2aXNpdG9yX2lkIjoiMTQzMzg0NTIzNjkxODg2MzQ0NyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | b44d85f63c164fa1c2db70e6278f01300cc79c37c9d84eb011a86d95e07651be |
| hovercard-subject-tag | issue:3810493715 |
| 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/oracle/graalpython/590/issue_layout |
| twitter:image | https://opengraph.githubassets.com/29072a95ae8b22615c625b31946c85e9329793ba895101d3a84416e7cdcaf9ae/oracle/graalpython/issues/590 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/29072a95ae8b22615c625b31946c85e9329793ba895101d3a84416e7cdcaf9ae/oracle/graalpython/issues/590 |
| og:image:alt | Summary pyproj builds successfully on GraalPy but crashes at runtime with SystemError: internal exception occurred due to unsupported cpython.pythread Cython APIs. Environment GraalPy 25.0.0 (Pytho... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | shrynx |
| hostname | github.com |
| expected-hostname | github.com |
| None | b278ad162d35332b6de714dfb005de04386c4d92df6475522bef910f491a35ee |
| turbo-cache-control | no-preview |
| go-import | github.com/oracle/graalpython git https://github.com/oracle/graalpython.git |
| octolytics-dimension-user_id | 4430336 |
| octolytics-dimension-user_login | oracle |
| octolytics-dimension-repository_id | 129883600 |
| octolytics-dimension-repository_nwo | oracle/graalpython |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 129883600 |
| octolytics-dimension-repository_network_root_nwo | oracle/graalpython |
| 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 | 39aed5006635ab6f45e6b77d23e73b08a00272a3 |
| ui-target | canary-1 |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width