[TxMt] Re: Failure running “Typeset & View (PDF)” in LaTex
René Schwaiger
sanssecours at f-m.fm
Wed Sep 16 10:27:09 UTC 2015
Hi Riki,
> On 16 Sep 2015, at 11:16 , riki <riki80 at rediffmail.com> wrote:
>
> Many thanks to René & Allan for your kind help!!
>
> The warning has been suppressed as per Allan's advice.
> I installed `pip install PyObjC` and installation directory is 'anaconda' in my home directory.
> I have Python 3.4 and still I am getting the same error.
>
> Earlier I had many files in '/Library/Python/2.7/site-packages' directory and I think those were come by macport installation. I
> have removed all macport files including '/opt/local' directory. Now the '/Library/Python/2.7/site-packages' directory is empty.
> I
> checked the uninstallation script file, there are many files having name pyobjc:
> yes | pip uninstall pyobjc-core==2.5.1
> yes | pip uninstall pyobjc-framework-Accounts==2.5.1
> yes | pip uninstall pyobjc-framework-AddressBook==2.5.1
> yes | pip uninstall pyobjc-framework-AppleScriptKit==2.5.1
> yes | pip uninstall pyobjc-framework-AppleScriptObjC==2.5.1
> yes | pip uninstall pyobjc-framework-Automator==2.5.1
> yes | pip uninstall pyobjc-framework-CFNetwork==2.5.1
> yes | pip uninstall pyobjc-framework-Cocoa==2.5.1
> yes | pip uninstall pyobjc-framework-Collaboration==2.5.1
> yes | pip uninstall pyobjc-framework-CoreData==2.5.1
> yes | pip uninstall pyobjc-framework-CoreLocation==2.5.1
> yes | pip uninstall pyobjc-framework-CoreText==2.5.1
> yes | pip uninstall pyobjc-framework-DictionaryServices==2.5.1
> yes | pip uninstall pyobjc-framework-EventKit==2.5.1
> yes | pip uninstall pyobjc-framework-ExceptionHandling==2.5.1
> yes | pip uninstall pyobjc-framework-FSEvents==2.5.1
> yes | pip uninstall pyobjc-framework-InputMethodKit==2.5.1
> yes | pip uninstall pyobjc-framework-InstallerPlugins==2.5.1
> yes | pip uninstall pyobjc-framework-InstantMessage==2.5.1
> yes | pip uninstall pyobjc-framework-LatentSemanticMapping==2.5.1
> yes | pip uninstall pyobjc-framework-LaunchServices==2.5.1
> yes | pip uninstall pyobjc-framework-Message==2.5.1
> yes | pip uninstall pyobjc-framework-OpenDirectory==2.5.1
> yes | pip uninstall pyobjc-framework-PreferencePanes==2.5.1
> yes | pip uninstall pyobjc-framework-PubSub==2.5.1
> yes | pip uninstall pyobjc-framework-QTKit==2.5.1
> yes | pip uninstall pyobjc-framework-Quartz==2.5.1
> yes | pip uninstall pyobjc-framework-ScreenSaver==2.5.1
> yes | pip uninstall pyobjc-framework-ScriptingBridge==2.5.1
> yes | pip uninstall pyobjc-framework-SearchKit==2.5.1
> yes | pip uninstall pyobjc-framework-ServiceManagement==2.5.1
> yes | pip uninstall pyobjc-framework-Social==2.5.1
> yes | pip uninstall pyobjc-framework-SyncServices==2.5.1
> yes | pip uninstall pyobjc-framework-SystemConfiguration==2.5.1
> yes | pip uninstall pyobjc-framework-WebKit==2.5.1
>
> I also tried by Apple's preinstalled 'PyObjC'. I exported python 2.6 system directory in my bash profile.
> $ export PYTHONPATH="/System/Library/Frameworks/Python.framework/Versions/2.6/Extras/lib/python/"
as far as I know TextMate does not read environment variables that you export via your bash profile. If you want to use environment variables inside TextMate, then you can for example set them via “TextMate→Preferences…→Variables”.
> $ python
> Python 2.7.10 (default, Jul 14 2015, 19:46:27)
> [GCC 4.2.1 Compatible Apple LLVM 6.0 (clang-600.0.39)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import Foundation
> >>>
> It means python recognizes “PyObjC”. Here again I am getting the same error in TexMate. I exported python 2.6 because some
> 'PyObC' files are missing in python 2.7 system directory.
“Typeset & View (PDF)” always uses `/usr/bin/python` [1]. The reason for this is simple. `/usr/bin/python` is — by default — the location of the Python interpreter supplied by Apple. This means we can make some assumptions:
• The interpreter version is at least 2.7 (We do not support Python 2.6 [2])
• „PyObjC” and other standard libraries are installed
[1]: https://github.com/textmate/latex.tmbundle/blob/master/Support/bin/texmate.py#L1
[2]: http://textmate.1073791.n5.nabble.com/Failure-running-Typeset-amp-View-PDF-td29100.html
You need to make sure that “PyObjC” is installed for whatever version of Python `/usr/bin/python` links to. Hope this helps.
> Best Regards,
> Riki
Kind regards,
René
More information about the textmate
mailing list