Oi Lucas

 

Está dando um erro, já tentei colocar esse código de várias formas, mas não 
funciona. 

O erro é o seguinte:

 

 

Traceback (innermost last):
  Module ZPublisher.Publish, line 119, in publish
  Module ZPublisher.mapply, line 88, in mapply
  Module ZPublisher.Publish, line 42, in call_object
  Module Shared.DC.Scripts.Bindings, line 313, in __call__
  Module Shared.DC.Scripts.Bindings, line 350, in _bindAndExec
  Module Products.PageTemplates.ZopePageTemplate, line 330, in _exec
  Module Products.PageTemplates.ZopePageTemplate, line 427, in pt_render
  Module Products.PageTemplates.PageTemplate, line 89, in pt_render
  Module zope.pagetemplate.pagetemplate, line 117, in pt_render
  Module zope.tal.talinterpreter, line 271, in __call__
  Module zope.tal.talinterpreter, line 346, in interpret
  Module zope.tal.talinterpreter, line 891, in do_useMacro
  Module zope.tal.talinterpreter, line 346, in interpret
  Module zope.tal.talinterpreter, line 536, in do_optTag_tal
  Module zope.tal.talinterpreter, line 521, in do_optTag
  Module zope.tal.talinterpreter, line 516, in no_tag
  Module zope.tal.talinterpreter, line 346, in interpret
  Module zope.tal.talinterpreter, line 949, in do_defineSlot
  Module zope.tal.talinterpreter, line 346, in interpret
  Module zope.tal.talinterpreter, line 891, in do_useMacro
  Module zope.tal.talinterpreter, line 346, in interpret
  Module zope.tal.talinterpreter, line 824, in do_loop_tal
  Module zope.tal.talinterpreter, line 346, in interpret
  Module zope.tal.talinterpreter, line 536, in do_optTag_tal
  Module zope.tal.talinterpreter, line 521, in do_optTag
  Module zope.tal.talinterpreter, line 516, in no_tag
  Module zope.tal.talinterpreter, line 346, in interpret
  Module zope.tal.talinterpreter, line 623, in do_insertText_tal
  Module Products.PageTemplates.Expressions, line 228, in evaluateText
  Module zope.tales.tales, line 696, in evaluate
   - URL: portlet_destaques
   - Line 39, Column 13
   - Expression: <PythonExpr obj.effective.strftime('%d-%m-%Y')>
   - Names:
      {'container': <PloneSite at / Plone >,
       'context': <PloneSite at / Plone >,
       'default': <object object at 0x0072A528>,
       'here': <PloneSite at /Plone>,
       'loop': {u'obj': <Products.PageTemplates.Expressions.PathIterator object 
at 0x1232B3D0>},
       'nothing': None,
       'options': {'args': ()},
       'repeat': <Products.PageTemplates.Expressions.SafeMapping object at 
0x121A39B8>,
       'request': <HTTPRequest, URL=http://localhost:8080/index_html>,
       'root': <Application at >,
       'template': <ZopePageTemplate at /index_html>,
       'traverse_subpath': [],
       'user': <PropertiedUser 'admin'>}
  Module Products.PageTemplates.ZRPythonExpr, line 49, in __call__
   - __traceback_info__: obj.effective.strftime('%d-%m-%Y')
  Module PythonExpr, line 1, in <expression>
  Module DateTime.DateTime, line 1494, in strftime
ValueError: year=1000 is before 1900; the datetime strftime() methods require 
year >= 1900

 

 

Responder a