discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

recursion (by mistake) causes system lockup in 2014.12.30.nightly

J
jbeale
Wed, Dec 31, 2014 8:24 AM

Using Debian 7.7 x64, OpenSCAD 2014.12.30.nightly (git bebe084)

I made a simple typo which caused a module to reference itself, instead of
another module. There was a long string of "Error - recursion detected in
[x]" messages in the console pane, followed by a lot of disk activity (swap
space use?) and at that point the system was essentially locked up and I
could not close or quit the program; I had to reboot to escape.  It was my
fault for the unwanted recursion, but ideally I would not to have to reboot
to recover.  I've never tried to use recursion intentionally. Maybe there
could be a flag to turn the recursion feature off? Or is there already?

--
View this message in context: http://forum.openscad.org/recursion-by-mistake-causes-system-lockup-in-2014-12-30-nightly-tp10821.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

Using Debian 7.7 x64, OpenSCAD 2014.12.30.nightly (git bebe084) I made a simple typo which caused a module to reference itself, instead of another module. There was a long string of "Error - recursion detected in [x]" messages in the console pane, followed by a lot of disk activity (swap space use?) and at that point the system was essentially locked up and I could not close or quit the program; I had to reboot to escape. It was my fault for the unwanted recursion, but ideally I would not to have to reboot to recover. I've never tried to use recursion intentionally. Maybe there could be a flag to turn the recursion feature off? Or is there already? -- View this message in context: http://forum.openscad.org/recursion-by-mistake-causes-system-lockup-in-2014-12-30-nightly-tp10821.html Sent from the OpenSCAD mailing list archive at Nabble.com.
M
MichaelAtOz
Wed, Dec 31, 2014 9:22 AM

I've had similar on Windows, I set my swap space to a fixed amount (2GB),
thus when it is full OpenSCAD crashes, rather than the system hanging. Not
sure if that is possible on Linux.

Yes it should handle it properly, there have been some changes in this area
recently.


Unless specifically shown otherwise above, my contribution is in the Public Domain; To the extent possible under law, I have waived all copyright and related or neighbouring rights to this work. This work is published globally via the internet. :) Inclusion of works of previous authors is not included in the above.

The TPP is no simple “trade agreement.”  Fight it! http://www.ourfairdeal.org/

View this message in context: http://forum.openscad.org/recursion-by-mistake-causes-system-lockup-in-2014-12-30-nightly-tp10821p10822.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

I've had similar on Windows, I set my swap space to a fixed amount (2GB), thus when it is full OpenSCAD crashes, rather than the system hanging. Not sure if that is possible on Linux. Yes it should handle it properly, there have been some changes in this area recently. ----- Unless specifically shown otherwise above, my contribution is in the Public Domain; To the extent possible under law, I have waived all copyright and related or neighbouring rights to this work. This work is published globally via the internet. :) Inclusion of works of previous authors is not included in the above. The TPP is no simple “trade agreement.” Fight it! http://www.ourfairdeal.org/ -- View this message in context: http://forum.openscad.org/recursion-by-mistake-causes-system-lockup-in-2014-12-30-nightly-tp10821p10822.html Sent from the OpenSCAD mailing list archive at Nabble.com.
MK
Marius Kintel
Wed, Dec 31, 2014 5:19 PM

On Dec 31, 2014, at 03:24 AM, jbeale beale@bealecorner.com wrote:

There was a long string of "Error - recursion detected in
[x]" messages in the console pane, followed by a lot of disk activity (swap
space use?) and at that point the system was essentially locked up

This shouldn’t have been fixed. Could you provide an example .scad file so we can reproduce it and look into it?

-Marius

On Dec 31, 2014, at 03:24 AM, jbeale <beale@bealecorner.com> wrote: > There was a long string of "Error - recursion detected in > [x]" messages in the console pane, followed by a lot of disk activity (swap > space use?) and at that point the system was essentially locked up This shouldn’t have been fixed. Could you provide an example .scad file so we can reproduce it and look into it? -Marius
CL
Chow Loong Jin
Wed, Dec 31, 2014 5:26 PM

On Wed, Dec 31, 2014 at 01:24:47AM -0700, jbeale wrote:

Using Debian 7.7 x64, OpenSCAD 2014.12.30.nightly (git bebe084)

I made a simple typo which caused a module to reference itself, instead of
another module. There was a long string of "Error - recursion detected in
[x]" messages in the console pane, followed by a lot of disk activity (swap
space use?) and at that point the system was essentially locked up and I
could not close or quit the program; I had to reboot to escape.  It was my
fault for the unwanted recursion, but ideally I would not to have to reboot
to recover.  I've never tried to use recursion intentionally. Maybe there
could be a flag to turn the recursion feature off? Or is there already?

You don't have to reboot to recover. If your disk i/o is slow, you just have to
wait. It might be a long wait, though. :D

On the bright side, there are SysRq keys that can save you the wait:

Alt+SysRq+f: Trigger the OOM killer (Think Russian Roulette with a bias on
high-memory-consumption processes until OpenSCAD dies)

Alt+SysRq+k: Kill the entire TTY (Xorg and everything that depends on it,
including OpenSCAD).

--
Kind regards,
Loong Jin

On Wed, Dec 31, 2014 at 01:24:47AM -0700, jbeale wrote: > Using Debian 7.7 x64, OpenSCAD 2014.12.30.nightly (git bebe084) > > I made a simple typo which caused a module to reference itself, instead of > another module. There was a long string of "Error - recursion detected in > [x]" messages in the console pane, followed by a lot of disk activity (swap > space use?) and at that point the system was essentially locked up and I > could not close or quit the program; I had to reboot to escape. It was my > fault for the unwanted recursion, but ideally I would not to have to reboot > to recover. I've never tried to use recursion intentionally. Maybe there > could be a flag to turn the recursion feature off? Or is there already? You don't have to reboot to recover. If your disk i/o is slow, you just have to wait. It might be a long wait, though. :D On the bright side, there are SysRq keys that can save you the wait: Alt+SysRq+f: Trigger the OOM killer (Think Russian Roulette with a bias on high-memory-consumption processes until OpenSCAD dies) Alt+SysRq+k: Kill the entire TTY (Xorg and everything that depends on it, including OpenSCAD). -- Kind regards, Loong Jin