Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
cpg.root can't access cpg properties #116
Originally reported by: Anonymous
cpg.root is instantiated before the web server is started so cpg.foo is not available in the root class.
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 firstname.lastname@example.org
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.