# line, it's possible required libraries won't be in your searchable path
#
-sys.path.append(os.path.join(os.path.dirname(os.path.abspath(__file__)), 'wcs'))
+BASE_WCS_DIR = os.path.join(os.path.dirname(os.path.abspath(__file__)), 'wcs')
+sys.path.append(BASE_WCS_DIR)
+if os.path.exists(os.path.join(BASE_WCS_DIR, 'data/vendor/effective_tld_names.dat')):
+ # remove that file to get full domaine name in cookies
+ os.unlink(os.path.join(BASE_WCS_DIR, 'data/vendor/effective_tld_names.dat'))
from wcs import publisher
from wcs.qommon.http_request import HTTPRequest
return result
publisher.WcsPublisher.APP_DIR = os.environ.get('OPENSHIFT_DATA_DIR', '/tmp/')
-publisher.WcsPublisher.DATA_DIR = os.path.join(
- os.path.dirname(os.path.abspath(__file__)), 'wcs', 'data')
+publisher.WcsPublisher.DATA_DIR = os.path.join(BASE_WCS_DIR, 'data')
pub = publisher.WcsPublisher.create_publisher(register_cron=False)
application = QWIP(pub)