Modify

Opened 15 years ago

Closed 9 years ago

#5768 closed defect (wontfix)

Tickets still shown all custom fields

Reported by: webmaster@… Owned by:
Priority: highest Component: CondFieldsPlugin
Severity: normal Keywords:
Cc: Ryan J Ollos Trac Release: 0.11

Description

hey, i want to use that feature but it doesnt work for me :-(

i downloaded the zip-file. compiled the source and done the easy_install with the egg-file.

i activated the plugin and made some test in the adminmenu for the condfields example in trac.ini:

[condfields]
feature = blocking blocked_by, summary, type,
include_standard = true
requirement = id, type
task = totalhours, blocking

but if i want to create for example a new task all of my custom fields were shown...

the trac log shows:

2009-09-02 12:39:08,316 Trac[web_ui] INFO: version: 0.11 - id: $Id$
2009-09-02 12:39:08,413 Trac[main] ERROR: Internal Server Error:
Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/web/main.py", line 435, in _dispatch_request
    dispatcher.dispatch(req)
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/web/main.py", line 227, in dispatch
    data, content_type)
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/web/chrome.py", line 707, in render_template
    template = self.load_template(filename, method=method)
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/web/chrome.py", line 691, in load_template
    return self.templates.load(filename, cls=cls)
  File "build/bdist.linux-i686/egg/genshi/template/loader.py", line 237, in load
    raise TemplateNotFound(filename, search_path)
TemplateNotFound: Template "condfields.js" not found

where should the condfields.js template should be? a 'find / -name condfields.js' just showed me the plugin-install-folder, where i unzipped the source, compiled and installed the egg...

any hints to solve my issue?

Attachments (0)

Change History (14)

comment:1 in reply to:  description Changed 15 years ago by anonymous

of course i have tried include_standard = false but id didnt work too

comment:2 Changed 15 years ago by matthew.jenkin@…

I've been having this problem too tried placing the js file from the source into the htdocs directory but this didn't seem to help.

comment:3 Changed 15 years ago by Ryan J Ollos

Cc: Ryan J Ollos added; anonymous removed

comment:4 in reply to:  3 Changed 15 years ago by anonymous

Replying to rjollos:

Place it in the templates directory, not the htdocs directory.

comment:5 Changed 15 years ago by webmaster@…

hmm, so i need to copy that template into the template folder of every project???? I have more than 40 projects on my server... why it is not used as a global template?

comment:6 in reply to:  5 Changed 15 years ago by anonymous

Replying to webmaster@meneke.de:

hmm, so i need to copy that template into the template folder of every project???? I have more than 40 projects on my server... why it is not used as a global template?

I put it in the main trac template directory. It got me past this issue but I still haven't gotten it to work completely with trac0.11.5 - very frustrating!

comment:7 Changed 15 years ago by anonymous

i had the problem that the priority was shown twice... if i submitted the ticket with the doubled shown prio i got the error message 'Multi-values fields not supported yet' therefore i edited the web_ui.py and took out the priority in the forced_fields (line 23)

but i have to set include_standard = false... otherwise the prio is shown twice again... i dont know yet where that came from...

what is directly your problem? we have a test system where 11.5 is running... maybe i can reproduce your failure?

comment:8 Changed 15 years ago by anonymous

i can't make it work with trac-0.11.5 either,here is the error information

2009-10-27 20:55:00,437 Trac[main] ERROR: Internal Server Error: 
Traceback (most recent call last):
  File "C:\Python26\lib\site-packages\trac-0.11.5-py2.6-win32.egg\trac\web\main.py", line 444, in _dispatch_request
    dispatcher.dispatch(req)
  File "C:\Python26\lib\site-packages\trac-0.11.5-py2.6-win32.egg\trac\web\main.py", line 226, in dispatch
    data, content_type)
  File "C:\Python26\lib\site-packages\trac-0.11.5-py2.6-win32.egg\trac\web\chrome.py", line 730, in render_template
    template = self.load_template(filename, method=method)
  File "C:\Python26\lib\site-packages\trac-0.11.5-py2.6-win32.egg\trac\web\chrome.py", line 704, in load_template
    return self.templates.load(filename, cls=cls)
  File "C:\Python26\lib\site-packages\genshi\template\loader.py", line 227, in load
    filename, encoding=encoding)
  File "C:\Python26\lib\site-packages\genshi\template\loader.py", line 265, in _instantiate
    allow_exec=self.allow_exec)
  File "C:\Python26\lib\site-packages\genshi\template\base.py", line 379, in __init__
    raise TemplateSyntaxError(e.msg, self.filepath, e.lineno, e.offset)
