Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changing package name #1

Merged
merged 1 commit into from
Feb 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/munchkin/pykin/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,4 @@ bitflags = "2.4.0"
crate-type = ["cdylib"]

[package.metadata.maturin]
name = "pykin._native"
name = "munchqin._native"
Empty file.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import os
import shutil
import sys

from datetime import date, datetime
from enum import Enum
from logging.config import dictConfig
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
from tempfile import NamedTemporaryFile
from typing import Any, List

from pykin import initialize_logger, BuilderAdaptor, RuntimeAdaptor, Executor, DEFAULT_LOG_FILE
from .utils import initialize_logger
from .adaptors import BuilderAdaptor, RuntimeAdaptor
from ._native import DEFAULT_LOG_FILE, Executor

dev_directory = join(dirname(__file__), "..", "..", "..", "munchkin")

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@

from typing import Dict

from pykin import BuilderAdaptor, RuntimeAdaptor
from qiskit.providers.models import QasmBackendConfiguration

from qiskit import QiskitError, QuantumCircuit, transpile
from qiskit_aer import AerSimulator

from pykin.runtime import MunchkinRuntime
from .runtime import MunchkinRuntime
from .adaptors import BuilderAdaptor, RuntimeAdaptor


def fetch_qasm_runtime(qubit_count=30):
Expand Down
3 changes: 0 additions & 3 deletions src/munchkin/pykin/pykin/__init__.py

This file was deleted.

2 changes: 1 addition & 1 deletion src/munchkin/pykin/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[project]
name = "pykin"
name = "munchqin"
version = "0.1.0"
requires-python = ">=3.9"
dependencies = [
Expand Down
12 changes: 7 additions & 5 deletions src/munchkin/scripts/psakefile.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Properties {
}

task default -depends build
task build -depends build-llvm, pykin
task build -depends build-llvm, munchqin
task checks -depends cargo-fmt, cargo-clippy, black, mypy
task manylinux -depends build-manylinux-container-image, run-manylinux-container-image

Expand Down Expand Up @@ -78,19 +78,21 @@ task build-llvm -depends init {
Invoke-LoggedCommand -workingDirectory $BuildLlvm { cargo build --release @(Get-CargoArgs) }
}

task pykin -depends init {
task munchqin -depends init {
$env:MATURIN_PEP517_ARGS = (Get-CargoArgs) -Join " "
Get-Wheels pykin | Remove-Item -Verbose
Get-Wheels munchqin | Remove-Item -Verbose
Invoke-LoggedCommand { pip --verbose wheel --no-deps --wheel-dir $Wheels $Pykin }

if (Test-CommandExists auditwheel) {
$unauditedWheels = Get-Wheels pykin
$unauditedWheels = Get-Wheels munchqin
Invoke-LoggedCommand { auditwheel repair --wheel-dir $Wheels $unauditedWheels }
$unauditedWheels | Remove-Item
}

$packages = Get-Wheels pykin
# Force reinstall the package if it exists, but not its depenencies.
$packages = Get-Wheels munchqin
Invoke-LoggedCommand -workingDirectory $Root {
pip install $packages
pip install --force-reinstall --no-deps $packages
}

Expand Down
2 changes: 1 addition & 1 deletion src/munchkin/scripts/utils.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ function Resolve-Python() {
function Resolve-PythonRequirements([string[]] $projects) {
$report = pip --quiet install --dry-run --ignore-installed --report - @projects | ConvertFrom-Json
$report.install.metadata `
| Where-Object { !$_.name.StartsWith("pykin") } `
| Where-Object { !$_.name.StartsWith("munchqin") } `
| ForEach-Object { "$($_.name)==$($_.version)" }
}

Expand Down
4 changes: 2 additions & 2 deletions src/munchkin/tests/test_munchkin.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
from os.path import abspath, dirname, join

from .file_utils import get_qir_path
from pykin.simulators import fetch_qasm_runtime
from pykin.runtime import (
from munchqin.simulators import fetch_qasm_runtime
from munchqin.runtime import (
BuilderAdaptor,
RuntimeAdaptor, MunchkinRuntime,
)
Expand Down
Loading