Forum OpenACS Q&A: New Survey Package imported into CVS

Collapse
Posted by Dave Bauer on
A new survey package has been added to OpenACS 4 CVS. It is called
survey. There is support for Oracle and Postgresql. The postgresql
version could
use a little more testing, but should be fine. I tried to keep up the
postgresql version while developing the oracle version. I wanted to
get the code into CVS so people could start working with it.

It is a clean up of the simple-survey module with an improved user
interface and added features. Thanks to MIT/Sloan for funding the
development of this package.

Survey should probably replace simple-survey. I am not sure how to
write a script to upgrade to a different version of a different, but
similar package but if anyone needs this I am sure I can help out
working on a conversion.

If anyone has any questions feel free to contact me on the bboard or
by email.

Collapse
Posted by Dave Bauer on
I forgot to mention the survey package was developed with Musea Technologies. Luke Pond and myself will be maintaining the package.
Collapse
Posted by Stan Kaufman on
Dave, I got this error during the install:

Installing data model for Survey 0.1d... 
              Loading data model /var/web/epimetrics-dev/packages/survey/sql/postgresql/survey-create.sql... 

                    CREATE
                     inline_0 
                    ----------
                            0
                    (1 row)
                    DROP
                    BEGIN
                    DROP
                     acs_privilege__add_child 
                    --------------------------
                                            0
                    (1 row)
                     acs_privilege__add_child 
                    --------------------------
                                            0
                    (1 row)
                     acs_privilege__add_child 
                    --------------------------
                                            0
                    (1 row)
                     acs_privilege__add_child 
                    --------------------------
                                            0
                    (1 row)
                     acs_privilege__add_child 
                    --------------------------
                                            0
                    (1 row)
                     acs_privilege__add_child 
                    --------------------------
                                            0
                    (1 row)
                     acs_privilege__add_child 
                    --------------------------
                                            0
                    (1 row)
                    CREATE
                     acs_privilege__add_child 
                    --------------------------
                                            0
                    (1 row)
                    COMMIT
                    CREATE
                     inline_1 
                    ----------
                            0
                    (1 row)
                    DROP
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    CREATE
                    HTTP/1.0 200 OK
                    Server: AOLserver/3.3.1+ad13
                    Content-Type: text/html; charset=iso-8859-1
                    MIME-Version: 1.0
                    Date: Mon, 16 Sep 2002 02:20:38 GMT
                    Content-Length: 3565
                    Connection: close







                    Request Error


                            
                           psql:survey-create.sql:258: ERROR:  Relation "survey_question_responses" does not exist
                           psql:survey-create.sql:259: ERROR:  Relation "survey_question_responses" does not exist
                           psql:survey-create.sql:260: ERROR:  Relation "survey_question_responses" does not exist
                           psql:survey-create.sql:276: ERROR:  Function 'survey_response__initial_respon(int4)' does not exist
                                   Unable to identify a function that satisfies the given argument types
                                   You may need to add explicit typecasts
                           psql:survey-create.sql:314: ERROR:  parser: parse error at or near "view"

                               invoked from within
                           "db_source_sql_file -callback $callback $path/$file_path"
                               (procedure "apm_package_install_data_model" line 32)
                               invoked from within
                           "apm_package_install_data_model -callback $callback -data_model_files $data_model_files $spec_file_path"
                               (procedure "apm_package_install" line 19)
                               invoked from within
                           "apm_package_install -install_path $install_path  -callback apm_ns_write_callback -load_data_model  -data_model_files $data_model_files $spec_file"
                               ("foreach" body line 36)
                               invoked from within
                           "foreach pkg_info $pkg_install_list {
                               set spec_file [pkg_info_spec $pkg_info]
                               if { [catch {
                                   array set version [apm_read_package_info_file $spe..."
                               ("uplevel" body line 34)
                               invoked from within
                           "uplevel {
                                     ad_page_contract {

                               Installs the packages.

                               @author Bryan Quinn (bquinn@arsdigita.com)
                               @creation-date Mon Oct  9 00:22:31..."
                               (procedure "code::tcl::/var/web/epimetrics-dev/packages/acs-admin/www/ap..." line 2)
                               invoked from within
                           "code::tcl::$__adp_stub"
                               invoked from within
                           "if { [file exists $__adp_stub.tcl] } {

                                 # ensure that data source preparation procedure exists and is up-to-date
                                 adp_init tcl $__adp_stub
                           ..."
                               ("uplevel" body line 3)
                               invoked from within
                           "uplevel {

                               if { [file exists $__adp_stub.tcl] } {

                                 # ensure that data source preparation procedure exists and is up-to-date
                                 adp_init t..."
                               (procedure "adp_prepare" line 2)
                               invoked from within
                           "adp_prepare "
                               (procedure "template::adp_parse" line 30)
                               invoked from within
                           "template::adp_parse [file root [ad_conn file]] {}"
                               (procedure "adp_parse_ad_conn_file" line 7)
                               invoked from within
                           "$handler"
                               ("uplevel" body line 2)
                               invoked from within
                           "uplevel $code"
                               invoked from within
                           "ad_try {
                                   $handler
                                 } ad_script_abort val {
                                   # do nothing
                                 }"
                               invoked from within
                           "rp_serve_concrete_file [ad_conn file]"
                               (procedure "rp_serve_abstract_file" line 60)
                               invoked from within
                           "rp_serve_abstract_file "$root/$path""
                               ("uplevel" body line 2)
                               invoked from within
                           "uplevel $code"
                               invoked from within
                           "ad_try {
                                   rp_serve_abstract_file "$root/$path"
                                   set tcl_url2file([ad_conn url]) [ad_conn file]
                                   set tcl_url2path_info([ad_conn url]) [ad_conn path_inf..."
Collapse
Posted by Dave Bauer on
Stan,

Drop the data model like this:

psql -f survey-drop.sql dbname

from survey/sql/postgresql.

Then cvs update and try to reinstall. This should be fixed.

Sorry for the inconvenience.

Collapse
Posted by Stan Kaufman on
Installed fine now; thanks! BTW on the main page, I get a broken image where 'admin.gif' is supposed to display. Doesn't appear that it made it into the package; find finds nothing by that name in /packages/survey/ and I don't see a /packages/graphics/ directory that might explain the src=/graphics/admin.gif param in the image tag. The installer didn't identify another dependency like a missing graphics package. Where is this graphic supposed to live? Thanks!
Collapse
Posted by Talli Somekh on
I was going to post right after Dave did, but then the Sopranos came on and...

Anyway, there are some people that I would like to thank for the development and release of this project, so please be aware that this is going to be an Oscar-esque thank you post. But if you're interested in seeing who added to this package and check out some props for great hackers and project managers, I hope that you would read on.

I would like to thank MIT/Sloan for selecting Musea Technologies (http://www.museatech.net) to work on this package. Caroline Meeks (http://www.meekshome.com) for doing an excellent job with project management and guiding our development.

Open Force (http://www.openforce.net) and its team (Ben, Arjun and Yon) for building an *extremely* strong platform for oacs development. People at LinuxWorld were wowed by it.

In order to help Musea develop the survey package, Dave Bauer (http://www.deepskydesign.com) was brought on to do yeoman's work in designing, building and fixing the system. Dave has done an incredible job in working with Caroline and Sloan to deliver what they needed.

I would also like to thank Luke Pond (http://www.museatech.net/about/luke.html), Musea's engineer extraordinaire for the high level design and fancy hacking of tough datamodel problems and development.

Malte Sussdorff (http://www.sussdorff-roy.com) contributed a great deal with development as our development team and his worked together to deliver a new system for both Sloan and SR's client.

In addition, Don Baccus (http://donb.photo.net) for bug fixing and for ad_form which is heavily used in survey.

Thanks to the openacs volunteers, developers and companies that have been tossing bug fixes and ideas into the pot for the past few years.

Finally, thanks to the #openacs IRC crew for wasting a lot of everyone's time with their petty little discussions about who Vinod has a crush on and why markd's Spousal Overunit is on the fritz. Pshhh... losers.

Just another example of all the pieces, vendors and volunteers that go into making the oacs...

Please download the survey package and bang away on it. Send in patches, bug fixes, new features and donations to the Capital Campaign to Build Talli's Gut. Everything will be accepted. At least for the campaign.

talli

Collapse
Posted by Stan Kaufman on
Dave, I don't know if you want stuff posted here or in the SDM, but trying to add a question to a survey produces this error. It appears there's some dotlrn stuff still in the code that needs to be cleaned out, eh?

Request Error

       invalid command name "dotlrn_community::get_community_id_from_url"
           while executing
       "dotlrn_community::get_community_id_from_url"
           invoked from within
       "set community_id [dotlrn_community::get_community_id_from_url]"
           ("uplevel" body line 27)
           invoked from within
       "uplevel {
                 ad_page_contract {

           This page allows the admin to administer a single survey.

           @param  section_id integer denoting survey we'..."
           (procedure "code::tcl::/var/web/epimetrics-dev/packages/survey/www/admin..." line 2)
           invoked from within
       "code::tcl::$__adp_stub"
           invoked from within
       "if { [file exists $__adp_stub.tcl] } {

             # ensure that data source preparation procedure exists and is up-to-date
             adp_init tcl $__adp_stub
       ..."
           ("uplevel" body line 3)
           invoked from within
       "uplevel {

           if { [file exists $__adp_stub.tcl] } {

             # ensure that data source preparation procedure exists and is up-to-date
             adp_init t..."
           (procedure "adp_prepare" line 2)
           invoked from within
       "adp_prepare "
           (procedure "template::adp_parse" line 30)
           invoked from within
       "template::adp_parse [file root [ad_conn file]] {}"
           (procedure "adp_parse_ad_conn_file" line 7)
           invoked from within
       "$handler"
           ("uplevel" body line 2)
           invoked from within
       "uplevel $code"
           invoked from within
       "ad_try {
               $handler
             } ad_script_abort val {
               # do nothing
             }"
           invoked from within
       "rp_serve_concrete_file [ad_conn file]"
           (procedure "rp_serve_abstract_file" line 60)
           invoked from within
       "rp_serve_abstract_file "$root/$path""
           ("uplevel" body line 2)
           invoked from within
       "uplevel $code"
           invoked from within
       "ad_try {
               rp_serve_abstract_file "$root/$path"
               set tcl_url2file([ad_conn url]) [ad_conn file]
               set tcl_url2path_info([ad_conn url]) [ad_conn path_inf..."
Collapse
Posted by Talli Somekh on
Stan, yes, there is a lot of dotlrn stuff that needs to be cleaned out, or at least hidden in a way. We decided to release it before everything was totally clean because it was important to get the code out there.

It will get cleaned out soon as will documentation be available. Please bear with us as we finish this stuff up.

talli

Collapse
Posted by Talli Somekh on
Rather, we were *reminded* that code needs to be released and available to the community even in its developmental stages. I've been a big proponent of this, and some people reminded me that I should be doing it as well.

talli

Collapse
Posted by Stan Kaufman on
Given those considerations, how would it be most helpful to handle discovered bugs of this sort? I don't want to pester the maintainers about stuff that they already know, but then again, until someone points problems out, they may fall through the cracks...
Collapse
Posted by Talli Somekh on
A very reasonable question.

For those in the know, is it better to have this in the OpenACS bugtracker or the dotLRN bugtracker?

In the meantime, I will set something up.

talli

Collapse
Posted by Talli Somekh on
While we're still working out where the canonical version of the Survey bugtracker will be, I've set one up here (http://clients.museatech.net/Sloan/Bugtracker/).

Registered users should have access to add bugs. Let me know if it doesn't work.

talli

Collapse
Posted by Stan Kaufman on
What about the rest of us? I registered by was rejected from bugtracker for lack of proper permissions...
Collapse
Posted by Talli Somekh on
Ok, Stan, you should have access now.

That user admin page has *got* to change soon...

talli

Collapse
Posted by Dave Bauer on
Stan,

Thanks for the feedback. For some strange reason I needed to actually sleep last night. Posting questions and bugs to the bboard is fine with me. Or use the bugtracker Talli set up. I should get email from that.

The graphics package idea is good. Maybe we should have packages that contain nothing except graphics or other resources.

Sloan was keeping all their graphics in www/graphics, so I can't install the icons in there from istalling the survey package.

Maybe I can include them in survey/www/graphics, and create a way upon installation to move them to the right place. What we need is a set of standard icons for OpenACS. Then every package could take advantage of standard icons for new, edit, delete, admin, etc.

I am sure this was mentioned before.

Collapse
Posted by Dave Bauer on
Stan,

OK, i think this is all fixed. It is working on my test system anyway.

Collapse
Posted by Stan Kaufman on
Dave, thanks for the fixes. Sleep is good and underrated.

I can now add questions without error, but all the graphics for the buttons are still missing. Is there something other than just a cvs update that I need to do to get them into the package (like uninstall and reinstall it -- I'm still somewhat foggy on v4.5 stuff like this)?