Kas Ob. 121 Posted February 1 1 hour ago, PeterPanettone said: If i to read this right, then the exception was not here at all, and this one is a nested one, in other words this one is raised while handing a previous (and original) exception. Also the stack is cut !, where is the rest of it ? does this dialog have more text without scroll bars ? or this is it ? Also would you please try to track the actual disk operations with Process Monitor ? in other words, were there a successful/failure File Write operations right before this dialog ? Share this post Link to post
Uwe Raabe 2057 Posted February 1 56 minutes ago, PeterPanettone said: This faulty behavior occurs only if MMX is loaded AND with the "MainProgramWindowManager" unit! (If both conditions are NOT met, clicking the SAVE button turns the SAVE-ALL icon grey: Checked and re-checked just now). That is probably caused by the IDE or whatever catching the failing assertion during save of that unit. While MMX logs such an assertion it should nevertheless popup. 1 hour ago, PeterPanettone said: This points to the same error from the previous MMX error message dialog (EAssertionFailed in CustomPascalExplorer.pas), thus proving that MMX prevents the project from being compiled or built. I have uploaded a new beta catching this assertion and writing it to CodeSite. So if you reproducibly get that exception now, you should get a CodeSite message with the new beta - unless the underlying object instance is no longer valid, which would move the spot to a completely different source location. What puzzles me is that this assertion failure nor any other exception is not logged to CodeSite. After all the MMX beta hooks into AssertErrorProc as well as Application.OnException. Can you disable the JCL exception handler as well as any other ones interfering with MMX here - at least for the time needed to investigate this? Share this post Link to post
PeterPanettone 157 Posted February 1 46 minutes ago, Uwe Raabe said: I have uploaded a new beta catching this assertion and writing it to CodeSite. Thank you. I downloaded and installed the new beta: When loading my project in the IDE, CodeSite Live Viewer received these messages: What conclusions can you draw from this? Share this post Link to post
Uwe Raabe 2057 Posted February 1 4 minutes ago, PeterPanettone said: What conclusions can you draw from this? At least that gives me a hint where I can look at now. Stay tuned... Share this post Link to post
Uwe Raabe 2057 Posted February 1 @PeterPanettone Can you please try again with the latest beta 2597? If that doesn't show the problem I will provide a new release. Share this post Link to post
PeterPanettone 157 Posted February 1 After having closed the Obsidium unit still opened in the IDE from the Obsidium Sample folder, now, when SAVING the "MainProgramWindowManager" unit, these are the CodeSite messages: Please note the new "Invalid class typecast" message that occurs while saving. Share this post Link to post
PeterPanettone 157 Posted February 1 2 minutes ago, Uwe Raabe said: Can you please try again with the latest beta 2597? If that doesn't show the problem I will provide a new release. I will download and install beta 2597 in a second. Share this post Link to post
PeterPanettone 157 Posted February 1 I downloaded and installed beta 2597: There are a lot of CodeSite messages now. I have compressed them here: messages from beta 2597.zip Share this post Link to post
Uwe Raabe 2057 Posted February 1 Those are expected in the beta reminding me to create a test case for this. The functionality (f.i. regarding the Save All) should be ok now. Share this post Link to post
Kas Ob. 121 Posted February 1 May i suggest this alternated code from Remy (i hope with his permission) https://stackoverflow.com/questions/39584234/how-to-obtain-rtti-from-an-interface-reference-in-delphi type ITest1 = interface ['{5AB029F5-31B0-4054-A70D-75BF8278716E}'] procedure Test1; end; ITest2 = interface ['{AAC18D39-465B-4706-9DC8-7B1FBCC05B2B}'] procedure Test1; end; TTest = class(TInterfacedObject, ITest1, ITest2) public procedure Test1; procedure Test2; end; procedure TTest.Test1; begin //... end; procedure TTest.Test2; begin //... end; function GetInterfacesFromItsObj(AIntf: IInterface): string; var obj: TObject; IntfType: TRttiInterfaceType; ctx: TRttiContext; tmpIntf: IInterface; begin obj := AIntf as TObject; Result := 'Object: (' + obj.ClassName + ')_ -> : '; for IntfType in (ctx.GetType(obj.ClassType) as TRttiInstanceType).GetImplementedInterfaces do begin if obj.GetInterface(IntfType.GUID, tmpIntf) then begin Result := Result {+ 'Intf: '} + IntfType.Name + ', '; tmpIntf := nil; end; end; end; procedure TForm10.FormCreate(Sender: TObject); var Intf1: ITest1; Intf2: ITest2; begin Intf1 := TTest.Create as ITest1; Intf2 := TTest.Create as ITest2; ShowMessage(GetInterfacesFromItsObj(Intf1)); end; The result Share this post Link to post
Uwe Raabe 2057 Posted February 1 11 minutes ago, Kas Ob. said: May i suggest this alternated code from Remy Wrong thread? Share this post Link to post
Kas Ob. 121 Posted February 1 Just now, Uwe Raabe said: Wrong thread? I am sorry ! I thought putting such interfaces resolver in the exception handler for failed "as" casting could show log better information about the missed interface implementation hence the failed casting. Share this post Link to post
Uwe Raabe 2057 Posted February 1 Thanks, but interfaces are not even involved in the code in question. 1 Share this post Link to post
PeterPanettone 157 Posted February 1 35 minutes ago, Uwe Raabe said: The functionality (f.i. regarding the Save All) should be ok now. You are right - there are no more error messages when saving MainProgramWindowManager in beta 2597 now, and the behavior of the save icons is OK now! And I can compile/build my project after changes now! Thank you! Will you publish a new MMX release now (without the CodeSite debug messages)? Share this post Link to post
PeterPanettone 157 Posted February 1 4 minutes ago, Uwe Raabe said: A new version V15.1.9 is available. Thanks! Sorry, my latest posting came one second too late. Share this post Link to post
PeterPanettone 157 Posted February 1 (edited) Downloaded and installed V15.1.9 Release. Everything is fine now. Thanks again, Uwe! MMX takes 47 seconds to load: Is that normal? Edited February 1 by PeterPanettone Share this post Link to post
PeterPanettone 157 Posted February 1 (edited) BTW - when I ever get a living from the apps I create, I will donate to MMX, GExperts ... and all the other real benefactors of humanity. Edited February 1 by PeterPanettone Share this post Link to post
Uwe Raabe 2057 Posted February 1 3 hours ago, PeterPanettone said: Is that normal? Looks like a bit much. It depends on the number of design time packages. Anyway, it should not have changed unless you installed a bunch of new ones. There already exists a feature request to move that into a thread. 1 Share this post Link to post
PeterPanettone 157 Posted February 1 46 minutes ago, Uwe Raabe said: There already exists a feature request to move that into a thread. Good idea! Share this post Link to post
Ian Branch 127 Posted February 1 Well done to Uwe, Peter, & any others, for seeing this issue through. Ian Share this post Link to post