Fisheye: Tag 1.1.22.2 refers to a dead (removed) revision in file `openacs-4/packages/acs-admin/www/apm/version-reload.adp'. Fisheye: No comparison available. Pass `N' to diff? Index: openacs-4/packages/acs-admin/www/apm/version-reload.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-admin/www/apm/version-reload.tcl,v diff -u -r1.9.20.3 -r1.9.20.4 --- openacs-4/packages/acs-admin/www/apm/version-reload.tcl 5 Aug 2014 10:08:55 -0000 1.9.20.3 +++ openacs-4/packages/acs-admin/www/apm/version-reload.tcl 7 Aug 2014 19:09:26 -0000 1.9.20.4 @@ -27,7 +27,19 @@ if { [llength $files] == 0 } { append body "There are no changed files to reload in this package.

" } else { - append body "Marked the following file[ad_decode [llength $files] 1 "" "s"] for reloading:

\n" } @@ -68,4 +101,6 @@ }] -ad_return_template apm +# template::head::add_javascript -src "//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js" + +ad_return_template Index: openacs-4/packages/acs-bootstrap-installer/tcl/30-apm-load-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-bootstrap-installer/tcl/30-apm-load-procs.tcl,v diff -u -r1.41.2.7 -r1.41.2.8 --- openacs-4/packages/acs-bootstrap-installer/tcl/30-apm-load-procs.tcl 2 Nov 2013 18:18:44 -0000 1.41.2.7 +++ openacs-4/packages/acs-bootstrap-installer/tcl/30-apm-load-procs.tcl 7 Aug 2014 19:09:26 -0000 1.41.2.8 @@ -362,24 +362,35 @@ return [expr {![file exists "${package_path}/sql"] || [file exists "${package_path}/sql/[db_type]"]}] } -ad_proc -private apm_source { __file } { +ad_proc -private apm_source { __file {errorVarName ""}} { Sources $__file in a clean environment, returning 1 if successful or 0 if not. Records that the file has been sourced and stores its mtime in the nsv array apm_library_mtime } { + if {$errorVarName ne ""} { + upvar $errorVarName errors + } else { + array set errors [list] + } + if { ![file exists $__file] } { - ns_log "Error" "Unable to source $__file: file does not exist." + ns_log "Error" "Unable to source $__file: file does not exist." return 0 } + set r_file [ad_make_relative_path $__file] + # Actually do the source. - if { [catch { source $__file }] } { - global errorInfo - ns_log "Error" "Error sourcing $__file:\n$errorInfo" + if { [catch { source $__file } errorMsg] } { + set backTrace $::errorInfo + ns_log "Error" "Error sourcing $__file:\n$backTrace" + set package_key "" + regexp {/packages/([^/]+)/} $__file -> package_key + lappend errors($package_key) $r_file $backTrace return 0 } - nsv_set apm_library_mtime [ad_make_relative_path $__file] [file mtime $__file] + nsv_set apm_library_mtime $r_file [file mtime $__file] return 1 } @@ -591,4 +602,4 @@ file copy -force $file [acs_root_dir]/tcl } } -} \ No newline at end of file +} Index: openacs-4/packages/acs-bootstrap-installer/tcl/40-db-query-dispatcher-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-bootstrap-installer/tcl/40-db-query-dispatcher-procs.tcl,v diff -u -r1.42.2.6 -r1.42.2.7 --- openacs-4/packages/acs-bootstrap-installer/tcl/40-db-query-dispatcher-procs.tcl 17 Oct 2013 08:54:59 -0000 1.42.2.6 +++ openacs-4/packages/acs-bootstrap-installer/tcl/40-db-query-dispatcher-procs.tcl 7 Aug 2014 19:09:26 -0000 1.42.2.7 @@ -217,14 +217,23 @@ # ################################################ -ad_proc -public db_qd_load_query_file {file_path} { +ad_proc -public db_qd_load_query_file {file_path {errorVarName ""}} { A procedure that is called from the outside world (APM) to load a particular file -} { - if { [catch {db_qd_internal_load_cache $file_path} errmsg] } { - global errorInfo - ns_log Error "Error parsing queryfile $file_path:\n\n$errmsg\n\n$errorInfo" +} { + if {$errorVarName ne ""} { + upvar $errorVarName errors + } else { + array set errors [list] } + if { [catch {db_qd_internal_load_cache $file_path} errMsg] } { + set backTrace $::errorInfo + ns_log Error "Error parsing queryfile $file_path:\n\n$errMsg\n\n$backTrace" + set r_file [ad_make_relative_path $file_path] + set package_key "" + regexp {/packages/([^/]+)/} $file_path -> package_key + lappend errors($package_key) $r_file $backTrace + } } Index: openacs-4/packages/acs-tcl/tcl/apm-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/apm-procs.tcl,v diff -u -r1.94.2.15 -r1.94.2.16 --- openacs-4/packages/acs-tcl/tcl/apm-procs.tcl 24 Jul 2014 08:27:59 -0000 1.94.2.15 +++ openacs-4/packages/acs-tcl/tcl/apm-procs.tcl 7 Aug 2014 19:09:26 -0000 1.94.2.16 @@ -751,7 +751,7 @@ " -default "all" -bind [list db_type $db_type]]] } -ad_proc -public apm_load_any_changed_libraries {} { +ad_proc -public apm_load_any_changed_libraries { {errorVarName {}} } { In the running interpreter, reloads files marked for reload by apm_mark_version_for_reload. If any watches are set, examines watched @@ -760,6 +760,13 @@ before any filters or registered procedures are applied). } { + + if {$errorVarName ne ""} { + upvar $errorVarName errors + } else { + array set errors [list] + } + # Determine the current reload level in this interpreter by calling # apm_reload_level_in_this_interpreter. If this fails, we define the reload level to be # zero. @@ -820,12 +827,12 @@ # Make sure this is not a -init.tcl file as those should only be sourced on server startup if { ![regexp {\-init\.tcl$} $file_path] } { ns_log Notice "apm_load_any_changed_libraries: Reloading $file..." - apm_source $file_path + apm_source $file_path errors } } .xql { ns_log Notice "apm_load_any_changed_libraries: Reloading $file..." - db_qd_load_query_file $file_path + db_qd_load_query_file $file_path errors } default { ns_log Notice "apm_load_any_changed_libraries: File $file_path has unknown extension. Not reloading."