PrinterSetup crash on Linux

Maybe there is something else in dealing with the page setup that’s causing the burp.

What happens if you duplicate Peter’s very basic app from above rather than trying a complex app? Create a new Desktop app and put this in the Window.Open event:

Dim ps As New PrinterSetup If ps.PageSetupDialog Then break End If

Does that crash on the Pi?

[quote=474728:@Tim Jones]What happens if you duplicate Peter’s very basic app from above rather than trying a complex app? Create a new Desktop app and put this in the Window.Open event:
Does that crash on the Pi?[/quote]
Yup, it does. Of course :wink:
I know, hard to believe - but that’s what happens to Frank, me - and others.
If you want to see what I get to see - here’s a ScreenRecording.
You’ll see two DebugRun’s, and launching the built app via Terminal.
The PageSetup Dialog briefly flashes, then the app quits. No expection, no error reported - just silently quits (*).
Always. No matter how I set up the Pi4/Raspbian (in the ScreenRecording Raspbian is configured to German, but that doesn’t matter for this printing issue). Always reproducible. Just not for you or Xojo, which makes it difficult for them to reproduce-and-fix.
And the big mystery remains… what’s the difference causing this?

i in a production application, this of course may lead to data loss for the end-user - if there are unsaved changes when trying to print…[/i]

Okay - that means the issue is related to the generic setup of the PrinterSetup object. That’s a level that we can’t touch …

I wish that we could convince the Xojo team to actually remote-debug the IDE and their classes/objects using the remote debugger on one of the systems where the crash is consistent. That would allow them to catch the exceptions at a level that we don’t and can’t see.

One more thought, have any of you tried running the built app under strace?

strace -o myappcrash.strace myapp
We’ll then have the strace output that may provide info that hasn’t been seen as yet.

[quote=474728:@Tim Jones]Maybe there is something else in dealing with the page setup that’s causing the burp.

What happens if you duplicate Peter’s very basic app from above rather than trying a complex app? Create a new Desktop app and put this in the Window.Open event:

Dim ps As New PrinterSetup If ps.PageSetupDialog Then break End If

Does that crash on the Pi?[/quote]
That is exactly what I tested with all Xojo versions since 2015r3. Just this code snippet in Window.Open. Any attempt to open a printer dialog fails with 64-bits apps.

In order to make my old REALbasic apps work on Manjaro, I currently use Xojo2019r1.1 in 32bits mode. That works for now. Only drawback is that the HTMLViewer doesn’t work because lib32-webkitgtk fails to install on Arch/Manjaro (they dropped support for it some time ago).

[quote=474733:@Tim Jones]One more thought, have any of you tried running the built app under strace?

strace -o myappcrash.strace myapp

We’ll then have the strace output that may provide info that hasn’t been seen as yet.[/quote]
Here you are. Also added to <https://xojo.com/issue/58365>.
It ends with: +++ killed by SIGABRT +++

Same message here: +++ killed by SIGABRT (core dumped) +++ See strace file.

I may be one step closer to the problem, because briefly my app did not crash, which was when the network printer was listed but not recognized (does not respond to print requests), which happens when the printer goes in sleep mode for a longer period of time. When I manually wake the printer up and it is recognized again, the app crashes.

Note: app crashed also before a printer was installed.

is it n the liqt of supported Linux flavors ?

(I searched, but not found that list).

[quote=474800:@Emile Schwarz]is it n the liqt of supported Linux flavors ?

(I searched, but not found that list).[/quote]
I’m not sure if there is such a thing as supported linux flavours, but some may be recommended. If a software developer provides a tgz file it is worth a try, and in the case of Xojo, as long as all required GTK libraries are installed there shouldn’t be a reason for it not to work. Usually, most necessary libraries come with GTK based desktops such as XFCE, MATE, GNOME and Cinnamon. From what I have been able to test on Manjaro XFCE, Xojo and its compiled apps work just fine. There is just this problem with printer dialogs, which as it appears, happens on different systems, not just Arch/Manjaro.

There is a list of flavours that Xojo supports
http://documentation.xojo.com/resources/system_requirements_for_current_version.html

[quote=474834:@Norman Palardy]There is a list of flavours that Xojo supports
http://documentation.xojo.com/resources/system_requirements_for_current_version.html[/quote]
That list looks outdated. Unless Xojo 2019 still fully supports GTK 2 it won’t run (smoothly) on Debian 6. Those were the days of Real Studio 2012. But I’m curious to see if it would actually work, so perhaps I will run some tests on an older spare computer.

In any case, the list could be much larger. Xojo will probably run without problem on most Debian based systems. MX Linux would probably also do just fine and it is a very good one in my opinion. I already tested Manjaro. No problem either. I guess the list is what the Xojo developers have tested and what they know will work.

Dunno about how current that list is but thats Xojo’s statement about system requirements for the IDE and built apps
The things they “officially” support and test on/against

If it needs review then a feedback case to them is probably in order to get it updated

Good catch, @Frank Hoogerbeets!

On my Pi 4:

  • default install of latest Raspbian Buster, all updates applied
  • no printers configured
  • no Ethernet connected
  • WiFi is ON
    => Crash when-ever a Xojo built app tries to print (PageSetup Dialog, Printer Dialog, …)

Now…:

  • no Ethernet connected
  • WiFi is OFF
    => Printing works just fine! Dialog shows, I can print (to PDF).

So this is somehow related to the Network Environment/Setup… weird, but 100% reproducible (well, on those systems/machines that suffer from this xojo-print-crash issue).

[quote=474884:@Jürg Otter]So this is somehow related to the Network Environment/Setup… weird, but 100% reproducible (well, on those systems/machines that suffer from this xojo-print-crash issue).

[/quote]
And that MAY be the common element - all of my systems are running on Wired Ethernet.

My systems also have wired connections. No WiFi here. And even though my printer is network connected, it also happens when no printer is installed. The fact that no crash occurs when my printer is listed but seemingly offline, might be another clue.

Well, on my Pi 4, the crashes occur if either Ethernet or WLAN (or both) are connected. I’ve even set up Raspbian once with just Ethernet. Same effect - only when I have no network connection at all, the xojo built apps don’t crash when printing.

And what happens on your x64 machine if you pull out the Ethernet Cable, then launch the xojo built app?
Right, that’s close to “printer is offline”… it’s just that this also happens if there are no “network printers” configured - even then I only get the printer-dialogs when being totally offline… :frowning:

[quote=474942:@Jürg Otter]And what happens on your x64 machine if you pull out the Ethernet Cable, then launch the xojo built app?
Right, that’s close to “printer is offline”… it’s just that this also happens if there are no “network printers” configured - even then I only get the printer-dialogs when being totally offline… :([/quote]
I do not even have to pull out the cable. When I disconnect in Network Settings the app does NOT crash. After the network is enabled again the app crashes. This is 100% a network related bug on 64-bits systems.