amazon-braket / amazon-braket-pennylane-plugin-python

A plugin for allowing Xanadu PennyLane to use Amazon Braket devices
https://amazon-braket-pennylane-plugin-python.readthedocs.io/
Apache License 2.0
43 stars 37 forks source link

DEFAULT_RESULTS_POLL_TIMEOUT_SIMULATOR exists in master but not in stable/latest #17

Closed jmp-aws closed 4 years ago

jmp-aws commented 4 years ago

executing the following commands

virtualenv braket
cd braket
source bin/activate
git clone -b stable/latest https://github.com/aws/braket-python-sdk.git
git clone -b stable/latest https://github.com/aws/amazon-braket-pennylane-plugin-python.git
pip install -e amazon-braket-pennylane-plugin-python
pip install -e braket-python-sdk
python -c "from braket.pennylane_plugin import AWSSimulatorDevice"

produces the error

AttributeError: type object 'AwsQuantumSimulator' has no attribute 'DEFAULT_RESULTS_POLL_TIMEOUT_SIMULATOR'

that is because DEFAULT_RESULTS_POLL_TIMEOUT_SIMULATOR does not exist in the stable/latest branch of the braket-python-sdk.

stable/latest https://github.com/aws/braket-python-sdk/blob/stable/latest/src/braket/aws/aws_quantum_simulator.py

master https://github.com/aws/braket-python-sdk/blob/master/src/braket/aws/aws_quantum_simulator.py#L30-L32

speller26 commented 4 years ago

Fixed with new releases of the SDK and PennyLane plugin: https://github.com/aws/braket-python-sdk/releases/tag/v0.4.0 https://github.com/aws/amazon-braket-pennylane-plugin-python/releases/tag/v0.1.3

For the new SDK release, you'll also want to pull in the latest release of the default simulator: https://github.com/aws/amazon-braket-default-simulator-python/releases/tag/v0.2.0