New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cpg.root can't access cpg properties #116

Closed
bb-migration opened this Issue Feb 24, 2005 · 1 comment

Comments

Projects
None yet
1 participant
@bb-migration

bb-migration commented Feb 24, 2005

Originally reported by: Anonymous


cpg.root is instantiated before the web server is started so cpg.foo is not available in the root class.
I noticed this when I subclassed my root class from csauthenticate and made some stuff in my version of csauthenticate try to access cpg.configOption.sessionCookieName in it's init.

It seems that the structure of CP2 should be changed so that the root class is passed to cp when the server is started so it can be instantiated later on after things are set up around it.

Reported by mischko chappie@mischko.com


@bb-migration

This comment has been minimized.

Show comment
Hide comment
@bb-migration

bb-migration May 20, 2005

Original comment by Anonymous:


If I understand this correctly, it can be solved by the application code itself. Simply call cpg.server.start before binding cpg.root. There's nothing in the core that relies on cpg.root being populated before the server starts. The only miniscule issue is that someone could request a page in the microsecond between the two calls, and be rejected.

bb-migration commented May 20, 2005

Original comment by Anonymous:


If I understand this correctly, it can be solved by the application code itself. Simply call cpg.server.start before binding cpg.root. There's nothing in the core that relies on cpg.root being populated before the server starts. The only miniscule issue is that someone could request a page in the microsecond between the two calls, and be rejected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment