New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Eio: stdenv type not compatiable with Eio_unix.Stdenv #114
Comments
I assume you are seeing a compile-time error related to the |
Thank you! I'm not too familiar with classes, so sorry for wasting your time. |
No problem; it's one of the lesser known parts of the language. Maybe the preferred way would have been to pass the three resources individually, though I think the current approach of bundling them provides a better chance of programs being compatible with new versions of Caqti which might require extra resources from the stdenv. |
I know caqti-eio is prerelease, but would it's API be stable enough to receive some documentation? I would be happy to translate the bikereg example from Lwt. I think Eio can present unfamiliar elements to more people than me (especially with it's use of the class system), so a simple 1-1 demonstration of an lwt program would be useful. |
Yes, I realized some documentation is needed here. I will add some basics to the API doc. The caqti-study is maybe a better place for examples. I have considered moving the bikereg there, as well. We should coordinate that with @benjamin-thomas who has done most of the current work there. |
Sounds good to me 👍 I've opened an issue to track this. We can discuss there if you feel like giving a hand @ada2k |
Hi,
The ~stdenv argument taken by caqti-eio does not appear to be compatible with Eio_unix.Stdenv. If I manually create an object with the net, clock and mono_clock methods copied from Eio_unix.Stdenv, it then throws a type error expecting [
Generic] instead of [
Generic |Unix]. Editing system.ml to accept [
Generic | `Unix ] allows me to connect to a postgres instance fine. I have caqti pinned to master with eio 0.14, not tested on release.Thank you
The text was updated successfully, but these errors were encountered: