From 7b2c2d3742f1f00b1e64ff02c04152c9831909f0 Mon Sep 17 00:00:00 2001 From: John Dumbell Date: Wed, 20 Mar 2024 17:59:10 +0000 Subject: [PATCH 1/5] Define on-release event type When releasing for some reason it was attempting to deploy three times, I assume for created/released/published. Just limit to one of these. --- .github/workflows/deploy-wheels.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/deploy-wheels.yml b/.github/workflows/deploy-wheels.yml index 821553c..e93cf03 100644 --- a/.github/workflows/deploy-wheels.yml +++ b/.github/workflows/deploy-wheels.yml @@ -2,6 +2,7 @@ name: deploy-wheels on: release: + types: [released] jobs: deploy: From 67063dde1213bed5f10598817f4565e10db2eac0 Mon Sep 17 00:00:00 2001 From: John Dumbell Date: Wed, 20 Mar 2024 18:15:40 +0000 Subject: [PATCH 2/5] Missing format on exception message --- src/rasqal/src/runtime.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rasqal/src/runtime.rs b/src/rasqal/src/runtime.rs index 3091e79..7f1c369 100644 --- a/src/rasqal/src/runtime.rs +++ b/src/rasqal/src/runtime.rs @@ -475,7 +475,7 @@ impl QuantumRuntime { let stuff = context.step_count.deref().clone(); if context.step_count.deref() > limit { return Err(String::from( - "Execution step count limitation of {limit} exceeded." + format!("Execution step count limitation of {limit} exceeded.") )); } } From 5d42cafe3f38a85b6db66a4bc53991a22673caca Mon Sep 17 00:00:00 2001 From: John Dumbell Date: Thu, 21 Mar 2024 11:02:57 +0000 Subject: [PATCH 3/5] Testing examples.py on build Basic checks to make sure our examples aren't broken. --- src/scripts/psakefile.ps1 | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/scripts/psakefile.ps1 b/src/scripts/psakefile.ps1 index 391a197..c7665b7 100644 --- a/src/scripts/psakefile.ps1 +++ b/src/scripts/psakefile.ps1 @@ -7,6 +7,7 @@ Include utils.ps1 Properties { $ProjectRoot = Resolve-Path (Split-Path -Parent (Split-Path -Parent $PSScriptRoot)) $Root = Join-Path $ProjectRoot src + $Docs = Join-Path $ProjectRoot docs $BuildLlvm = Join-Path $Root build-llvm $Rasqal = Join-Path $Root rasqal $Target = Join-Path $Root target @@ -68,10 +69,16 @@ task test-rasqal { pip install --force-reinstall --no-deps $packages } + # Run Python tests Invoke-LoggedCommand -workingDirectory $Root { pip install pytest pytest . } + + # Run our examples Python file. + Invoke-LoggedCommand -workingDirectory $Docs { + python examples.py + } } task check-environment { From ac5c87720ccdc922571e66a5926a7f0041085795 Mon Sep 17 00:00:00 2001 From: John Dumbell Date: Thu, 21 Mar 2024 11:21:17 +0000 Subject: [PATCH 4/5] Add wheel deployment badge Currently builds aren't run directly against main/dev --- README.md | 2 +- src/rasqal/README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index d298bc0..be4df8d 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -![build status](https://github.com/oqc-community/rasqal/actions/workflows/build.yaml/badge.svg?branch=main) +[![PyPi Deployment](https://github.com/oqc-community/rasqal/actions/workflows/deploy-wheels.yml/badge.svg?event=release)](https://github.com/oqc-community/rasqal/actions/workflows/deploy-wheels.yml) Rasqal is a quantum-classical hybrid runtime which runs QIR in a fully dynamic fashion, building up quantum circuits on the fly and executing them against a provided quantum backend. It uses symbolic execution and heavily deferred execution to perform code transformations, optimizations and lowering to power the circuit synthesis. diff --git a/src/rasqal/README.md b/src/rasqal/README.md index d298bc0..be4df8d 100644 --- a/src/rasqal/README.md +++ b/src/rasqal/README.md @@ -1,4 +1,4 @@ -![build status](https://github.com/oqc-community/rasqal/actions/workflows/build.yaml/badge.svg?branch=main) +[![PyPi Deployment](https://github.com/oqc-community/rasqal/actions/workflows/deploy-wheels.yml/badge.svg?event=release)](https://github.com/oqc-community/rasqal/actions/workflows/deploy-wheels.yml) Rasqal is a quantum-classical hybrid runtime which runs QIR in a fully dynamic fashion, building up quantum circuits on the fly and executing them against a provided quantum backend. It uses symbolic execution and heavily deferred execution to perform code transformations, optimizations and lowering to power the circuit synthesis. From 502f11187a5a5ff18cc34053cac5c1885b8c480b Mon Sep 17 00:00:00 2001 From: John Dumbell Date: Thu, 21 Mar 2024 11:25:14 +0000 Subject: [PATCH 5/5] Bump version --- src/rasqal/pyproject.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rasqal/pyproject.toml b/src/rasqal/pyproject.toml index 480cd6a..b351375 100644 --- a/src/rasqal/pyproject.toml +++ b/src/rasqal/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "rasqal" -version = "0.1.1" +version = "0.1.2" requires-python = ">=3.9" description = "A dynamically executed quantum-classical hybrid optimizing runtime." license = { file = "LICENSE" }