tgapp-calendarevents, tgext-pluggable woes

19 views
Skip to first unread message

zov...@gmail.com

unread,
Mar 15, 2016, 10:07:51 AM3/15/16
to TurboGears
Hi,

I am looking for calendar of events to use with Turbogears. My first try was with tw2.jqplugins.fullcalendar but couldn't make it work with Turbogears.
My next try was with tgapp-calendarevents and Turbogears 2.3.7. It looks like tgext.pluggable does not work with TG 2.3.7 (with activated virtualenv and installed tgext.pluggable I got "ImportError: No module named pluggable" trying to import tgext.pluggable.plug).
Then I created virtualenv with TG 2.3.1 and was succesful installing tgext.pluggable and tgapp-calendarevents. The problem I am having now is that tables for calendarevents do not get created (or get created somewhere where i can't find them, I did run gearbox setup-app after plugging in calendarevents) and I'm getting after starting the app:

File "/home/user/src/turbogears/2.3.1/lib/python2.7/site-packages/testcalendar-0.1dev-py2.7.egg/testcalendar/controllers/error.py", line 28, in document
code=request.params.get('code', resp.status_int),

AttributeError: 'NoneType' object has no attribute 'status_int'


What am I doing wrong?

Any help would be greatly appreciated.

Ernest

Alessandro Molina

unread,
Mar 15, 2016, 10:18:03 AM3/15/16
to TurboGears
How are you plugging things?

It looks to me that calendarevents is plugging and creating models properly on TG-2.3.8:

$ gearbox quickstart caltest
Creating directory caltest
$ cd caltest/
$ vim caltest/config/app_cfg.py 

    from tgext.pluggable import plug
    plug(base_config, 'calendarevents')

$ gearbox setup-app -c development.ini 
15:14:59,424 INFO  [tgext.pluggable] Plugging calendarevents
Running setup_app() from caltest.websetup
Creating tables
Initializing Migrations
Bootstrapping calendarevents...

$ echo .schema calendarevents_event | sqlite3 devdata.db 
CREATE TABLE calendarevents_event (
uid INTEGER NOT NULL, 
name VARCHAR(255) NOT NULL, 
summary VARCHAR(1024), 
datetime DATETIME NOT NULL, 
end_time DATETIME, 
location VARCHAR(255) NOT NULL, 
active BOOLEAN, 
calendar_id INTEGER NOT NULL, 
linked_entity_id INTEGER NOT NULL, 
linked_entity_type VARCHAR(255) NOT NULL, 
PRIMARY KEY (uid), 
CHECK (active IN (0, 1)), 
FOREIGN KEY(calendar_id) REFERENCES calendarevents_calendar (uid)
);



--
You received this message because you are subscribed to the Google Groups "TurboGears" group.
To unsubscribe from this group and stop receiving emails from it, send an email to turbogears+...@googlegroups.com.
To post to this group, send email to turbo...@googlegroups.com.
Visit this group at https://groups.google.com/group/turbogears.
For more options, visit https://groups.google.com/d/optout.

zov...@gmail.com

unread,
Mar 23, 2016, 10:05:11 AM3/23/16
to TurboGears
Hi again,

It was kind of strange, with freshly quickstarted project, versions 2.3.7 and 2.3.8 everything worked fine but with my previously quickstarted project in another virtualenv it did not work no matter what.
Thanks a lot for your help, I am working on integration of tgapp-calendarevents with my application now.

Ernest
Reply all
Reply to author
Forward
0 new messages