Modify

Opened 6 years ago

Closed 6 years ago

Last modified 6 years ago

#3782 closed defect (fixed)

build error "invalid syntax"

Reported by: sromanow@… Owned by: scratcher
Priority: normal Component: KeywordSuggestPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description

Received the following output while building plugin.

copying build/lib/keywordsuggest/keywordsuggest.py -> build/bdist.linux-i686/egg/keywordsuggest
byte-compiling build/bdist.linux-i686/egg/keywordsuggest/__init__.py to __init__.pyc
byte-compiling build/bdist.linux-i686/egg/keywordsuggest/keywordsuggest.py to keywordsuggest.pyc
  File "build/bdist.linux-i686/egg/keywordsuggest/keywordsuggest.py", line 27
    if self.config.getbool('keywordsuggest','mustmatch') else ""
     ^
SyntaxError: invalid syntax
creating build/bdist.linux-i686/egg/EGG-INFO
copying TracKeywordSuggest.egg-info/PKG-INFO -> build/bdist.linux-i686/egg/EGG-INFO

Attachments (2)

keywordsuggest.py (2.3 KB) - added by scratcher 6 years ago.
update with unix-style EOLs
keywordsuggest2.py (2.3 KB) - added by scratcher 6 years ago.
version without Python ternary operator

Download all attachments as: .zip

Change History (7)

Changed 6 years ago by scratcher

update with unix-style EOLs

comment:1 Changed 6 years ago by scratcher

  • Status changed from new to assigned

Hello! I can build sources out of trac-hacks SVN on my windows machine without any errors. Attached file contains Unix style EOLs. May be this help. Can you please check it?

Changed 6 years ago by scratcher

version without Python ternary operator

comment:2 in reply to: ↑ description ; follow-up: Changed 6 years ago by scratcher

SyntaxError: invalid syntax

Please also check your Python interpreter version. Such error may be caused by lack of ternary logical operator in Python versions prior to 2.5. Attached keywordsuggest2.py have no ternary operators in it. Let me know if it helps. Thanks!

comment:3 in reply to: ↑ 2 ; follow-up: Changed 6 years ago by anonymous

Replying to scratcher:

SyntaxError: invalid syntax

Please also check your Python interpreter version. Such error may be caused by lack of ternary logical operator in Python versions prior to 2.5. Attached keywordsuggest2.py have no ternary operators in it. Let me know if it helps. Thanks!

The version without ternary operators built with no error on my rhel 5.2 box. I am using python 2.4.

On a side note, I didn't install jquery yet. Not sure how I could implement this plugin rollout in our environment with client machines all over the country. Am I reading this correctly that JQuery Autocomplete is a separately distributed library?

comment:4 in reply to: ↑ 3 Changed 6 years ago by scratcher

  • Resolution set to fixed
  • Status changed from assigned to closed

On a side note, I didn't install jquery yet. Not sure how I could implement this plugin rollout in our environment with client machines all over the country. Am I reading this correctly that JQuery Autocomplete is a separately distributed library?

jQuery itself is a part of Trac distribution (at least in 0.11). jQuery Autocomplete is a plugin for jQuery, included into KeywordSuggestPlugin and does not require additional actions to install - it is installed automatically together with KeywordSuggestPlugin plugin.

comment:5 Changed 6 years ago by scratcher

Fixed in [4325].

Add Comment

Modify Ticket

Action
as closed The owner will remain scratcher.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.