Hello, High-schooler enthusiast here who's taken up learning J as a hobby. I'm currently trying to write a Discord bot in J. I have a working, bare-bones prototype here: https://github.com/Kauhentus/disj, but I have a few questions.
I'm currently using sockets to do all the internet/network communications, but they aren't event-driven. I've resorted to using a clunky while loop and constantly blocking/unblocking the thread with sdioctl as needed (the API requires a heartbeat every x interval, so completely blocking the thread is not an option). Is there a better way to do this? Also, Discord's API only works via HTTPS. As far as I know, J does not have an HTTPS library, so I resorted to using node.js and writing a small "proxy". I looked into how one might implement the TLS handshake but it's out of my ability. Am I out of luck if I want to write everything using J? I'm still new to J and 90%+ of my code is not idiomatic, but I'd appreciate any feedback and thoughts. Thanks! Best, Josh Y. ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm