Bug 896396

Summary: [abrt] picard-1.0-2.fc18: script.py:71:__init__:ScriptError: Wrong number of arguments for $if: Expected 2 - 3, got 1 at position 118, line 1
Product: [Fedora] Fedora Reporter: Dario Castellarin <req1348>
Component: picardAssignee: Alex Lancaster <alex>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 18CC: alex
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:f1683b161493d9138bb37ea9206a64d509e12f57
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-02-05 15:00:26 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
File: backtrace
none
File: core_backtrace
none
File: environ none

Description Dario Castellarin 2013-01-17 08:13:53 UTC
Description of problem:
I was modifying the file renaming string in the options

Version-Release number of selected component:
picard-1.0-2.fc18

Additional info:
cmdline:        /usr/bin/python /usr/bin/picard
executable:     /usr/bin/picard
kernel:         3.7.2-204.fc18.x86_64
uid:            1000

Truncated backtrace:
script.py:71:__init__:ScriptError: Wrong number of arguments for $if: Expected 2 - 3, got 1 at position 118, line 1

Traceback (most recent call last):
  File "/usr/lib64/python2.7/site-packages/picard/ui/options/renaming.py", line 90, in check_formats
    self.update_examples()
  File "/usr/lib64/python2.7/site-packages/picard/ui/options/renaming.py", line 118, in update_examples
    example1 = self._example_to_filename(self.example_1())
  File "/usr/lib64/python2.7/site-packages/picard/ui/options/renaming.py", line 107, in _example_to_filename
    filename = file._make_filename(file.filename, file.metadata, settings)
  File "/usr/lib64/python2.7/site-packages/picard/file.py", line 279, in _make_filename
    new_filename = self._script_to_filename(format, metadata, settings)
  File "/usr/lib64/python2.7/site-packages/picard/file.py", line 253, in _script_to_filename
    filename = ScriptParser().eval(format, metadata, self)
  File "/usr/lib64/python2.7/site-packages/picard/script.py", line 251, in eval
    ScriptParser._cache[key] = self.parse(script, True)
  File "/usr/lib64/python2.7/site-packages/picard/script.py", line 242, in parse
    return self.parse_expression(True)[0]
  File "/usr/lib64/python2.7/site-packages/picard/script.py", line 220, in parse_expression
    tokens.append(self.parse_function())
  File "/usr/lib64/python2.7/site-packages/picard/script.py", line 166, in parse_function
    return ScriptFunction(name, self.parse_arguments(), self)
  File "/usr/lib64/python2.7/site-packages/picard/script.py", line 71, in __init__
    parser._y))
ScriptError: Wrong number of arguments for $if: Expected 2 - 3, got 1 at position 118, line 1

Local variables in innermost frame:
expected_args: [2, 3]

Comment 1 Dario Castellarin 2013-01-17 08:13:57 UTC
Created attachment 680070 [details]
File: backtrace

Comment 2 Dario Castellarin 2013-01-17 08:13:59 UTC
Created attachment 680071 [details]
File: core_backtrace

Comment 3 Dario Castellarin 2013-01-17 08:14:02 UTC
Created attachment 680072 [details]
File: environ

Comment 4 Fedora End Of Life 2013-12-21 10:27:24 UTC
This message is a reminder that Fedora 18 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 18. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '18'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 18's end of life.

Thank you for reporting this issue and we are sorry that we may not be 
able to fix it before Fedora 18 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora, you are encouraged  change the 'version' to a later Fedora 
version prior to Fedora 18's end of life.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 5 Fedora End Of Life 2014-02-05 15:00:29 UTC
Fedora 18 changed to end-of-life (EOL) status on 2014-01-14. Fedora 18 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.