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

FIX: issue #146 (No output in Matlab 2020b) #147

Merged
merged 2 commits into from
Nov 2, 2020
Merged

FIX: issue #146 (No output in Matlab 2020b) #147

merged 2 commits into from
Nov 2, 2020

Conversation

davide84
Copy link

No description provided.

@dsblank
Copy link
Member

dsblank commented Oct 29, 2020

@davide84 Any idea of when this changed? Will it break with other versions? What versions is this know to work? Maybe we need something in the front README that mentions what version it is know to work?

@davide84
Copy link
Author

You are right. I'll try to get some more information.

@davide84
Copy link
Author

davide84 commented Oct 30, 2020

Ok, first thing I understood is that the change is related to the Matlab engine, not to Python in general.

According to Matlab documentation:

eng = matlab.engine.start_matlab(async) starts MATLAB asynchronously if async is True. Not recommended. Use the background argument instead. Do not use for Python Version 3.7.
For Python Version 3.7, async is a keyword and cannot be used as an argument for matlab.engine.start_matlab. Use the background argument instead for all supported versions of Python.
https://ch.mathworks.com/help/matlab/apiref/matlab.engine.start_matlab.html

My understanding is that 'background' should not only be the default nowadays, but it it also recommended for all versions of Python with Matlab 2020b.

As for previous Matlab versions, according to my research the 'background' keyword was introduced in Matlab R2017b:
https://ch.mathworks.com/help/releases/R2017b/matlab/apiref/matlab.engine.start_matlab.html?s_tid=doc_ta
and it was not present in R2017a:
https://ch.mathworks.com/help/releases/R2017a/matlab/apiref/matlab.engine.start_matlab.html?s_tid=doc_ta

EDIT: I integrated the PR with a backward-compatibility try/except. It works on my setup (Python 3.8 and Matlab 2020b).

@dsblank
Copy link
Member

dsblank commented Nov 1, 2020

Looks good (even tough I don't have matlab 👍 )!

Copy link
Contributor

@blink1073 blink1073 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@blink1073 blink1073 merged commit 12a5041 into Calysto:master Nov 2, 2020
@blink1073
Copy link
Contributor

Released as 0.16.10.

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.

3 participants