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

transform.local.command property of transform set to homebrew's python bin directory #43

Open
johannestaas opened this issue Feb 27, 2015 · 1 comment

Comments

@johannestaas
Copy link

We've noticed an interesting issue generating an mtz with canari create-profile $package in the environment of a machine that uses homebrew python on OSX.

I use OSX Python and the transform.local.command property of my transforms correctly points to /usr/local/bin/dispatcher.

However, a peer uses homebrew Python 2.7.9 and their transform.local.command property gets set to:
/usr/local/Cellar/python/2.7.9/Frameworks/Python.framework/Versions/2.7/bin/dispatcher

His is actually installed in /usr/local/bin/dispatcher .

Which, doesn't exist, so all attempts to run the transform fail with "No file or directory" in maltego. This can be worked around by editing the property of the transforms in Manage Transforms in maltego.

I believe the related code might be at src/canari/pkgutils/maltego.py:

        transform_settings_def = TransformSettings(properties=[                 
            CmdLineTransformPropertySetting(                                    
                os.path.join(get_bin_dir(),                                     
                             'dispatcher.bat' if os.name == 'nt' else 'dispatcher')
            ),                                                                  
            CmdParmTransformPropertySetting(name),                              
            CmdCwdTransformPropertySetting(working_dir),                        
            CmdDbgTransformPropertySetting(spec.debug)                          
        ])        
@ropdor
Copy link

ropdor commented May 7, 2015

I am seeing something similar, though on linux, using a custom setuptools config (i.e. install-scripts set in .pydistutils.cfg) that installs to personal directories. So far I've narrowed it down to setuptools not taking into account my config when returning the install_scripts location though not sure if the way get_bin_dir calls setuptools to get that variable is the ultimate cause

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