[Checkins] SVN: Grokstar/trunk/ Make Grokstar compatible with Grok 0.11.1, thanks to Robert Marianski

Martijn Faassen faassen at infrae.com
Mon Jan 21 09:09:27 EST 2008


Log message for revision 83061:
  Make Grokstar compatible with Grok 0.11.1, thanks to Robert Marianski
  

Changed:
  U   Grokstar/trunk/buildout.cfg
  U   Grokstar/trunk/src/grokstar/blog.py
  U   Grokstar/trunk/src/grokstar/workflow.py

-=-
Modified: Grokstar/trunk/buildout.cfg
===================================================================
--- Grokstar/trunk/buildout.cfg	2008-01-21 14:00:45 UTC (rev 83060)
+++ Grokstar/trunk/buildout.cfg	2008-01-21 14:09:26 UTC (rev 83061)
@@ -1,6 +1,10 @@
 [buildout]
 develop = .
-parts = app data zopectl test
+parts = app data zopectl i18n test
+find-links = http://download.zope.org/distribution/
+newest = false
+extends= http://grok.zope.org/releaseinfo/grok-0.11.1.cfg
+versions = versions
 
 [data]
 recipe = zc.recipe.filestorage
@@ -11,6 +15,7 @@
 site.zcml = <include package="grokstar" />
             <include package="zope.app.twisted" />
 
+            <configure i18n_domain="grokstar">
             <unauthenticatedPrincipal id="zope.anybody"
                                       title="Unauthenticated User" />
             <unauthenticatedGroup id="zope.Anybody"
@@ -38,7 +43,12 @@
             <grantAll role="zope.Manager" />
             <grant role="zope.Manager"
                    principal="zope.manager" />
+           </configure>
 
+[data]
+recipe = zc.recipe.filestorage
+
+# this section named so that the start/stop script is called bin/zopectl
 [zopectl]
 recipe = zc.zope3recipes:instance
 application = app
@@ -46,5 +56,13 @@
 
 [test]
 recipe = zc.recipe.testrunner
-eggs = grok
+eggs = Grokstar
 defaults = ['--tests-pattern', '^f?tests$', '-v']
+
+# this section named so that the i18n scripts are called bin/i18n...
+[i18n]
+recipe = lovely.recipe:i18n
+package = grokstar
+domain = grokstar
+location = src/grokstar
+output = locales

Modified: Grokstar/trunk/src/grokstar/blog.py
===================================================================
--- Grokstar/trunk/src/grokstar/blog.py	2008-01-21 14:00:45 UTC (rev 83060)
+++ Grokstar/trunk/src/grokstar/blog.py	2008-01-21 14:09:26 UTC (rev 83061)
@@ -50,18 +50,9 @@
 class Breadcrumbs(grok.View):
     grok.context(Interface)
     def parents(self):
-        pl = getParents(self.context)
-        return pl
-        obj = self.context
-        while obj is not None:
-            pl.append(obj)
-            if isinstance(obj, grok.Application):
-                break
-            obj = obj.__parent__
-        pl.reverse()
-        return pl
-    
-        
+        return getParents(self.context)
+
+
 class Entries(grok.Container):
     pass
 

Modified: Grokstar/trunk/src/grokstar/workflow.py
===================================================================
--- Grokstar/trunk/src/grokstar/workflow.py	2008-01-21 14:00:45 UTC (rev 83060)
+++ Grokstar/trunk/src/grokstar/workflow.py	2008-01-21 14:09:26 UTC (rev 83061)
@@ -4,6 +4,8 @@
 from grokstar.entry import Entry
 from hurry.workflow import workflow
 from hurry.workflow.interfaces import IWorkflow
+from hurry.workflow.interfaces import IWorkflowState
+from hurry.workflow.interfaces import IWorkflowInfo
 from hurry.query.query import Query
 from hurry.query import Eq
 
@@ -66,7 +68,9 @@
     
 class WorkflowState(grok.Adapter, workflow.WorkflowState):
     grok.context(Entry)
+    grok.provides(IWorkflowState)
     
 class WorkflowInfo(grok.Adapter, workflow.WorkflowInfo):
     grok.context(Entry)
+    grok.provides(IWorkflowInfo)
 



More information about the Checkins mailing list