microsoft / QuantumKatas

Tutorials and programming exercises for learning Q# and quantum computing
MIT License
4.53k stars 1.21k forks source link

Enable tests that are currently excluded with multicell solution tag #806

Closed Manvi-Agrawal closed 11 months ago

Manvi-Agrawal commented 2 years ago

In PR 539 : Updating notebooks validation script to exclude individual tasks, we excluded tasks in CHSHGame and MagicSquareGame because some tasks required implementing two code cells at once before running the test, so the first of the cells implemented is guaranteed to fail.

Currently, the following notebooks have a multicell_solution

We can enable those tests in the workbook by using raises-exception cell tag which runs the cell but ignores any exceptions encountered during the cell execution. Here is a sample PR : https://github.com/microsoft/QuantumKatas/pull/805 which enables these tests in CHSH Workbook

However currently, we can only enable the Workbook tests and not the jupyter front-end notebook tests because KataMagic stores the results of its previous excutions whereas CheckKataMagic doesn't. For more details, here are the links KataMagic code and CheckKataMagic code

@tcNickolas, @anjbur, maybe we can do this small change in CheckKataMagic to store the results of previous tests, so that we can enable those tests. Thoughts?

tcNickolas commented 11 months ago

We will be migrating the Katas to the new QDK that will use a different infrastructure (see https://devblogs.microsoft.com/qsharp/introducing-the-azure-quantum-development-kit-preview/ for the announcement), so we won't continue to improve the existing infrastructure of Q# notebooks magics. Closing this issue as "won't fix".

Manvi-Agrawal commented 11 months ago

Thanks @tcNickolas for your valuable guidance.

Looking forward to the new kata experience. Just had a look at https://quantum.microsoft.com/en-us/experience/quantum-katas, and the experience looks way more polished :-)