Qwerty212 Posted April 4, 2022 Share Posted April 4, 2022 Hello from Barcelona. I've been doing some research and all that I can find is just the opposite of what I'm looking for. I've been asked to help a partner debug a looooooooooong script that crashes without showing any of the typical Autoit's error popups. I can not post the code here (more than 20.000 lines before stripping and I don't know if I'm allowed as it's a corporative program). I know that you don't have a crystal ball, but I would love to know if there's someone that has faced the same issue: a compiled script that just crashes without giving any error popup. I have searched for all the Exit calls in the code and before each of them there is a MsgBox with flag 262208 (one button, information icon, top-most attribute) but none of them is shown when the program crashes. Any hint or clue about how possibly a script could end without giving an error message would be truly appreciated. Link to comment Share on other sites More sharing options...
Trong Posted April 4, 2022 Share Posted April 4, 2022 Debug console line by line. Qwerty212 1 Regards, Link to comment Share on other sites More sharing options...
Qwerty212 Posted April 4, 2022 Author Share Posted April 4, 2022 38 minutes ago, VIP said: Debug console line by line. Thanks for the reply. I can not use the console as there are several compiled scripts and they transpond data between them. I've tried to make a kind of log creating files in a ramdisk (way faster than doing a filewritelog: Func _pseudolog($message) Local $now = @HOUR & "-" & @MIN & "-" & @SEC & "-" & @MSEC & " - " & $message & '.log' Local $hFile = _WinAPI_CreateFile($folder & $now, 1, 4, 0) _WinAPI_CloseHandle($hFile) EndFunc ;==>_pseudolog This way I can have some traceability, but I can not figure yet where the error is. The goal of this thread is more oriented in trying to know if there's someone that has experience on autoit crashing without poping up any error message. I've discarded antivir programs, also. One thing that happens a lot with these compiled scripts is that they have to perform Inireads and IniWrites several times in the same file. I don't know if trying to read/open an already in use .ini could lend to an error that leaves no trace. Once again, thanks for any clue or hint that you could provide. Link to comment Share on other sites More sharing options...
water Posted April 4, 2022 Share Posted April 4, 2022 I would at least log a message before and after each call to one of your compiled scripts. Qwerty212 1 My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki Link to comment Share on other sites More sharing options...
Qwerty212 Posted April 4, 2022 Author Share Posted April 4, 2022 30 minutes ago, water said: I would at least log a message before and after each call to one of your compiled scripts. Yeah, that’s what I’m trying to achieve with the pseudo log. The only way I think that Autoit can exit from running without showing an error is with an Exit call or with a ProcessClose from one of the other scripts (the Exit is going to be test tomorrow, the ProcessClose is discarded). Thanks for stopping by to give your opinion. Greets from Barcelona Link to comment Share on other sites More sharing options...
Danp2 Posted April 4, 2022 Share Posted April 4, 2022 Have you checked the Windows logs for any signs of the app exiting due to a crash? Qwerty212 1 Latest Webdriver UDF Release Webdriver Wiki FAQs Link to comment Share on other sites More sharing options...
water Posted April 4, 2022 Share Posted April 4, 2022 Can you log the result (return code) of every called script plus the return value of the main script? Qwerty212 1 My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki Link to comment Share on other sites More sharing options...
Qwerty212 Posted April 4, 2022 Author Share Posted April 4, 2022 18 minutes ago, water said: Can you log the result (return code) of every called script plus the return value of the main script? I’ll do a big test tomorrow. I’ve placed my pseudo log in each function call and in those that were called when the program crashes I have placed it at each step. so far the current pseudo log looks like this. I will add the psuedo log function in the other compiled scripts and not just in the main one. (I use this one instead of FileWriteLog because it’s faster) 22 minutes ago, Danp2 said: Have you checked the Windows logs for any signs of the app exiting due to a crash? Uops, I didn’t knew that there were such a Windows Log! I’m going to Google for some more info. Thanks for all the help. Good night Link to comment Share on other sites More sharing options...
Qwerty212 Posted April 5, 2022 Author Share Posted April 5, 2022 I've took a look at the Windows Event Viewer and when the main program has crashed, it has this info: Quote Nombre de registro:Application Origen: Application Error Fecha: 01/04/2022 17:08:29 Id. del evento:1000 Categoría de la tarea:(100) Nivel: Error Palabras clave:Clásico Usuario: No disponible Equipo: DESARROLLO Descripción: Nombre de la aplicación con errores: BONO.exe, versión: 2.2.4.201, marca de tiempo: 0x6247101c Nombre del módulo con errores: BONO.exe, versión: 2.2.4.201, marca de tiempo: 0x6247101cExeption Code: 0xc0000005 Desplazamiento de errores: 0x00051107 Identificador del proceso con errores: 0x52c4 Hora de inicio de la aplicación con errores: 0x01d845d735f8b5e7 Ruta de acceso de la aplicación con errores: D:\1 GUI Principal\BONO.exe Ruta de acceso del módulo con errores: D:\1 GUI Principal\BONO.exe Identificador del informe: 1c2d6719-1667-4f5d-86b7-f9bd9f79d215 Nombre completo del paquete con errores: Identificador de aplicación relativa del paquete con errores: XML de evento: <Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event"> <System> <Provider Name="Application Error" /> <EventID Qualifiers="0">1000</EventID> <Version>0</Version> <Level>2</Level> <Task>100</Task> <Opcode>0</Opcode> <Keywords>0x80000000000000</Keywords> <TimeCreated SystemTime="2022-04-01T15:08:29.0369281Z" /> <EventRecordID>22641</EventRecordID> <Correlation /> <Execution ProcessID="13484" ThreadID="0" /> <Channel>Application</Channel> <Computer>DESARROLLO</Computer> <Security /> </System> <EventData> <Data>BONO.exe</Data> <Data>2.2.4.201</Data> <Data>6247101c</Data> <Data>BONO.exe</Data> <Data>2.2.4.201</Data> <Data>6247101c</Data> <Data>c0000005</Data> <Data>00051107</Data> <Data>52c4</Data> <Data>01d845d735f8b5e7</Data> <Data>D:\1 GUI Principal\BONO.exe</Data> <Data>D:\1 GUI Principal\BONO.exe</Data> <Data>1c2d6719-1667-4f5d-86b7-f9bd9f79d215</Data> <Data> </Data> <Data> </Data> </EventData> </Event> Looking for some info on this 0xc0000005 I have seen that it's related to a memory problem. I'll have to insert more logs to check where does it fail exactly. Any hint or clue about this 0xc0000005 error would be really welcomed. Greets from Barcelona Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now