Forum OpenACS Development: HEADache ...

Collapse
Posted by Ola Hansson on
I am getting some errors when I install acs-core from HEAD:
ola@debian:~$ tail -n 20 ~/web/dotlrn-test/log/error.log
 
[15/Feb/2003:16:38:20][11459.49156][-conn0-] Debug: --------------------------
 
[15/Feb/2003:16:38:20][11459.49156][-conn0-] Debug:                         0
 
[15/Feb/2003:16:38:20][11459.49156][-conn0-] Debug: (1 row)
 
[15/Feb/2003:16:38:20][11459.49156][-conn0-] Error: Error sourcing /home/ola/web/dotlrn-test/packages/acs-bootstrap-installer/installer/install-data-model.tcl:
psql:groups-body-create.sql:202: ERROR:  ProcedureCreate: cannot change return type of existing function.
        Use DROP FUNCTION first.
psql:groups-body-create.sql:333: ERROR:  ProcedureCreate: cannot change return type of existing function.
        Use DROP FUNCTION first.
psql:acs-create.sql:258: ERROR:  -20000: Insert to membership rels not yet supported
psql:acs-create.sql:303: ERROR:  -20001: composition_rel  violation: Invalid object types. Object <NULL> (<NULL>) must be of type <NULL> Object -2 (<NULL>) must be of type <NULL>
 
    invoked from within
"db_source_sql_file -callback apm_ns_write_callback "acs-kernel-create.sql""
    (file "/home/ola/web/dotlrn-test/packages/acs-bootstrap-installer/installer/install-data-model.tcl" line 31)
    invoked from within
"source $__file "
ola@debian:~$
(I am on PG 7.3.2 ...)

I will try to hunt this down, but if someone finds the aspirin before I do, it wouldn't hurt 😉

/Ola

Collapse
2: Re: HEADache ... (response to 1)
Posted by Peter Marklund on
Ola,
I experienced the same error on PG 7.3. However, it doesn't occur on 7.2. Unfortunately I didn't see the reason for the problem and right now I'm busy fixing other installation problems.

/Peter

Collapse
3: Re: HEADache ... (response to 1)
Posted by Don Baccus on
It looks like it is coughing on the redefinition of the function fired by the trigger.  Both definitions will have type opaque so that makes me wonder if it is a PG bug.  Peter, I'll be interested to see what you find out.

BTW HEAD is slightly whacked out at the moment.  I've concentrated on getting my permissions changes into 4.6.1 - originally they were going into 4.7 but after 4.6 proved to be absolutely unscalable in the face of lots of groups and relational segments (i.e. "dotLRN") got moved to 4.6.1.

I'll be cleaning up HEAD tomorrow or Monday AM ...

Collapse
4: Re: HEADache ... (response to 3)
Posted by Matthew Walker on
In PG 7.3 they have redefined the return type for trigger functions from 'OPAQUE' to 'TRIGGER'. They do this automagically for new functions but it seems that when 'create or replace function' is used in 7.3 with a return type of opaque it doesn't like it because it thinks you are trying to redefine the return type of the existing function (which it automagically changed from opaque to trigger).

The solution for 7.3 currently is to change the return type to trigger for the two trigger functions (membership_rels_in_tr and composition_rels_in_tr) that are replaced in acs-kernel/sql/postgresql/groups-body-create.sql (these are originally created in acs-kernel/sql/postgresql/groups-create.sql as placeholders). The problem is this then won't work in PG 7.1 or 7.2.

Matthew

Collapse
5: Re: HEADache ... (response to 1)
Posted by Don Baccus on
(sigh) never a dull moment with these postgres improvements ...

I'll switch it back to the drop/drop/create/create coding style.

sigh ... sigh ... sigh ...

Collapse
6: Re: HEADache ... (response to 1)
Posted by Roberto Mello on
Hmmm, this really sucks. I just bumped into this in a dotlrn install. I'm glad I made those PG 7.2.4 Debian packages now.

I sent a message about this to the PG list. I'd like to know the rationale behind this change, and the possibility of a fix in a 7.3 maintenance release.

-Roberto