Closed speckyspooky closed 6 months ago
I could reproduce the one problem which I tried to fix like this:
But I don't know if it's correct. I'm not sure where to look to see what might be impacted.
The other problem I can't reproduce. I can see the document provider being set:
Might the one problem cause the other somehow?
I thought the same fix to for the first option, but we have to check the effect on layout level, because at the version 4.14 be got directly position-values of that which are unequal 0.
The second issue is a good question. I will spend a little bit more time this evening.
I will try to help out where I can within my ability to understand the frameworks. Certain for the getProvider() NPE I see the explicit and implicit providers being set so can't see why they would be null except if there are things happening after a dispose call...
Update, with the last PR the Integer-cast-issue is solved but the document-provider issue is listed again together with another NullPointer:
java.lang.NullPointerException: Cannot invoke "org.eclipse.swt.widgets.Control.setMenu(org.eclipse.swt.widgets.Menu)" because the return value of "org.eclipse.ui.forms.editor.IFormPage.getPartControl()" is null
In this code where the NPE happens:
It checks if the getPartControl() is null and if so creates one:
So it's kind of inconceivable that it can be null right after that. This is very confusing.
With changed start configuration to start with the RCP-designer I got it reproduced locally.
I added the following line:
-product org.eclipse.birt.report.designer.ui.rcp.BIRT
But what is the difference to the all-in-one-designer that we got the issue(?)
Even doing that I don't see the problem:
Normally one chooses the product here:
I recall mentioning in the past that BIRT has quite a few products and I don't understand their purpose:
Only two of them are "published" but I don't think anyone every clarified their purpose.
Products are just different combinations of installed bundles...
Moreover, when I download and unzip the nightly build with the constraint NPE fix:
I also cannot reproduce the problem:
So I'm getting a bit suspicious about the nature of the problem. Might it be specific to the report you are opening?
It is not specific on my report because I have the effect also with "new report" which are created with that RCP-version.
@merks Your screen above doesn't show the RCP-designer with the example-report on screen 2. This is the "all-in-one"-designer. It is for comparison between both versions right(?) But for testing of the nightly-build it would be better to use the RCP-zip-version.
The idea was from my side a little bit, can we change the RCP-configuration to avoid the error without further impact on RCP. I have checked the BIRT.poduction-files yesterday evening but I couldn't figure out a specific config which would help.
I retested the nightly-build: https://www.eclipse.org/downloads/download.php?file=/birt/updates/nightly/N202403121254/downloads/birt-rcp-report-designer-4.15.0-202403121254-win32.win32.x86_64.zip
Result with the same error - attached the demo-report (a blank report): new_report.zip
Even with exactly that, I cannot reproduce the problem:
This product is in pretty bad shape in general though...
Hi Ed, to get the error you have to select the "XML Source"-tab. All other register works fine on my side.
Latest update on it: in some special cases I can get an empty "XML Source"-tab also with the all-in-one-designer.
@merks You are able to see the empty "XML Source"-tab? I started debugging of the source according to you and can see that the document-provider of the page-editor is null -> crash. But no idea why this happens with the new 2024-03 and under 2024-06 too.
@wimjongman What do you think about this issue. For my it is an eclipse-framework issue but we have the problem at designer level. Yes, it is no longer a "RELEASE BLOCKER" but it is very confusing that to have an empty "XML Source"-tab for the users. Have you an idea or should we accept the topic as Know-Bug for our release 4.15...?
The source tab works for me but the preview does not:
(These products are horribly defined with huge incomplete lists of bundles, i.e., if you say add required bundles it has more than 100, They are completely unmaintainable from my point of view.)
This new preview prototype should not be part of the release. It is incomplete.
The question is more the common situatione with the "XML Source"-tab and the situation we have with the latest eclipse-platform changes. Together with your eclipse experiences if we can go ahead with the milestone-release or we can do something to solve the topics.
The "new preview prototype tab" is visible since 4.14 (I don't know where this has activated).
I'm not sure the state of the progress here. I cannot reproduce the problem on Windows with the latest nightly build:
@speckyspooky
It's inexplicable to me that you can reproduce a problem with the same binary that I'm trying for which I cannot reproduce that problem...
I have retested the nightly build and I get the following result:
4.15-RCP (eclipse platform 2024-03): error 01: Tab "XML Source" shows no content error 02: Tab "Preview Prototpye" shows no content
4.15-All-In-One (eclipse platform 2024-03): error 02: Tab "Preview Prototpye" shows no content
BIRT-dev-local-eclipse-master (my development machine, eclipse platform 2024-06): error 01: Tab "XML Source" shows no content
The both errors for each tab every time the 2 same errors.
java.lang.NullPointerException: Cannot invoke "org.eclipse.ui.texteditor.IDocumentProvider.getDocument(Object)" because "provider" is null
java.lang.NullPointerException: Cannot invoke "org.eclipse.swt.widgets.Control.setMenu(org.eclipse.swt.widgets.Menu)" because the return value of "org.eclipse.ui.forms.editor.IFormPage.getPartControl()" is null
FYI, the Preview Prototype tab was broken because of a bundle missing from the product. In particular, this class
can't create a report viewer without the contribution from the other bundle. To me this looks like a problem that has existed for a long time...
This leaves the empty XML Source tab that I can reproduce nowhere and apparently no one else is testing anything to provide additional information about whether they can or cannot reproduce that problem. I can make no problem in a problem I cannot reproduce....
Hi Ed, for me it would be ok, to hide the "Preview Prototype" but I didn't know exactly where it can be hidden or remove. May be we can exclude it from the build-process.
And if nobody else has the issue with the "XML Source"-tab then it must be a special situation on my devices. So I have no problem if we have hidden the prototype to go ahead with the milestone.
Note that I fixed the problem with the prototype tab.
So both tabs work in the all-in-one from https://download.eclipse.org/birt/updates/nightly/N202403241246
And also for the other product:
I'll start another milestone build.
@wimjongman
It would be great if at least one other person can confirm that these things work for them.
@merks I have done the retest from my side.
The problem with the "New Preivew Prototype" is solved. Based on the nightly build All-In-One & RCP is fine!
The problem with the "XML Source"-tab is no longer reproducable on All-In-One. With the RCP-Version and a new created report directly from the nightly build I get again an empty "XML Source"-tab on MS Windows 11:
@wimjongman According to Ed, has you the option to make a check/test from your side with the RCP-version under Windows. May be it is really only a local topic on my device.
Your one comment about a "a new created reported" made me think what are all the ways to do that? Apparently there is a way to do that which doesn't involve creating a report in a project in the workspace but rather directly in the file system. which then uses a different mechanism to determine the document provider. In this case a ReportEditorInput is used as the editor's input, rather than IFileEditorInput, and that just isn't handled gracefully at all by the structure editor. Even if I try to hack in a document provider, the editor is not happy with that implementation (see error log warnings), though at least it shows some text:
This makes me really suspicious. So I tried this with the 4.14 release and I see both this problem and the design tab problem happen in the 4.14 release:
So indeed both these problem don't look new and in fact I am rather doubtful that either of these things worked correctly in the recent past, which makes me also wonder whether anyone actually normally cares.
I thought, perhaps you would appreciate some feedback. Unfortunately I can't contribute in programming a solution for this, but some spare time for a quick test was available.
I made a quick test with a simple new report containing a 3x3 grid with some labels, nothing fancy. I used
In AllInOne (1.) the XML source tab and the new preview prototype work for me. In RCP (2.) the new preview prototype works for me but the XML source tab is broken. I think it is the already known error (shortened stack trace for reference):
java.lang.NullPointerException: Cannot invoke "org.eclipse.ui.texteditor.IDocumentProvider.getDocument(Object)" because "provider" is null
at org.eclipse.ui.texteditor.MarkerRulerAction.getDocument(MarkerRulerAction.java:285)
at org.eclipse.ui.texteditor.MarkerRulerAction.update(MarkerRulerAction.java:199)
at org.eclipse.ui.texteditor.AbstractRulerActionDelegate.update(AbstractRulerActionDelegate.java:130)
...
When help is needed, I can test another version as well.
Thank @doortokaos your help is much appreciated.
I also ran it. Apologies for the low response but I am tied to a customer project.
I tested the RCP and it is broken in many places. We cannot take that thing seriously. I think we can just drop that from the build. See below for some other weirdness in that product.
The all-in-one works fantastic.
Thanks for fixing the preview Ed @merks.
If you ask me, you could scrap the RCP Designer entirely. I always used the AIO, since I have plugins the need parts of the "normal" eclipse, but that might be a special case. 🤷♂️
I really don't know why the RCP even exists. In the "old days" I understood, that the file is smaller, and it is more preconfigured. Filesize differs on the above used nightly builds by ~3 MB...
And concerning pre-configuration: I only noticed, that I have to choose a workspace manually in AIO, in RCP it is automatically chosen... Perhaps there are more differences, but at a first glance, they elude me.
But that's just my 2 cents...
FYI, I am removing the RCP product via this PR:
The RCP is now offline.
The rcp-designer version 4.15 milestone (Windows) is currently brooken according to #1588. The XML-source of a report isn't available (the page is gray) and there are NullPointerExceptions at the log-file. The problem of the reproducing is the same like #1588 only on the designer of master and my synced fork but not on my dev-env.
The NullPointers are:
Error 01
java.lang.NullPointerException: Cannot invoke "org.eclipse.ui.texteditor.IDocumentProvider.getDocument(Object)" because "provider" is null at org.eclipse.ui.texteditor.MarkerRulerAction.getDocument(MarkerRulerAction.java:285)
Error 02
java.lang.NullPointerException: Cannot invoke "java.lang.Integer.intValue()" because the return value of "org.eclipse.birt.report.designer.internal.ui.editors.rulers.EditorRulerLayout.getConstraint(org.eclipse.draw2d.IFigure)" is null at org.eclipse.birt.report.designer.internal.ui.editors.rulers.EditorRulerLayout.layout(EditorRulerLayout.java:57)
Log-File
log-2024-03-11.zip
XML-Source register