# Error with installation

**URL:** <https://discuss.pennylane.ai/t/error-with-installation/4993>\
**Category:** PennyLane Strawberry Fields\
**Created:** [July 30, 2024, 2:36pm UTC](https://discuss.pennylane.ai/t/error-with-installation/4993 "2024-07-30T14:36:40Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mlowe](https://yyz2.discourse-cdn.com/flex012/user_avatar/discuss.pennylane.ai/mlowe/32/2805_2.png) [@mlowe](https://discuss.pennylane.ai/u/mlowe)\
**Post date:** [July 30, 2024, 2:36pm UTC](https://discuss.pennylane.ai/t/error-with-installation/4993/1 "2024-07-30T14:36:40Z")

</div>

Hello! If applicable, put your complete code example down below. Make sure that your code:

- is 100% self-contained — someone can copy-paste exactly what is here and run it to  
reproduce the behaviour you are observing
- includes comments

```auto
# Put code here
import pennylane as qml

```

If you want help with diagnosing an error, please put the full error message below:

```auto
# Put full error message here
In 2023, my pennylane code could run on this computer. In summer 2024, I typed this: pip install pennylane --upgrade
pip list shows that PennyLane 0.37.0, PennyLane-Lightning 0.37.0 and PennyLane-SF 0.29.1 are installed.
However now my programs have trouble importing pennylane. Here is the error message:

Traceback (most recent call last):
  File "test.py", line 1, in <module>
    import pennylane as qml
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\ __init__.py", line 26, in <module>
    import pennylane.numpy
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\numpy\ __init__.py", line 87, in <module>
    from .wrapper import extract_tensors, tensor_wrapper, wrap_arrays
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\numpy\wrapper.py", line 23, in <module>
    from .tensor import tensor
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\numpy\tensor.py", line 25, in <module>
    from pennylane.operation import Operator
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\operation.py", line 260, in <module>
    from pennylane.math import expand_matrix
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\math\ __init__.py", line 37, in <module>
    from .matrix_manipulation import expand_matrix, reduce_matrices, get_batch_size
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\math\matrix_manipulation.py", line 24, in <module>
    from pennylane.wires import Wires
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\wires.py", line 23, in <module>
    from pennylane.pytrees import register_pytree
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\pytrees\ __init__.py", line 18, in <module>
    from .pytrees import PyTreeStructure, flatten, is_pytree, leaf, register_pytree, unflatten
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\pytrees\pytrees.py", line 21, in <module>
    import pennylane.queuing
  File "C:\Users\mlowe\anaconda3\lib\site-packages\pennylane\queuing.py", line 560, in <module>
    ) -> tuple[list[ops_or_meas], list["pennylane.measurements.MeasurementProcess"]]:
TypeError: 'type' object is not subscriptable

Can you help me?

```

And, finally, make sure to include the versions of your packages. Specifically, show us the output of `qml.about()`.

---

<div class="post-metadata">

**Author:** ![CatalinaAlbornoz](https://yyz2.discourse-cdn.com/flex012/user_avatar/discuss.pennylane.ai/catalinaalbornoz/32/1196_2.png) [@CatalinaAlbornoz](https://discuss.pennylane.ai/u/CatalinaAlbornoz)\
**Post date:** [August 1, 2024, 6:27am UTC](https://discuss.pennylane.ai/t/error-with-installation/4993/2 "2024-08-01T06:27:09Z")

</div>

Hi @mlowe, welcome to the Forum!

Thank you for your question. The PennyLane-SF plugin only works with versions v0.29 of PennyLane or lower. I suggest that you create a new virtual environment where you `pip install pennylane==0.29` and then pip install the plugin.

Let me know if this fixes your issue!