TemplateSyntaxError: syntax error: line 1, column 0 (d:\workspace\localsite\templates\condfields.js, line 1)

comment:9 Changed 15 years ago by Curtis Ide

I just replicated the problem.

comment:10 Changed 15 years ago by Henri

Problem reproduced on:

    Trac: 0.11.5
    Python: 2.6.4 (r264:75708, Oct 26 2009, 08:23:19) [MSC v.1500 32 bit (Intel)]
    setuptools: 0.6c11
    SQLite: 3.6.11
    pysqlite: 2.5.5
    Genshi: 0.5.1
    CustomFieldAdmin: 0.2.2
    jQuery:1.2.6
    OS: WinXP SP3
Debug/Error:
2009-11-03 12:16:19,515 Trac[main] DEBUG: Dispatching <Request "GET u'/condfield
s/new.js'">
2009-11-03 12:16:19,515 Trac[web_ui] DEBUG: ['summary', 'reporter', 'description
', 'type', 'status', 'priority', 'milestone', 'component', 'version', 'resolutio
n', 'keywords', 'owner', 'cc', 'pb_marketing', 'pb_technical']
2009-11-03 12:16:19,515 Trac[web_ui] INFO: set(['status', 'description', 'report
er', 'cc', 'resolution', 'component', 'summary', 'priority', 'keywords', 'versio
n', 'milestone', 'owner', 'type'])
2009-11-03 12:16:19,515 Trac[main] ERROR: Internal Server Error:
Traceback (most recent call last):
  File "D:\Documents and Settings\Python\lib\site-packages\trac-0.11.5-py2.6.egg
\trac\web\main.py", line 444, in _dispatch_request
    dispatcher.dispatch(req)
  File "D:\Documents and Settings\Python\lib\site-packages\trac-0.11.5-py2.6.egg
\trac\web\main.py", line 226, in dispatch
    data, content_type)
  File "D:\Documents and Settings\Python\lib\site-packages\trac-0.11.5-py2.6.egg
\trac\web\chrome.py", line 730, in render_template
    template = self.load_template(filename, method=method)
  File "D:\Documents and Settings\Python\lib\site-packages\trac-0.11.5-py2.6.egg
\trac\web\chrome.py", line 704, in load_template
    return self.templates.load(filename, cls=cls)
  File "D:\Documents and Settings\Python\lib\site-packages\genshi\template\loade
r.py", line 227, in load
    filename, encoding=encoding)
  File "D:\Documents and Settings\Python\lib\site-packages\genshi\template\loade
r.py", line 265, in _instantiate
    allow_exec=self.allow_exec)
  File "D:\Documents and Settings\Python\lib\site-packages\genshi\template\base.
py", line 379, in __init__
    raise TemplateSyntaxError(e.msg, self.filepath, e.lineno, e.offset)
TemplateSyntaxError: syntax error: line 1, column 0 (d:\tractest\templates\condf
ields.js, line 1)
2009-11-03 12:16:19,530 Trac[chrome] DEBUG: Prepare chrome data for request

comment:11 Changed 15 years ago by Henri

Priority: highhighest

See for temporary but working solution ticket #5515. I have got it working.

If developer is able to remove the Priority field from a template 'out-of-my-understanding' then the quick and dirty fix in templates\condfields.js is not needed. Still this field Priority should be handled as a normal conditional field. Type should always be a fixed field.

The Text/Plain solution from #5515 is acceptable I think but should be added to the package as a configuration setting checking Genshi version.

comment:12 Changed 14 years ago by anonymous

Yo he conseguido solucionarlo copiando el fichero condfieldsplugin/0.11/condfields/templates/condfields.js dentro del patch /usr/lib/python2.4/site-packages/Trac-0.11.2.1-py2.4.egg/trac/htdocs/js

saludos

comment:13 Changed 10 years ago by Ryan J Ollos

Owner: Noah Kantrowitz deleted

comment:14 Changed 9 years ago by Ryan J Ollos

Resolution: wontfix
Status: newclosed

CondFieldsPlugin is deprecated. Please see notice on CondFieldsPlugin and use DynamicFieldsPlugin instead. If you have any issues creating an equivalent configuration with DynamicFieldsPlugin, please ask for help on the trac:MailingList.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The ticket will remain with no owner.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


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

 
Note: See TracTickets for help on using tickets.