View Issue Details

IDProjectCategoryView StatusLast Update
0007704ScribusScripterpublic2015-11-23 20:05
ReporteraliB Assigned ToKunda  
PrioritynormalSeveritycrashReproducibilityalways
Status closedResolutionunable to reproduce 
PlatformDell Inspiron 9400OSSuSEOS Version10.3
Product Version1.3.5svn 
Target VersionFixed in Version 
Summary0007704: Unhandled exceptions in CalendarWizard.py script may cause freeze
Descriptionshape1 = createRect(self.marginl, self.margint+5, self.width, 30, monthName)
setFillColor("White", shape1)
setFillTransparency(30, shape1)

Execute these lines and scribus never comes back
Uncomment setFillTransparency and everything is just fine.
TagsNo tags attached.
Patch

Relationships

related to 0012627 confirmed [OSX] calendarWizard leads to an endless loop 
related to 0008634 assignedcbradney [OSX] calendarwizard script language and date selection menu problems 

Activities

jghali

2009-01-04 22:30

administrator   ~0020869

Cannot reproduce a crash, just a cursor display issue. Otherwise transparency must be between 0.0 and 1.0

cbradney

2009-01-09 21:44

administrator   ~0020900

if ((w < 0.0) || (w > 1.0))
{
    PyErr_SetString(PyExc_ValueError, QObject::tr("Transparency out of bounds, must be 0 <= transparency <= 1.","python error").toLocal8Bit().constData());
    return NULL;
}

The code checks for the bounds.. so is there another way to produce this?

subik

2009-01-18 08:06

manager   ~0020932

cannot reproduce it too.

setFillTransparency works without any freeze and/or cursor issue.

 aliB : can you test it with fresh svn, please?

subik

2009-01-27 12:11

manager   ~0021008

aliB, can you retest it, please?

aliB

2009-01-27 21:38

reporter   ~0021014

Ok, I found the time to make some more tests.
Scribus only freezes when you call the script using the menu "execute script"
But then it freezes with every wrong call of a function. (e.g setFillATypoXY(10,Image) )

Tested with build C-C-T-F-C1.8.0 from 17.01.09

subik

2009-01-28 08:12

manager   ~0021017

this is strange.
I'm running this script (from console to see printouts):

from scribus import *

print 'step 1'
shape1 = createRect(100, 100, 100, 30, 'frame1')
print 'step 2'
setFillColor("White", shape1)
print 'step 3'
setFillTransparency(30, shape1)
print 'step 4'

There is no freeze at all. Just the correct error message in scribus popup dialog:

Traceback (most recent call last):
  File "<string>", line 8, in <module>
  File "/home/subzero/scribus/transparency.py", line 8, in <module>
    setFillTransparency(30, shape1)
ValueError: Transparency out of bounds, must be 0 <= transparency <= 1.

It must be something else.
Can you run it with debugger and/or strace, please?
What is Python version in suse 10.3? And what is Qt version?

subik

2009-01-28 08:13

manager   ~0021018

BTW can you run something in Python console?
And can you run any of "Scribus Scripts" (font sampler, calendar wizard...)

aliB

2009-01-28 18:47

reporter   ~0021035

I'll try to write and upload a samplescript this weekend.
All Scribus Scripts work well.

2009-01-30 20:54

 

CalendarWizard.py (21,523 bytes)

aliB

2009-01-30 20:58

reporter   ~0021048

I copied the CalendarWizard script and inserted a call of setFillTransparency() with a type (setFillTranspar_a_ncy).
Run the script from Scribus using the "execute script" menu entry.
Options to set:
Classic calender
select 1 month
-> ok
make the other settings (page, style name ...) and see scribus freeze...

jghali

2009-01-30 21:05

administrator   ~0021049

Still unable to reproduce

aliB

2009-01-30 22:33

reporter   ~0021050

Starting scribus from console:
Exception in Tkinter callback
Traceback (most recent call last):
  File "/usr/lib/python2.6/lib-tk/Tkinter.py", line 1410, in __call__
    return self.func(*args)
  File "/home/aliB/CalendarWizard.py", line 511, in okButonn_pressed
    err = cal.createCalendar()
  File "/home/aliB/CalendarWizard.py", line 227, in createCalendar
    self.createMonthCalendar(i)
  File "/home/aliB/CalendarWizard.py", line 323, in createMonthCalendar
    setFillTransparancy(0.5, cel)
NameError: global name 'setFillTransparancy' is not defined

Maybe it is just a problem of mine if nobody can reproduce.

jghali

2009-02-01 20:10

administrator   ~0021063

I finally managed to reproduce the problem. It seems to be related to unhandled exceptions in scripts. In such case the function we use to run the script, Py_RunString, may not return without an additional Ctrl+C...

Kunda

2014-09-11 22:11

manager   ~0033627

per MRB, this won't make it in to 1.5.0 release. bumping to 1.5.1

gpittman

2015-11-21 15:24

developer   ~0037573

As far as I know, CalendarWizard should now be working.
I have checked it recently and found no issues on 1.5.1svn, Fedora 21.

owencook

2015-11-22 00:04

reporter   ~0037580

I have checked with the latest SUSE, Leap and there were no problems

Kunda

2015-11-22 22:36

manager   ~0037593

per the responses from gpittman and owencook, I am resolving this issue.

Issue History

Date Modified Username Field Change
2009-01-04 21:57 aliB New Issue
2009-01-04 22:30 jghali Note Added: 0020869
2009-01-09 21:44 cbradney Note Added: 0020900
2009-01-18 08:06 subik Note Added: 0020932
2009-01-27 12:11 subik Note Added: 0021008
2009-01-27 12:11 subik Status new => feedback
2009-01-27 21:38 aliB Note Added: 0021014
2009-01-28 08:12 subik Note Added: 0021017
2009-01-28 08:13 subik Note Added: 0021018
2009-01-28 18:47 aliB Note Added: 0021035
2009-01-30 20:54 aliB File Added: CalendarWizard.py
2009-01-30 20:58 aliB Note Added: 0021048
2009-01-30 21:05 jghali Note Added: 0021049
2009-01-30 22:33 aliB Note Added: 0021050
2009-02-01 20:10 jghali Note Added: 0021063
2009-02-01 20:13 jghali Summary calling setFillTransparency makes scribus crash => Unhandled exceptions in script may cause freeze
2009-02-01 20:13 jghali Status feedback => confirmed
2014-09-11 02:47 Kunda Severity crash => block
2014-09-11 22:11 Kunda Note Added: 0033627
2014-09-11 22:11 Kunda Severity block => crash
2014-09-11 22:11 Kunda Target Version => 1.5.1
2014-09-11 22:34 Kunda Target Version 1.5.1 =>
2014-10-09 02:02 Kunda Relationship added related to 0012627
2014-10-09 02:03 Kunda Relationship added related to 0008634
2014-10-09 02:03 Kunda Summary Unhandled exceptions in script may cause freeze => Unhandled exceptions in CalendarWizard.py script may cause freeze
2015-11-21 15:24 gpittman Note Added: 0037573
2015-11-22 00:04 owencook Note Added: 0037580
2015-11-22 22:36 Kunda Note Added: 0037593
2015-11-22 22:36 Kunda Status confirmed => resolved
2015-11-22 22:36 Kunda Resolution open => unable to reproduce
2015-11-22 22:36 Kunda Assigned To => Kunda
2015-11-23 20:05 Kunda Status resolved => closed