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

QVM port interferes with Mac Airplay receiver. #1653

Closed
2 tasks done
AJnsm opened this issue Sep 13, 2023 · 2 comments
Closed
2 tasks done

QVM port interferes with Mac Airplay receiver. #1653

AJnsm opened this issue Sep 13, 2023 · 2 comments
Labels
bug 🐛 An issue that needs fixing.

Comments

@AJnsm
Copy link

AJnsm commented Sep 13, 2023

Pre-Report Checklist

  • I am running the latest versions of pyQuil and the Forest SDK
  • I checked to make sure that this bug has not already been reported

Issue Description

The QVM starts a server through port 5000, but this resulted in the error USOCKET:ADDRESS-IN-USE-ERROR on my MacBook.

How to Reproduce

Run qvm -S on a Mac with airplay receiver enabled.

Environment Context

Operating System: MacOS Ventura 13.2.1 (22D68)

Python Version (python -V): Python 3.11.4

Quilc Version (quilc --version): 1.23.0 [e6c0939]

QVM Version (qvm --version): 1.17.1 [cf3f91f]

Solution

Running lsof -i -P -n | grep LISTEN shows that there is a ControlCenter process using port 5000. This thread seems to indicate that it is the airplay receiver doing this. In system setting, under "Airdrop & Handoff", you can disable Airplay Receiver. This frees the port and now qvm -S runs as expected.

It might be a good idea to add this to the docs, as Airplay Receiver seems to be enabled by default on MacOS.

@AJnsm AJnsm added the bug 🐛 An issue that needs fixing. label Sep 13, 2023
@notmgsk notmgsk pinned this issue Sep 13, 2023
@notmgsk
Copy link
Contributor

notmgsk commented Sep 13, 2023

Thanks for the report, @AJnsm. This an issue known by the QVM developers. I've pinned your report so it will be at the top of the pyquil issues list and thus hopefully more discoverable. I'll make a note to see how our documentation should be changed too.

@notmgsk notmgsk closed this as completed Sep 13, 2023
@cosenal
Copy link

cosenal commented Apr 3, 2024

For reference, the way I am obviating to this is by starting the QVM on port 5001 (e.g., docker run --rm -idt -p 5000:5001 rigetti/qvm -), and then setting the env var

QCS_SETTINGS_APPLICATIONS_QVM_URL='http://127.0.0.1:5001'

before executing a pyQuil program.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 An issue that needs fixing.
Projects
None yet
Development

No branches or pull requests

3 participants