Forum OpenACS Q&A: Which is the best way to update acs-lang?

Hi all,

I installed openACS 4.6.3, but now I need to use the new acs-lang package. I would like to know which is the best strategy to follow knowing that the only package that I need to use, apart from the acs-core, is the edit-this-page package.

If I get the HEAD acs-lang version from cvs and just overwrite my old acs-lang folder and run the sql scripts I get this error:

unknown command "locale":  should be authpassword, authuser, close, content, contentlength, driver, flags, form, headers, host, isconnected, location, method, outputheaders, peeraddr, peerport, port, protocol, url, query, server, sock, start, status, urlc, urlv, or version
    while executing
"ns_conn $var"
    ("-get" arm line 20)
    invoked from within
"switch -- $flag {
    -connected_p {
      return [info exists ad_conn(request)]
    }

    -set {
      set ad_conn($var) [lindex $args 2]
    }

   ..."
    (procedure "ad_conn" line 12)
    invoked from within
"ad_conn locale"
    invoked from within
"set locale_user [ad_conn locale]"

And if I get all the openACS core from the HEAD, after fixing some bugs (problems with acs-lang sql creation script, with the calling to the 'lang::message::register' function inside the '/packages/acs-lang/tcl/lang-catalog-procs.tcl' file and with the absence of the 'locale' column in the user_preferences table), I get errors in the two versions of the edit-this-page package.

With the 1.1d version the file '/package/edit-this-page/www/etp' I get this error:

can't read "content_types(etp_page_revision)": no such element in array
    while executing
"set attributes $content_types($content_type)"
    (procedure "etp::get_ext_attribute_columns" line 7)
    invoked from within
"etp::get_ext_attribute_columns $content_type"
    invoked from within
"set extended_attributes [etp::get_ext_attribute_columns $content_type]"
    ("uplevel" body line 32)
    invoked from within
"uplevel {
    	  ad_page_contract {
    @author Luke Pond (dlpond@museatech.net)
    @creation-date 2001-06-04

    Displays all options for editing a..."
    (procedure "code::tcl::/web/dev/packages/edit-this-page/www/etp" 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

And with the 1.5d version the file '/package/edit-this-page/www/etp-setup-2' I get this error:

ora8.c:3463:ora_tcl_command: error in `OCIStmtExecute ()': ORA-00001: unique constraint (DEV.CR_ITEMS_UNIQUE_NAME) violated
ORA-06512: at "DEV.CONTENT_ITEM", line 169
ORA-06512: at "DEV.CONTENT_FOLDER", line 34
ORA-06512: at line 3

SQL: 
   begin
     :1 := content_folder.new(
              name        => :name,
              label       => :title,
              description => '',
              parent_id   => etp.get_folder_id(:parent_package_id)
           );
   end;

    while executing
"ns_ora exec_plsql_bind nsdb0 {
   begin
     :1 := content_folder.new(
              name        => :name,
              label       => :title,
      ..."
    ("uplevel" body line 1)
    invoked from within
"uplevel $ulevel [list ns_ora $type $db $sql] $args"
    ("oracle" arm line 2)
    invoked from within
"switch $driverkey {

I know the HEAD version is not stable, but I have read some post of Lars saying that acs-lang would work well from the HEAD untill the next openACS 4.7 version.
Should I wait till the 4.7 (when is the release scheduled?), or can you help me with these errors?

Thanx in advance,
juanjo

Collapse
Posted by Jarkko Laine on
juanjo,

To play around with i18n you have to use HEAD, 4.6 doesn't do the trick. So your latter approach is the right one. However, I can't help with the errors you got. Hope someone can.