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

Skip to content

Conversation

aebrahim
Copy link
Contributor

@aebrahim aebrahim commented Mar 9, 2015

No description provided.

@arokem
Copy link
Owner

arokem commented Mar 10, 2015

Thanks for doing this! I think that the test breakage is fixed here:

#162

So let's merge that one first, and then rebase this one on top of it, before merging it as well.

else:
print(usage)
build_octave()
Copy link
Owner

Choose a reason for hiding this comment

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

This seems like it might be confusing. If someone enters a typo, it will try to build the octave thing and emit a confusing error. How about:

elif args.target == 'octave':
    build_octave
else: 
    e_s = "'%s' is not a valid target for building the messenger."%args.target
    e_s = e_s + " Use 'matlab' or 'octave'" 
    raise ValueError(e_s)

Or something to that effect. Also, could you please rebase on master? Thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It won't let you choose another one because argparse limits the choices.

for example, running ./make.py foo will give:
usage: make.py [-h] [--static] {matlab,octave}
make.py: error: argument target: invalid choice: 'foo' (choose from
'matlab', 'octave')

On Mon, Mar 9, 2015 at 7:54 PM, Ariel Rokem [email protected]
wrote:

In messenger/make.py
#161 (comment)
:

 else:
  •    print(usage)
    
  •    build_octave()
    

This seems like it might be confusing. If someone enters a typo, it will
try to build the octave thing and emit a confusing error. How about:

elif args.target == 'octave':
build_octave
else:
e_s = "'%s' is not a valid target for building the messenger."%args.target
e_s = e_s + " Use 'matlab' or 'octave'"
raise ValueError(e_s)

Or something to that effect. Also, could you please rebase on master?
Thanks!


Reply to this email directly or view it on GitHub
https://github.com/arokem/python-matlab-bridge/pull/161/files#r26095797.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'll still change it though... it is your repo after all :)

On Mon, Mar 9, 2015 at 8:01 PM, Ali Ebrahim [email protected] wrote:

It won't let you choose another one because argparse limits the choices.

for example, running ./make.py foo will give:
usage: make.py [-h] [--static] {matlab,octave}
make.py: error: argument target: invalid choice: 'foo' (choose from
'matlab', 'octave')

On Mon, Mar 9, 2015 at 7:54 PM, Ariel Rokem [email protected]
wrote:

In messenger/make.py
#161 (comment)
:

 else:
  •    print(usage)
    
  •    build_octave()
    

This seems like it might be confusing. If someone enters a typo, it will
try to build the octave thing and emit a confusing error. How about:

elif args.target == 'octave':
build_octave
else:
e_s = "'%s' is not a valid target for building the messenger."%args.target
e_s = e_s + " Use 'matlab' or 'octave'"
raise ValueError(e_s)

Or something to that effect. Also, could you please rebase on master?
Thanks!


Reply to this email directly or view it on GitHub
https://github.com/arokem/python-matlab-bridge/pull/161/files#r26095797
.

Copy link
Owner

Choose a reason for hiding this comment

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

Gotcha. No need to change - I just really didn't know how that works. I see the whole thing above now. Cool. Thanks for doing this - much cleaner.

This commit also includs an updated messenger mex for windows 64 bit
which is statically linked against libzmq 4.0.5 (so it does not need to
be separately installed).

The make.py script for messenger has been updated to use argparse, and
also now supports linking to a statically linked zmq.
@aebrahim
Copy link
Contributor Author

Should be good to go

arokem added a commit that referenced this pull request Mar 10, 2015
fix messenger build on windows
@arokem arokem merged commit bbee5c7 into arokem:master Mar 10, 2015
@arokem
Copy link
Owner

arokem commented Mar 10, 2015

Thanks!

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