m-labs / artiq

A leading-edge control system for quantum information experiments
https://m-labs.hk/artiq
GNU Lesser General Public License v3.0
414 stars 192 forks source link

Conda installation on windows couldn't find artiq #2398

Open thomasfire opened 2 months ago

thomasfire commented 2 months ago

Bug Report

One-Line Summary

Conda installation on windows couldn't find artiq.

Issue Details

Probably related to the Python 3.12 being pushed in conda.

(base) PS C:\Users\esmlabs> conda activate artiq
(artiq) PS C:\Users\esmlabs> artiq_browser
Traceback (most recent call last):
  File "C:\ProgramData\miniconda3\envs\artiq\Scripts\artiq_browser-script.py", line 5, in <module>
    from artiq.frontend.artiq_browser import main
ModuleNotFoundError: No module named 'artiq'
(artiq) PS C:\Users\esmlabs> artiq_run
Traceback (most recent call last):
  File "C:\ProgramData\miniconda3\envs\artiq\Scripts\artiq_run-script.py", line 5, in <module>
    from artiq.frontend.artiq_run import main
ModuleNotFoundError: No module named 'artiq'

Steps to Reproduce

  1. Clean install windows 11/10
  2. Follow official instructions for conda installation on windows (both release-7 and beta), either miniconda or full anaconda
  3. In artiq environment, try run any artiq command
  4. Any command fails with ModuleNotFoundError: No module named 'artiq'

Your System (omit irrelevant parts)

sbourdeauducq commented 2 months ago

Probably related to the Python 3.12 being pushed in conda.

The conda installer is still for 3.11.

thatschatt commented 2 months ago

I was seeing problems where the artiq packages were installed into env/artiq/site-packages instead of env/artiq/Lib/site-packages , however I just tried again, and this time they ended up in the right place. So maybe fixed?

thomasfire commented 2 months ago

I was seeing problems where the artiq packages were installed into env/artiq/site-packages instead of env/artiq/Lib/site-packages

I checked it now, and it indeed seems to be the case, with similar happening on Fedora 40

(artiq) [user@fedora ~]$ artiq_browser                                       
Traceback (most recent call last):                                              
  File "/home/user/.conda/envs/artiq/bin/artiq_browser", line 6, in <module> 
    from artiq.frontend.artiq_browser import main
ModuleNotFoundError: No module named 'artiq'

What's interesting, if I install the same package from cache (without dependencies), it will install into right location: conda install /home/user/.conda/pkgs/artiq-7.8190.db79100-0.tar.bz2