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

Failure running "Typeset & View (PDF)" #62

Closed
lpellegr opened this issue Oct 24, 2013 · 12 comments
Closed

Failure running "Typeset & View (PDF)" #62

lpellegr opened this issue Oct 24, 2013 · 12 comments

Comments

@lpellegr
Copy link

Since I have upgraded to OS X Mavericks I get the following message when I try to visualize a PDF file in Textmate 2 after I have compiled a latex document with the CMD-R shortcut.

Typeset & View (PDF):23:in `exit': no implicit conversion from nil to integer 
(TypeError) from Typeset & View (PDF):23

I have tried to revert the default settings as explained in [1] but the issue still remains.

[1] https://github.com/textmate/textmate/wiki/Reverting-To-Defaults

@infininight
Copy link
Member

You say visualizing the PDF after compiling, is the PDF generated successfully?

Also did you install MacTeX before or after updating to Mavericks? I'm wondering if the update could have messed up one of the Latex bits. I searched and found a reference to a X11 related bug after updating but I don't think that would affect this.

@cfrauenberger
Copy link

Same here, but without Mavericks, just upgrading to Textmate 2 on OSX 1.8.5 (and reverting to default settings).

I found that the pdf is actually generated, so it is a matter of telling textmate to display it. I tried looking into the bundle preferences, but then saw that those were broken - deprecation warning in configure.py (os.popen4) - does anyone know what is going on here?

Thanks!

@lpellegr
Copy link
Author

@infininight yes, the PDF is generated with success. MacTex was installed before upgrading to Mavericks.

The textmate version I am using is 2.0-alpha.9489.

I have enclosed the dialog that is opened when I click on the "Edit Command" button from the dialog where the failure is displayed.

screen shot 2013-10-24 at 12 33 00

@cfrauenberger
Copy link

@lpellegr does your bundle preferences pane come up? (Latex -> Preferences or alt+cmd+,)

@lpellegr
Copy link
Author

@cfabric yes it is displayed and the configuration seems ok.

@sorbits
Copy link
Member

sorbits commented Oct 24, 2013

From the error message, it would seem like the texMate.py script either
hasn’t exited or failed to launch, but if the latter, then there
should be no PDF, and if the former, well… we wait() for it…

That it is a new problem is likely due to
0a707c3 which had the problematic line
commented.

A fix could be to change the last line to:

 ::Process.exit($?.exited? ? $?.exitstatus : 0)

Or possibly just:

 ::Process.exit($?.exitstatus || 0)

But it would be good to know why there is no exit status for you guys
(it works for me on 10.8.5 and @infininight on 10.9).

On 24 Oct 2013, at 12:27, cfabric wrote:

Same here, but without Mavericks, just upgrading to Textmate 2 on OSX
1.8.5 (and reverting to default settings).

I found that the pdf is actually generated, so it is a matter of
telling textmate to display it. I tried looking into the bundle
preferences, but then saw that those were broken - deprecation warning
in configuration.py - does anyone know what is going on here?

Thanks!


Reply to this email directly or view it on GitHub:
#62 (comment)

@plalteaugal
Copy link

Allan, Should Latex Bundle users wait until this is sorted out to install Mavericks? Many of us will need hand holding if we have to change scripts.

@sorbits
Copy link
Member

sorbits commented Oct 24, 2013

I don’t think it has anything to do with Mavericks per se, given that some see it on 10.8 and @infininight is not seeing it on Mavericks.

If someone has the issue and are comfortable editing bundle items then please apply the proposed fix and report back if it works, then we can push that.

On Oct 24, 2013, at 17:38, plalteaugal notifications@github.com wrote:

Allan, Should Latex Bundle users wait until this is sorted out to install Mavericks? Many of us will need hand holding if we have to change scripts.


Reply to this email directly or view it on GitHub.

@lpellegr
Copy link
Author

@sorbits Both solutions work. Thanks!

@lpellegr
Copy link
Author

I have tried to debug a bit but I am not familiar with the ruby syntax.

I have added the following line before the exit line you proposed:

File.open("/path/to/file", 'w') { |file| file.write("$?.exited?=" + $?.exited?.to_s + ", $?.exitstatus=" + $?.exitstatus.inspect + ", $?.inspect"+$?.inspect) }

After I execute I get:

$?.exited?=false, $?.exitstatus=nil, $?.inspect#<Process::Status: pid=27664,signaled(SIGINT=2)>

There is no exitstatus because the process has exited abnormally. I haven't time to go deeper but I post just in case, it could maybe help.

@sorbits
Copy link
Member

sorbits commented Oct 24, 2013

Thanks, that is indeed useful: Something must be sending the process SIGINT. I’ll go through the other code to see if I can figure out why that might be.

On Oct 24, 2013, at 18:02, Laurent Pellegrino notifications@github.com wrote:

I have tried to debug a bit but I am not familiar with the ruby syntax.

I have added the following line before the exit line you proposed:

File.open("/path/to/file", 'w') { |file| file.write("$?.exited?=" + $?.exited?.to_s + ", $?.exitstatus=" + $?.exitstatus.inspect + ", $?.inspect"+$?.inspect) }

After I execute I get:

$?.exited?=false, $?.exitstatus=nil, $?.inspect#<Process::Status: pid=27664,signaled(SIGINT=2)>

Thus, there is not exitstatus because the process has exited abnormally. I haven't time to go deeper but I post just in case it could help.


Reply to this email directly or view it on GitHub.

@svidela
Copy link

svidela commented Oct 24, 2013

Hi,

I found the same issue and my fix was:

::Process.exit(($?.exitstatus).to_i)

Regards,

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

6 participants