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

Heads up. Breaking commit in SP3.2dev #20

Open
rbnpi opened this issue Aug 22, 2019 · 6 comments
Open

Heads up. Breaking commit in SP3.2dev #20

rbnpi opened this issue Aug 22, 2019 · 6 comments

Comments

@rbnpi
Copy link
Contributor

rbnpi commented Aug 22, 2019

Sam has changed the port structure within SP3.2dev Now the server listening port is dynamically allocated. commit d245d93c5b797ad76fa333f829c32d67480af96c
on 30th April.
I suggest adding a -p option to sonic-pi-cli with default value 4557 but where the user can specify the dynamic port currently allocated (which can be inspected in the Sonic Pi server log). Sam talks of adding a text file where users can override the port allocations, but that is not available at present. The other alternative is that the user overrides the dynamic port allocation in teh SP source, but most users wont want to do this.

@rbnpi
Copy link
Contributor Author

rbnpi commented Aug 26, 2019

Now done a rewrite allowing for extraction of current server listen port which is dynamically allocated in Sonic Pi 3.2dev. Amended code to read the allocated port from the .sonic-pi/log/server-output.log, and then to use this when setting up the OSC link rather than the hard wired port 4557. For compatibility, if the new format log file is not present then the previous port 4557 is used ensuring compatibility back to Sonic Pi 2.7. The code used has been tested on Mac, Raspberry Pi and Windows PC.
Once I've completed final testing I'll submit a PR from my forked version

@Widdershin
Copy link
Owner

Good to know. If someone is willing to make a pull request to support this change I'd really appreciate it.

@Widdershin
Copy link
Owner

Oh sorry I hadn't reloaded this issue when I made that comment, sounds good 👍

@rbnpi
Copy link
Contributor Author

rbnpi commented Aug 27, 2019

Pretty happy with it now. Will rebase and PR the final version later this afternoon.

@rbnpi
Copy link
Contributor Author

rbnpi commented Aug 28, 2019

Now posted a PR to solve the problem

@rbnpi
Copy link
Contributor Author

rbnpi commented Feb 21, 2020

Bump this. Sonic Pi 3.2 is due to be released at the end of Feb 2020.
I have tested my PR version of sonic_pi_cli on Raspberry Pi, Windows and Mac and it works fine, both with this new release (Im using the latest beta for Windows, and builds from altest github for Mac and RPi), and more importantly with existing 3.1 builds. Can you incorporate the PR now as the existing version will not work with the new release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants