google-code-export / django-photologue

Automatically exported from code.google.com/p/django-photologue
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

PHOTOLOGUE_PATH only works for module.function and not package.module.function #144

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
In photologue, the PHOTOLOGUE_PATH setting only if for a single level 
(module.function), it does not work for multiple level 
(package.module.function) because __import__ is used.

Please check: http://www.python.org/doc/2.3.5/lib/built-in-funcs.html

Relevant part: "When the name variable is of the form package.module, 
normally, the top-level package (the name up till the first dot) is 
returned, not the module named by name."

The above link contains an example helper function that gets the correct 
module using a set of getattr() calls.

Original issue reported on code.google.com by william+g@shallum.net on 5 Dec 2009 at 1:21

GoogleCodeExporter commented 9 years ago
I too just ran around this issue during initial setup and made a quick fix on 
my server by using a symlink to the 
upload directory instead of the PHOTOLOGUE_PATH setting

Original comment by funkshun on 5 Dec 2009 at 6:53