{"id":15637188,"url":"https://github.com/dsblank/simple_kernel","last_synced_at":"2025-07-29T06:35:31.708Z","repository":{"id":13339169,"uuid":"16026269","full_name":"dsblank/simple_kernel","owner":"dsblank","description":"A small, simple kernel example for IPython","archived":false,"fork":false,"pushed_at":"2019-03-25T11:56:42.000Z","size":61,"stargazers_count":112,"open_issues_count":0,"forks_count":25,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-04-15T06:12:04.218Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dsblank.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-01-18T13:45:50.000Z","updated_at":"2025-04-12T18:42:10.000Z","dependencies_parsed_at":"2022-09-05T18:00:33.424Z","dependency_job_id":null,"html_url":"https://github.com/dsblank/simple_kernel","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fsimple_kernel","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fsimple_kernel/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fsimple_kernel/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dsblank%2Fsimple_kernel/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dsblank","download_url":"https://codeload.github.com/dsblank/simple_kernel/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249016637,"owners_count":21198833,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-03T11:10:40.949Z","updated_at":"2025-04-15T06:12:09.967Z","avatar_url":"https://github.com/dsblank.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"simple_kernel\n=============\n\nA small, simple kernel example for Jupyter, specification version: 5.0\n\n## Run\n\nDownload and run:\n\n`ipython console --KernelManager.kernel_cmd=\"['python', 'simple_kernel.py', '{connection_file}']\"`\n\n`ipython notebook --KernelManager.kernel_cmd=\"['python', 'simple_kernel.py', '{connection_file}']\"`\n\n`ipython qtconsole --KernelManager.kernel_cmd=\"['python', 'simple_kernel.py', '{connection_file}']\"`\n\n### Alternative way\n\nInstall Jupyter\n\n```Bash\n$ git clone https://github.com/jupyter/notebook.git\n$ cd notebook\n$ mkvirtualenv jupyter-env\n$ workon jupyter-env\n(jupyter-env) $ pip install --pre -e .\n(jupyter-env) $ pip install jupyter-console\n```\n\nDownload project to the different directory, install (prepare kernel.json file with `install_script.sh` script) and run:\n\n```Bash\n(jupyter-env) $ git clone https://github.com/dsblank/simple_kernel.git\n(jupyter-env) $ ./install_script.sh\n(jupyter-env) $ jupyter console --kernel simple_kernel\n```\n\n### Testing kernel\n\nYou can test your project using [jupyter_kernel_test](https://github.com/jupyter/jupyter_kernel_test) project.\n\nClone this project:\n\n```Bash\n(jupyter-env) $ git clone https://github.com/jupyter/jupyter_kernel_test\n(jupyter_env) $ cd jupyter_kernel_test\n```\n\nModify `test_ipython.py` file to look like this:\n\n```Python\nimport unittest\nimport jupyter_kernel_test as jkt\n\nclass IRkernelTests(jkt.KernelTests):\n    kernel_name = \"simple_kernel\"\n    language_name = \"simple_kernel\"\n\n    code_hello_world = \"print('hello, world')\"\n\nif __name__ == '__main__':\n    unittest.main()\n```\n\nand run this project with following command:\n\n```Bash\n(jupyter-env) $ python test_ipython.py\n```\n\nOutput should be similar to this:\n\n```Bash\n### some debug information\n----------------------------------------------------------------------\nRan 5 tests in 1.034s\n\nOK (skipped=3)\n```\n\nCurrent status\n----------\n\nFeatures:\n\n* shell, heartbeat, and iopub channels working\n* signatures are correct\n* need to test control and stdin channels\n* need to handle \"magics\"\n\nBugs:\n\n1. when running a console, doesn't stop python when exiting\n\nReferences\n----------\n\nThese references may be helpful in understanding the big picture of IPython and zmq.\n\n1. http://ipython.org/ipython-doc/dev/development/messaging.html - Messaging documentation\n2. http://andrew.gibiansky.com/blog/ipython/ipython-kernels/ - Useful document in making a kernel\n3. http://zeromq.github.io/pyzmq/api/index.html - 0MQ Documentation for low-level socket functionality\n\nOther Kernel Examples\n---------------------\n\nHere is a list of all of the standalone kernels (backends) that I know about. I don't think I got a single one to run, however.\n\n* https://github.com/gibiansky/IHaskell - Written in Haskell\n* https://github.com/takluyver/igo - Written in Go\n  * fails to build, needs Go 1.2?\n* https://github.com/mattpap/IScala - Written in Scala\n* https://github.com/mattpap/IAldor - Written C\n  * fails to build\n* https://github.com/mattpap/ipykernel - Written in C\n  *  needs \"sudo ln -s /usr/lib/x86_64-linux-gnu/libjansson.so.4 /usr/lib/libjansson.so\"\n  *  needs \"sudo apt-get install uuid-dev\"\n  *  echo fails, needs M_UUID defined\n* http://nbviewer.ipython.org/gist/Carreau/4279371/node-kernel.ipynb - Written in JavaScript\n  * needs \"sudo apt-get install libzmq-dev\"\n  * ImportError: The IPython Notebook requires tornado \u003e= 3.1.0, but you have 2.4.1\n  * After upgrading \"sudo pip install tornado\": ImportError: No module named zmq.subprocesskernel\n  * Matthias Bussonnier says \"The node example pre-date the ability to configure kernelmanager. Just forget about subpricesskernelmanager.\"\n* https://github.com/minrk/profile_jskernel - In-browser JavaScript kernel\n  * doesn't work as far as I can tell\n* https://bitbucket.org/ipre/calico/src/master/Source/Calico/ZMQServer.cs?at=master - Written in C#, but serves a variety of languages (Java, Python, Scheme, and others)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdsblank%2Fsimple_kernel","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdsblank%2Fsimple_kernel","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdsblank%2Fsimple_kernel/lists"}