Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Existing session #209

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

Closed
wants to merge 7 commits into from
Closed

Conversation

brunobeltran
Copy link
Contributor

PR Contains:

  1. Preliminary solution to Issue Connect to an already running Matlab instance instead of making one #196.
  2. Reorganization of code to facilitate Matlab scripts that use pymatbridge to call Python functions. Separation of concerns (moving _preamble_code to matlabserver helper functions) is how I think the solution to clear potential hang conditions #13 should look.
  3. Replaced all "print" and *.write() statements with configurable logging.
  4. Tried to update code comments that were out of date.

The new convention for connecting to Matlab is that

lab = Matlab(executable=something, ...)

follows the old behavior, while

lab = Matlab(executable=None, socket_addr='ipc:///something', ...)

connects to a Matlab sessions where the matlabserver.m function is being executed.

The only thing I'm having trouble getting to work is the new "separate" command, designed for when you've started a Matlab session via Matlab(executable=matlab).start() and later decide that what you need to do requires (or would just be nicer) if you were to drop into Matlab proper without having to save, exit, and reload the workspace. Combined with the ability to dynamically connect to Matlab, this could facilitate workflows that involve actively switching back and forth.

On my box, calling something like
lab = Matlab()
lab.start()
lab.separate()
opens the Matlab desktop GUI, as expected, but the ZMQ socket and context closing messages are mysteriously printed twice, and the GUI eventually exists without becoming available for use. Any ideas here?

@brunobeltran
Copy link
Contributor Author

Man, it must have been really late when I made the pull request. Problem with lab.separate() was super simple. Fixed now, as well as some bug fixes in messenger.c that I missed in my half-asleep state.

@brunobeltran
Copy link
Contributor Author

rebase'd over my previous pull request, so this branch should be merge-able. Any thoughts on why it hasn't been merged, or is it just a not-enough-time thing?

@arokem
Copy link
Owner

arokem commented Sep 11, 2015

Just not-enough-time. I really want to sort out the Travis breakage on
master, before considering any more massive changes, but have been too busy
with a host of other things, and this has languished. Again - working
towards a deadline mid-next-week, but might have time to look towards the
end of the week. Sorry for the delay...

On Thu, Sep 10, 2015 at 10:35 PM, Bruno Beltran [email protected]
wrote:

rebase'd over my previous pull request, so this branch should be
merge-able. Any thoughts on why it hasn't been merged, or is it just a
not-enough-time thing?


Reply to this email directly or view it on GitHub
#209 (comment)
.

@arokem
Copy link
Owner

arokem commented Sep 21, 2015

Can I close this one? Looks like it's superseded by #218

@brunobeltran
Copy link
Contributor Author

Oh, didn't realize I had the inf-fix stuff over this branch. Putting it all in one place sounds fine to me.

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

Successfully merging this pull request may close these issues.

2 participants