Option to stop and recompile
Disclaimer
Please make sure all the items below is checked (i.e., prefixed with "- [x]")
- [x] The request feature has not been addressed in the feature request list.
- [x] The design of the feature does not require detailed discussion, or existing discussion with drawn conclusion can be found in Discussions Area at: [paste the link here]
Motivation
Please give strong enough reason(s) why the feature is demanded.
- When there are no errors in the latex files, the compilation process may continue infinitely, and no output is presented.
Feature Description
A clear and concise description of what you want to happen under what circumstance.
- Can we have an option to stop and recompile?
[Optional] Additional context
Please strike out any inappropriate items below. If you are not aware of the difference, please ignore this section.
- Applicable Overleaf Edition: Official / Community / Enterprise (Server Pro)
- Applicable Extension Range: Desktop Extension / Web Extension
When there are no errors in the latex files, the compilation process may continue infinitely, and no output is presented.
I don't get the point. If there is no error, the compile should compile and then stop with success.
Can we have an option to stop and recompile?
We cannot actually stop compiling but stop waiting for the compiling results. I think we should firstly identify why the compile status not update and wait indefinitely.
I think it may be related to something like network issues. I have to refresh the login to get the right compilation results.
I think it may be related to something like network issues. I have to refresh the login to get the right compilation results.
In that case, we have nothing to do with the indefinite waiting.
I, too, have noticed the infinite compilation time several times. But I could never pinpoint to why that is happening or reliably replicate it. Do you think that's a problem with pdflatex?
Now we need someone know how to stable reproduce the situation.
In fact, when compiling a project, we do have a button for stoping or recompile it from scratch. And I dont think the network is lost since edition is synced when infinite compilation happens.
In fact, when compiling a project, we do have a button for stoping or recompile it from scratch. And I dont think the network is lost since edition is synced when infinite compilation happens.
I see, but I still would like to know when it would fail.
As for "stop compilation in middle", I can add a function to the compile spin icon: when you click the icon, the waiting icon will immediately become error/warning icon so you can trigger another compile.
I see, but I still would like to know when it would fail.
As for "stop compilation in middle", I can add a function to the compile spin icon: when you click the icon, the waiting icon will immediately become error/warning icon so you can trigger another compile.
I am also curious. How can I inspect what is going on when infinite compilation happens?
I want to know it, too. But it rarely happens and only happened to me when my brain was in writing mode. If we can find a way to replicate it, it will be great
I see, but I still would like to know when it would fail. As for "stop compilation in middle", I can add a function to the compile spin icon: when you click the icon, the waiting icon will immediately become error/warning icon so you can trigger another compile.
I am also curious. How can I inspect what is going on when infinite compilation happens?
Please check if there is anything printed in developer log.
Please find the logs via: Title bar "Help" > "Toggle Developer Tools" > "Console".
Well, I encountered the same issue recently. I will try to figure out and fix it.
Update 2: recompile may stuck in the loop of "failure", still in fixing ... (make any changes and then compile will return "success") "overleaf/services/clsi/app/js/CompileController.js#L85-L91":
...
} else {
status = 'failure'
logger.warn(
{ projectId: request.project_id, outputFiles },
'project failed to compile successfully, no output.pdf generated'
)
}
...
Update 1: found the uncaught error
mainThreadExtensionService.ts:79 FetchError: request to http://.../compile?auto_compile=true failed, reason: socket hang up
...
at ClientRequest.emit (node:events:531:35)
at Socket.socketOnEnd (node:_http_client:524:9)
at Socket.emit (node:events:531:35)
at endReadableNT (node:internal/streams/readable:1696:12)
at processTicksAndRejections (node:internal/process/task_queues:82:21)
Got it. Let me know what you find out.
I speculate the following is the reason. Press compile > press save > Linux kernel writes to disk // latex concurrently compiles
If the write to disk happens to be a tad bit slower than usual, the latex will be trying to compile a file that's empty or in some unstable state. Just a speculation. Let's see
Hi guys, I have tried to figure out one possible reason for indefinite waiting, and also add the choice to stop waiting for compilation.
Please try the temporary extension here: https://github.com/iamhyc/Overleaf-Workshop/actions/runs/10299610784?pr=171
One known issue with the temporary extension: It may keep returning "compile failed" when compiling a complex project continuously without any changes. The only solution now is to make some changes, save it, and then apply the compilation.
Thanks for the new feature! Were you able to find the reason why the infinite compile time happens?
Thanks for the new feature! Were you able to find the reason why the infinite compile time happens?
Hi @pramodhrachuri , you can refer to my previous update. It should be due to an uncaught error raised by node-fetch module, while calling compile api too many times.