diff --git a/lib/python/App/Product.py b/lib/python/App/Product.py index 477ca90fbba449462b154835fd89b7954eec848b..13f9edd8512f8eed465b1371b16b726191f8cde2 100644 --- a/lib/python/App/Product.py +++ b/lib/python/App/Product.py @@ -470,7 +470,8 @@ def initializeProduct(productp, name, home, app): {'label':'README', 'action':'manage_readme'}, ) - if os.environ.get('ZEO_CLIENT',''): + if (os.environ.get('ZEO_CLIENT') and + not os.environ.get('FORCE_PRODUCT_LOAD')): get_transaction().abort() return product diff --git a/lib/python/OFS/Application.py b/lib/python/OFS/Application.py index 6542c85aa7b1a5d48ae87383363327dc0703f849..3ba6018c0e49f4e781493b378d24113acae92e42 100644 --- a/lib/python/OFS/Application.py +++ b/lib/python/OFS/Application.py @@ -85,8 +85,8 @@ __doc__='''Application support -$Id: Application.py,v 1.139 2001/01/19 20:19:36 brian Exp $''' -__version__='$Revision: 1.139 $'[11:-2] +$Id: Application.py,v 1.140 2001/01/25 21:48:50 chrism Exp $''' +__version__='$Revision: 1.140 $'[11:-2] import Globals,Folder,os,sys,App.Product, App.ProductRegistry, misc_ import time, traceback, os, string, Products @@ -443,8 +443,10 @@ def initialize(app): install_products(app) # Note that the code from here on only runs if we are not a ZEO - # client. - if os.environ.get('ZEO_CLIENT',''): + # client, or if we are a ZEO client and we've specified by way + # of env variable that we want to force products to load. + if (os.environ.get('ZEO_CLIENT') and + not os.environ.get('FORCE_PRODUCT_LOAD')): return # Check for dangling pointers (broken zclass dependencies) in the @@ -667,8 +669,10 @@ def install_products(app): Folder.__dict__['__ac_permissions__']=tuple( list(Folder.__ac_permissions__)+new_permissions) - if os.environ.get('ZEO_CLIENT',''): - # we don't want to install products from clients! + if (os.environ.get('ZEO_CLIENT') and + not os.environ.get('FORCE_PRODUCT_LOAD')): + # we don't want to install products from clients + # (unless FORCE_PRODUCT_LOAD is defined). get_transaction().abort() else: get_transaction().note('Installed product '+product_name)