question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

NBGrader with cling kernel

See original GitHub issue

Operating system

Linux Debian wheezy

nbgrader --version

nbgrader version 0.5.4

jupyterhub --version (if used with JupyterHub)

jupyter notebook --version

5.5.0

Expected behavior

I am using the C++ cling kernel with NbGrader and running into some issues.

  1. assert(false) or another method causes 0 points and program continues.
  2. cell execution if it throws uncaught exception, lets the kernel continue

Actual behavior

  1. using the assert function in C/C++ does not cause test to fail assert(false) gets full credit I think assert in C++ cling has no effect in production mode. There should be another method provided
  2. If the execution of a cell leads to uncaught exception, cling should not hang but continue.

Problem 2 is probably a problem with the kernel.

Steps to reproduce the behavior

Install a cling kernel and NbGrader . Also I use the following nbgrader_config.py : c = get_config() c.Exchange.course_id = “AlgoProj1” c.Exchange.root = “/mnt/nfs/dcdemo110@gmail.com/share” c.ExecutePreprocessor.kernel_name = “cling-cpp17” c.ClearSolutions.code_stub = { “R”: “# your code here\nraise NotImplementedError”, “python”: “# your code here\nraise NotImplementedError”, “javascript”: “// your code here, make sure it compiles or no grade for the whole notebook\n return 0;”, “C++”: “// your code here\n throw NULL;” }

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:12 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
jhamrickcommented, May 30, 2019

Yes, makes sense to close I think, thanks for confirming @nthiery that it works with xeus-cling at least!

0reactions
nthierycommented, May 30, 2019

I can confirm that nbgrader works very smoothly with xeus-cling. Maybe this issue can be closed? This is really a bug of the plain cling kernel.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Nbgrader and other programming languages - Education
I am thinking about whether I could use this, for example, to grade notebooks that depend on other language kernels, like Java, C++,...
Read more >
nbgrader 0.7.2.dev documentation - Read the Docs
It is up to the Jupyter kernel to write an error message to the standard error stream, otherwise autograder doesn't work (this has...
Read more >
C++ - Lab.Computer Docs
Open terminal. We provide a package for the conda package manager. Installing xwidgets and the C++ kernel. conda install xeus-cling xwidgets -c conda-forge....
Read more >
AUR (en) - Packages - Arch Linux
cling -jupyter-dev, v0.7-2, 0, 0.00, Interactive C++ interpreter (includes ... common-lisp-jupyter-git, r584.4e4d1f4-1, 0, 0.00, A Common Lisp kernel for ...
Read more >
jupyterhub/jupyterhub - Gitter
... like recent changes to jupyterhub are causing problems for nbgrader tests. ... I've added a kernel spec into ~/.ipyton/kernels but it is...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found