Closed lgaetz closed 10 years ago
Re: mulitfecta, I am not sure I am trying to use this feature correctly. Debug seems to work fine in single mode, but when I try to enable mulit mode debug fails with no output
edit: multi mode was not working until Jun 24 commit
Did you like that mouse pointer changing thing? I removed it because it's inconsistant with the rest of freepbx (Im trying to make this module look less like a rickety module and more like the freepbx/schmooze modules)
I haven't played with multi yet. Been working on bugs and functionality on super. Will check all of this shortly (right now)
'+' and spaces will be replaced with underscores
I added and deleted a few items in the original post above based on the June 24 commit. It's looking good.
When doing debug in single mode, I noticed that this version of superfecta does not remove spaces from $thenumber like 2.x did. Other non-digit characters do seem to be stripped. I have written all my lookup sources assuming that $thenumber was only digits. Is this a necessary change or a bug?
Fixed in July 20 commit
Another time to check for bugs @lgaetz and yes I know mouseovers still aren't working for sources...I need to figure out a better way to do that.
You knocked off a bunch of the bugs, it is looking really good. I edited post one above to scratch the bugs that are now working, and added some more to do with lookup modules. As soon as the user settings for individual lookups are saved, I will install this on my production system and get a real workout.
I think the July 20 commit should be called Alpha3 and this thread renamed to keep things less confusing.
I wonder if version 3.x should be completely split from the Superfecta repo and become the Master branch of a whole new Github project called Multifecta with numbering starting at 3.x
In Multi mode it checks for a valid CID rule, but runs the search on the original unmodified number
I couldn't replicate this. Perhaps more details?
Ok fixed those issues described above. Again I can't replicate your CID rule issue...
I couldn't replicate this. Perhaps more details?
I have both analog and SIP/IAX trunks. Local analog calls come in with CID of 7 digits only, one SIP trunk delivers 10 digit CID and one delivers 11 digits. I have the following CID rules defined for superfecta lookups:
1902+NXXXXXX
1+NxxNxxxxxx
1NxxNxxxxxx
In Multi mode only, when I do a debug with a 7 digit number, it will try to do a lookup with 7 digits and give me an error that it is not a valid number. In single mode a debug with 7 digits gets prefixed with 902 and lookup succeeds.
I tried installing alpha3 on FreePBX 2.8 and PHP ver. 5.1.6 . Everything seems to install properly, but the superfecta config page is blank when you click on it. This is for information purposes only, I don't see any reason to maintain 2.8 compatibility.
Unfortunately it means I can't test this any time soon on a production server :-(
here are some lines from the httpd log in case this is relevant to other versions:
[Sun Jul 22 11:05:29 2012] [error] [client 10.50.0.138] PHP Notice: Undefined variable: thisItem_description in /var/www/html/admin/modules/cidlookup/page.cidlookup.php on line 108, referer: http://10.41.2.2/admin/config.php?display=did&extdisplay=9024420777%2F&extension=9024420777&cidnum=&didfilter=&rnavsort=description
[Sun Jul 22 11:05:47 2012] [error] [client 10.50.0.138] PHP Parse error: syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM in /var/www/html/admin/modules/superfecta/page.superfecta.php on line 163, referer: http://10.41.2.2/admin/config.php?type=setup&display=cidlookup
[Sun Jul 22 11:05:56 2012] [error] [client 10.50.0.138] PHP Notice: Undefined variable: thisItem_description in /var/www/html/admin/modules/cidlookup/page.cidlookup.php on line 108, referer: http://10.41.2.2/admin/config.php?display=did&extdisplay=9024420777%2F&extension=9024420777&cidnum=&didfilter=&rnavsort=description
[Sun Jul 22 11:06:00 2012] [error] [client 10.50.0.138] PHP Parse error: syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM in /var/www/html/admin/modules/superfecta/page.superfecta.php on line 163, referer: http://10.41.2.2/admin/config.php?type=setup&display=cidlookup
[Sun Jul 22 11:06:14 2012] [error] [client 10.50.0.138] PHP Notice: Undefined variable: thisItem_description in /var/www/html/admin/modules/cidlookup/page.cidlookup.php on line 108, referer: http://10.41.2.2/admin/config.php?display=did&extdisplay=9024420777%2F&extension=9024420777&cidnum=&didfilter=&rnavsort=description
[Sun Jul 22 11:06:36 2012] [error] [client 10.50.0.138] PHP Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of [runtime function name](). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /var/www/html/admin/page.modules.php on line 566, referer: http://10.41.2.2/admin/config.php?type=setup&display=cidlookup
[Sun Jul 22 11:06:36 2012] [error] [client 10.50.0.138] PHP Notice: Undefined variable: freepbx_version in /var/www/html/admin/functions.inc.php on line 1651, referer: http://10.41.2.2/admin/config.php?type=setup&display=cidlookup
[Sun Jul 22 11:06:49 2012] [error] [client 10.50.0.138] PHP Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of [runtime function name](). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /var/www/html/admin/page.modules.php on line 566, referer: http://10.41.2.2/admin/config.php?type=setup&display=modules
[Sun Jul 22 11:06:49 2012] [error] [client 10.50.0.138] PHP Notice: Undefined variable: freepbx_version in /var/www/html/admin/functions.inc.php on line 1651, referer: http://10.41.2.2/admin/config.php?type=setup&display=modules
[Sun Jul 22 11:06:52 2012] [error] [client 10.50.0.138] PHP Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of [runtime function name](). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /var/www/html/admin/page.modules.php on line 566, referer: http://10.41.2.2/admin/config.php
[Sun Jul 22 11:06:54 2012] [error] [client 10.50.0.138] PHP Warning: Call-time pass-by-reference has been deprecated - argument passed by value; If you would like to pass it by reference, modify the declaration of [runtime function name](). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file. However, future versions may not support this any longer. in /var/www/html/admin/page.modules.php on line 566, referer: http://10.41.2.2/admin/config.php
[Sun Jul 22 11:06:54 2012] [error] [client 10.50.0.138] PHP Notice: Undefined variable: freepbx_version in /var/www/html/admin/functions.inc.php on line 1651, referer: http://10.41.2.2/admin/config.php
Google tells me that the error for line 163 (and I presume 164 as well) is related to the double colon:
163 "name" => strtoupper($class_name::$name),
164 "description" => $class_name::$description,
I tried changing them to single colons but that doesn't work either. I will leave alpha3 installed for a short time in case someone has a quick solution to try. When I comment these lines out, GUI works again, but superfecta is broken.
Double colons are scope resolution operators. Please see: http://en.wikipedia.org/wiki/Scope_resolution_operator or http://php.net/manual/en/keyword.paamayim-nekudotayim.php
Changing them to single breaks the functionality of this. On said system please run php -v and give me the results.
"As of PHP 5.3.0, it's possible to reference the class using a variable. The variable's value can not be a keyword (e.g. self, parent and static)."
Ai yi yi. Back to the drawing board! I'll resolve this for less than 5.3 in the next few days.
After line 161 enter this:
$class_name = new $class_name();
If that works then there are a few other changes you'll have to make, but I am curious.
First off:
root@pbx:~ $ php -v
PHP 5.1.6 (cli) (built: Nov 29 2010 16:47:37)
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies
Addiing the above after line 161 doesn't help, same error in httpd log:
[Sun Jul 22 20:43:22 2012] [error] [client 10.50.0.140] PHP Parse error: syntax error, unexpected T_PAAMAYIM_NEKUDOTAYIM in /var/www/html/admin/modules/superfecta/page.superfecta.php on line 164, referer: http://10.41.2.2/admin/config.php
For the record, I don't think we should expend too much effort to fix this issue. Not sure what the PBX distro is shipping with, but PIAF 2.x comes with PHP 5.3.x
I'd rather just make it work with PHP < 5.3x. If I can get some dang time in my IDE I could fix it, but I've got so many projects right now. I'm thinking I'll have it fixed tomorrow afternoon if all goes to plan. Thanks for waiting :-)
LOW PRIORITY
I think the send_to_Growl module was written by @ukstevef
Today I started playing with Growl installed on windows and have confirmed it works fine using the test file included with the readme.markdown file here: https://github.com/POSSA/Caller-ID-Superfecta/tree/v3.x/includes/php-growl
but I can't get Superfecta 3.0alpha3 to send notifications at all. Has anyone gotten this to work? Send_to_Winunciator works fine using debug.
I have growl on my mac so I'll look into it when I get back to this.
@lgaetz I finally fixed the T_PAAMAYIM_NEKUDOTAYIM issue. Please check. I'll work on the other issues in a bit as well.
Ok going to bed now. I added some sweet sweet debug messages in the asterisk CLI. It will help immensely with forum debugging in the future.
-- Executing [**********@from-trunk:4] AGI("DAHDI/1-1", "/var/www/html/admin/modules/superfecta/superfecta.agi") in new stack -- Launched AGI Script /var/www/html/admin/modules/superfecta/superfecta.agi /var/www/html/admin/modules/superfecta/superfecta.agi: CID Superfecta is Answering the Channel /var/www/html/admin/modules/superfecta/superfecta.agi: CID Superfecta: Scheme is ALL /var/www/html/admin/modules/superfecta/superfecta.agi: CID Superfecta: The DID passed from Asterisk is: ********** /var/www/html/admin/modules/superfecta/superfecta.agi: CID Superfecta: The number passed from Asterisk is: ********** /var/www/html/admin/modules/superfecta/superfecta.agi: CID Superfecta: Executing Scheme == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged on from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 == Manager 'admin' logged off from 127.0.0.1 /var/www/html/admin/modules/superfecta/superfecta.agi: CID Superfecta: CID Determined to be: 'Andrew Nagy' /var/www/html/admin/modules/superfecta/superfecta.agi: CID Superfecta: Attempting to set lookupcid
I have installed on my 2.10 test system and everything is looking good. I incremented the version number to alpha4 so I can keep things straight in my head. When I have a bit of time after bus hours, I will install it on my 2.8 production system and see what happens.
Knowing that people are using Superfecta 2.x for other purposes than inbound CNAM, is there any way to do the same thing with 3.x? Can 3.x give a CNAM via simple URL anymore?
3.x installer should check for the 2.x Caller ID Superfecta
entry in CID Lookup Souces
and remove it. It may be necessary to remove it from all inbound routes too, I think there was an issue a long time ago about inbound routes being inaccessible when superfecta 2.x was uninstalled because the lookup source was still present in inbound routes. These lines from 2.x unintall.php file are probably relevant:
$sql = "delete c1 from cidlookup_incoming c1, cidlookup c2 where c1.cidlookup_id = c2.cidlookup_id and c2.description = 'Caller ID Superfecta'";
$res = $db->query($sql);
//delete the line from the cidlookup table
$sql = "DELETE FROM cidlookup WHERE description = 'Caller ID Superfecta'";
$res = $db->query($sql);
//cleanup stray cidlookup_incoming records left by bad uninstalls
$sql = "delete c1 from cidlookup_incoming c1 left outer join cidlookup c2 on c1.cidlookup_id = c2.cidlookup_id where c2.cidlookup_id is null";
$res = $db->query($sql);
I have installed on my production system, FreePBX 2.8, Asterisk 1.8, PHP 5.1.6 CNAM lookups with alpha4 not working, module installs and configures fine but incoming calls all have the CID = CNAM. Debug for this number working, tried with both DAHDI and SIP trunks. Nothing useful in the httpd log, here is a portion the asterisk full log of incoming call CNAM part only:
[2012-09-18 10:20:05] VERBOSE[10798] pbx.c: -- Goto (from-pstn,s,1)
[2012-09-18 10:20:05] VERBOSE[10798] pbx.c: -- Executing [s@from-pstn:1] ExecIf("DAHDI/2-1", "1?Set(__FROM_DID=s)") in new stack
[2012-09-18 10:20:05] VERBOSE[10798] pbx.c: -- Executing [s@from-pstn:2] Set("DAHDI/2-1", "CIDSFSCHEME=ALL|ALL") in new stack
[2012-09-18 10:20:05] WARNING[10798] pbx.c: The application delimiter is now the comma, not the pipe. Did you forget to convert your dialplan? (Set(CIDSFSCHEME=ALL|ALL))
[2012-09-18 10:20:05] VERBOSE[10798] pbx.c: -- Executing [s@from-pstn:3] AGI("DAHDI/2-1", "/var/www/html/admin/modules/superfecta/superfecta.agi") in new stack
[2012-09-18 10:20:05] VERBOSE[10798] res_agi.c: -- Launched AGI Script /var/www/html/admin/modules/superfecta/superfecta.agi
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] ERROR[10798] utils.c: write() returned error: Broken pipe
[2012-09-18 10:20:05] VERBOSE[10798] res_agi.c: -- <DAHDI/2-1>AGI Script /var/www/html/admin/modules/superfecta/superfecta.agi completed, returning 0
[2012-09-18 10:20:05] VERBOSE[10798] pbx.c: -- Executing [s@from-pstn:4] Set("DAHDI/2-1", "CALLERID(name)=") in new stack
Near the time of the failed CNAM lookup are these errors in the httpd log:
[Tue Sep 18 10:05:06 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: last in /var/www/html/admin/modules/superfecta/functions.inc.php on line 36, referer: http://10.41.2.2/admin/config.php?display=did&didfilter=&rnavsort=description&extdisplay=/8938455
[Tue Sep 18 10:05:06 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: ringing in /var/www/html/admin/modules/core/functions.inc.php on line 3396, referer: http://10.41.2.2/admin/config.php?display=did&didfilter=&rnavsort=description&extdisplay=/8938455
[Tue Sep 18 10:05:07 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: last in /var/www/html/admin/modules/superfecta/functions.inc.php on line 36, referer: http://10.41.2.2/admin/config.php?display=did&didfilter=&rnavsort=description&extdisplay=/8938455
[Tue Sep 18 10:05:07 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=did&didfilter=&rnavsort=description&extdisplay=/8938455
[Tue
During a alpha4 scheme save, here is a partial list of notices showing up in the http log, PHP 5.1.6:
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: schemecopy in /var/www/html/admin/modules/superfecta/page.superfecta.php on line 40, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: scheme in /var/www/html/admin/modules/superfecta/tpl/compiled/header.5048f1b389baec829f22752457a107d0.php on line 96, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Warning: Missing argument 1 for superfecta_multi::__construct(), called in /var/www/html/admin/modules/superfecta/page.superfecta.php on line 162 and defined in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 9, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 10, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 11, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined offset: 1 in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 12, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 13, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 14, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 15, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 16, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 17, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 18, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 19, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 20, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_multi.php on line 21, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Warning: Missing argument 1 for superfecta_single::__construct(), called in /var/www/html/admin/modules/superfecta/page.superfecta.php on line 162 and defined in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 9, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 10, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 11, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined offset: 1 in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 12, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 13, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 14, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 15, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 16, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 17, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 18, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: options in /var/www/html/admin/modules/superfecta/includes/processors/superfecta_single.php on line 19, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined index: category in /var/www/html/admin/functions.inc.php on line 2077, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: check_updates in /var/www/html/admin/modules/superfecta/sources_new.php on line 69, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: update_site_unavailable in /var/www/html/admin/modules/superfecta/sources_new.php on line 71, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
[Tue Sep 18 10:54:55 2012] [error] [client 10.41.2.142] PHP Notice: Undefined variable: update_site_message in /var/www/html/admin/modules/superfecta/tpl/compiled/sources.5048f1b389baec829f22752457a107d0.php on line 189, referer: http://10.41.2.2/admin/config.php?display=superfecta&scheme=base_Initial
The agi script is not being executed by your system. Not sure why without being connected to it. You'd see debug messages that run well before superfecta. I suggest you check permissions on eveything. If you are doing git as root you must! Make sure everything is owned by asterisk. Otherwise the agi won't really run. Which is what I think it happening to you. Ps why do you have so many broken pipes. That's also not a superfecta error
Ah ok so I think broken pipe is related to the permissions being wrong on the agi
Confirmed ownership of everything is asterisk:asterisk, chmod to 777 just in case, no change still get no cnam and lots of broken pipes. Outside access is impossible unfortunately, it is behind a corp router outside my control
root@pbx:/var/www/html/admin/modules $ ls -l superfecta
total 88
-rwxrwxrwx 1 asterisk asterisk 182 Sep 18 08:31 ajax.html.php
drwxrwxrwx 4 asterisk asterisk 4096 Sep 18 09:50 assets
-rwxrwxrwx 1 asterisk asterisk 186 Sep 18 08:31 callerid.html.php
-rwxrwxrwx 1 asterisk asterisk 1016 Sep 18 08:31 disclaimer.html
-rwxrwxrwx 1 asterisk asterisk 7393 Sep 18 08:31 functions.inc.php
-rwxrwxrwx 1 asterisk asterisk 3152 Sep 18 08:31 generate_source_list_json.php
drwxrwxrwx 5 asterisk asterisk 4096 Sep 18 09:50 includes
-rwxrwxrwx 1 asterisk asterisk 14248 Sep 18 08:31 install.php
-rwxrwxrwx 1 asterisk asterisk 1239 Sep 18 10:00 log
-rwxrwxrwx 1 asterisk asterisk 2688 Sep 18 09:54 module.xml
-rwxrwxrwx 1 asterisk asterisk 9189 Sep 18 09:54 page.superfecta.php
drwxrwxrwx 2 asterisk asterisk 4096 Sep 18 09:50 sources
-rwxrwxrwx 1 asterisk asterisk 3201 Sep 18 09:54 sources_new.php
-rwxrwxrwx 1 asterisk asterisk 2169 Sep 18 09:54 superfecta.agi
drwxrwxrwx 3 asterisk asterisk 4096 Sep 18 09:57 tpl
-rwxrwxrwx 1 asterisk asterisk 1317 Sep 18 08:31 uninstall.php
Lorne
ssh in and run amportal a dbug
Then call in
Sent from my iPhone
On Sep 18, 2012, at 7:36 AM, Lorne Gaetz notifications@github.com wrote:
Confirmed ownership of everything is asterisk:asterisk, chmod to 777 just in case, no change still get no cnam and lots of broken pipes. Outside access is impossible unfortunately, it is behind a corp router outside my control
root@pbx:/var/www/html/admin/modules $ ls -l superfecta total 88 -rwxrwxrwx 1 asterisk asterisk 182 Sep 18 08:31 ajax.html.php drwxrwxrwx 4 asterisk asterisk 4096 Sep 18 09:50 assets -rwxrwxrwx 1 asterisk asterisk 186 Sep 18 08:31 callerid.html.php -rwxrwxrwx 1 asterisk asterisk 1016 Sep 18 08:31 disclaimer.html -rwxrwxrwx 1 asterisk asterisk 7393 Sep 18 08:31 functions.inc.php -rwxrwxrwx 1 asterisk asterisk 3152 Sep 18 08:31 generate_source_list_json.php drwxrwxrwx 5 asterisk asterisk 4096 Sep 18 09:50 includes -rwxrwxrwx 1 asterisk asterisk 14248 Sep 18 08:31 install.php -rwxrwxrwx 1 asterisk asterisk 1239 Sep 18 10:00 log -rwxrwxrwx 1 asterisk asterisk 2688 Sep 18 09:54 module.xml -rwxrwxrwx 1 asterisk asterisk 9189 Sep 18 09:54 page.superfecta.php drwxrwxrwx 2 asterisk asterisk 4096 Sep 18 09:50 sources -rwxrwxrwx 1 asterisk asterisk 3201 Sep 18 09:54 sources_new.php -rwxrwxrwx 1 asterisk asterisk 2169 Sep 18 09:54 superfecta.agi drwxrwxrwx 3 asterisk asterisk 4096 Sep 18 09:57 tpl -rwxrwxrwx 1 asterisk asterisk 1317 Sep 18 08:31 uninstall.php
— Reply to this email directly or view it on GitHubhttps://github.com/POSSA/Caller-ID-Superfecta/issues/82#issuecomment-8656910.
No dbug output to report. This is causing a bit of disruption so am rolling back to 2.x.
I understand. Unfortunately I can't do much more other than say it works on two of my 2.8 system just fine.
How do you want to proceed?
PS. what version of asterisk was this?
versions: Asterisk 1.8, FreePBX 2.8, PHP 5.1.6
If you have it working, I will see if I can narrow it down to what the issue is, but I need to play some time when the office is empty. If nothing else I will learn the nuts and bolts. I really don't think this is something that should be taking too much of the dev's time, 2.8 must be EOL by now.
It's not a 2.8 issue. Not that I think anyways. It could happen if you went to 2.10 on that system I believe. I'm looking into the issue (google: "utils.c: write() returned error: Broken pipe")
Seems to be an issue with the system (asterisk) being unwilling to run AGI scripts. I'm trying to dig deeper.
I might have nailed it:
The problem was solved. I installed a latest version of Asterisk to another machine, the AGI worked. I copied phpagi.php file from the new system to the >>old system, the old system worked too. So, the problem is the phpagi.php in the previous version, which is Asterisk 2.5x, was >>broken.
http://www.freepbx.org/forum/freepbx/users/agi-not-working
This further confirms that I want to run the AGI class from superfecta. Can I get you to upload a new version of the AGI class to /var/lib/asterisk/agi-bin?
Otherwise I will include a version of the AGI class inside superfecta....
You know, I was just coming to the realization that it could be phpagi.pgp
, I can upload a copy, where should it come from?
I can email it to you. I just copied it off of a working system. Make sure you backup though.
FML! I only now realized there are core and framework updates available for this 2.8 system, that might be the cause of the issue. I really do need to wait for after hrs for this. Email me the file in any case, it may be useful.
Don't do it now. I can wait until later, I don't need you losing a client. I can't remember if the AGI stuff was fixed in 2.8. I remember (slightly) that there were issues with it in the past however I don't remember the resolution.
Ya it might be AGI though. In my phpagi.php I have this line
$Id: phpagi.php 12726 2011-10-03 13:40:00Z mbrevda $
So I guess it got fixed then
Here is the AGI id tag on my problem machine:
$Id: phpagi.php 8648 2010-01-21 20:25:06Z mickecarlsson $
Does this file get updated with FreePBX core/framework? I guess I will find out soon enough.
Yes and no....
It was updated a lot during the 2.8 stages because the project was left for dead and a few freepbx devs spent a lot of time fixing it but they never submitted it back to the original sourceforge project....not sure why really
It hasn't been updated since 2011 because it works correctly now.
If this replacement works then I strongly think we should just include our own php-agi and I'll just reference that instead.
Sent from my iPhone
On Sep 18, 2012, at 9:09 AM, Lorne Gaetz notifications@github.com wrote:
Here is the AGI id tag on my problem machine: $Id: phpagi.php 8648 2010-01-21 20:25:06Z mickecarlsson $ Does this file get updated with FreePBX core/framework? I guess I will find out soon enough.
— Reply to this email directly or view it on GitHubhttps://github.com/POSSA/Caller-ID-Superfecta/issues/82#issuecomment-8660209.
I just browsed the 2.8 branch of the FreePBX svn and it looks like my phpagi.php
file is up to date so instead of doing core/framework upgrades I have installed the updated version you emailed and will leave for a bit to make sure it hasn't broken anything. Provided that works out, I will try alpha4 again when things are quiet.
p.s. client = my employer, it is my office phone system, I don't do PBXs professionally, it's just for my warped sense of fun.
Interesting. I need to look at my employers 2.8 system. It works on there however I may have updated php-agi long long ago. I'm not near ssh to tell at this moment
Sent from my iPhone
On Sep 18, 2012, at 9:40 AM, Lorne Gaetz notifications@github.com wrote:
I just browsed the 2.8 branch of the FreePBX svn and it looks like my phpagi.php file is up to date so instead of doing core/framework upgrades I have installed the updated version you emailed and will leave for a bit to make sure it hasn't broken anything. Provided that works out, I will try alpha4 again when things are quiet.
p.s. client = my employer, it is my office phone system, I don't do PBXs professionally, it's just for my warped sense of fun.
— Reply to this email directly or view it on GitHubhttps://github.com/POSSA/Caller-ID-Superfecta/issues/82#issuecomment-8661261.
Oh I just remembered! That system is a 2.9 system. Doh! Would be curious still if this fixes your problem. Let me know.
Sent from my iPhone
On Sep 18, 2012, at 9:40 AM, Lorne Gaetz notifications@github.com wrote:
I just browsed the 2.8 branch of the FreePBX svn and it looks like my phpagi.php file is up to date so instead of doing core/framework upgrades I have installed the updated version you emailed and will leave for a bit to make sure it hasn't broken anything. Provided that works out, I will try alpha4 again when things are quiet.
p.s. client = my employer, it is my office phone system, I don't do PBXs professionally, it's just for my warped sense of fun.
— Reply to this email directly or view it on GitHubhttps://github.com/POSSA/Caller-ID-Superfecta/issues/82#issuecomment-8661261.
Yes. That's how the debugger works. I will display the URL for people to use though
Knowing that people are using Superfecta 2.x for other purposes than inbound CNAM, is there any way to do the same thing with 3.x? Can 3.x give a CNAM via simple URL anymore?
CNAM lookups are working on 2.8! Problem was the stupid smartgit client inserts windows newlines in place of unix newlines on occasion. It almost never causes a problem, but Asterisk is fussy about the AGI file format. Worst thing is I have learned this lesson before and thought I had it fixed. Apologies for wasting your time. I will delete some of the posts above dealing with this issue to keep this thread clean.
Trunk provided module in alpha 4 is not working for me.
So we don't need to include the php-agi file? Should we include it so that there is one less area of potential breakage?
I will look into trunk provided. That module is a pain.
Sent from my iPhone
On Sep 18, 2012, at 12:04 PM, Lorne Gaetz notifications@github.com wrote:
CNAM lookups are working on 2.8! Problem was the stupid smartgit client inserts windows newlines in place of unix newlines on occasion. It almost never causes a problem, but Asterisk is fussy about the AGI file format. Worst thing is I have learned this lesson before and thought I had it fixed. Apologies for wasting your time.
Trunk provided module in alpha 4 is not working for me.
— Reply to this email directly or view it on GitHubhttps://github.com/POSSA/Caller-ID-Superfecta/issues/82#issuecomment-8666270.
Just tested with both versions of the phpagi.php files and confirm that alpha4 only works with the newest version (the ones you emailed me).
re: trunk provided, I had a hand in making that work way back in 2.2.3 days. There has to be a better way to get the existing CNAM than that, I will do a bit of research and see if asterisk channel variables are available directly.
edit Trunk provided does work as long as you don't modify the CID with scheme rules. As soon as the CID is modified, it will no longer match the CID for any active asterisk channels and never gets a match. For the trunk provided module to work as it is currently written, it needs access to the CID variable before it is modified by scheme rules (in 2.x that is the $thenumber_orig variable)
Now that we are using an agi script you have direct access to the channel look at the php agi parameters
Also I will include the new version of php-agi and reference that from now on
Sent from my iPhone
On Sep 18, 2012, at 12:53 PM, Lorne Gaetz notifications@github.com wrote:
Just tested with both versions of the phpagi.php files and confirm that alpha4 only works with the newest version (the ones you emailed me).
re: trunk provided, I had a hand in making that work way back in 2.2.3 days. There has to be a better way to get the existing CNAM than that, I will do a bit of research and see if asterisk channel variables are available directly.
— Reply to this email directly or view it on GitHubhttps://github.com/POSSA/Caller-ID-Superfecta/issues/82#issuecomment-8667936.
Previous commit gets trunk provided working. I don't know if it is "elegant", I added the require agi again, maybe it should be a require_once? shrug/ I will leave to others to clean it up.
edit Spoke too soon, the code above hangs GUI during debug. Is there any (i.e. like the $debug variable in 2.x) way to tell if we are running debug vs active call?
Bugs
Can't use a '+' character in Scheme nameMulitfecta mode mode not workingCan't save CID RulesWhen running a debug with a DID specified, DID never matches and debug doesn't runSpaces are not stripped from $thenumber before lookup occursHousekeeping
References to github.com/tm1000 on main pageSuggest removing ref to colsolgrp from main pagemouse pointer doesn't change when hovering over clickable links (scheme name and sources) in FreePBX 2.10pls ignore, user error - In Can411 source, single mode returns expected result, but same source in multi mode returns the correct name with multiple spaces separating words. Will a trim() fix this?Link at bottom to the "Modules wiki pages" still points to tm1000Mouseover help for lookup modules not working in FreePBX 2.10When running a debug, is it possible that pressing the enter key in the number field to trigger the debug button?References to colsolgrp in module.xmlIn "Module Admin", this module lists under inbound call control which is misleading, suggest that it be listed under the heading "Other" to match the menu it appears in for FreePBX 2.10{"success":false}
3.x installer should check for the 2.xCaller ID Superfecta
entry inCID Lookup Souces
and remove it. It may be necessary to remove it from all inbound routes tooModules
Lookup source modules that use the 'select' option for $source_param no longer work in v3.x. See Hitta_SELDAP - 'LDAP_server' uses type 'select' and 'LDAP_format' is an undefined typeUser settings for individual lookup source modules are not saved. Entering changes and hitting save it all looks good, but going back it always comes up with the default values.Recommend removing the report back function in "who called" and all other sources that do this.Trunk provided not working alpha4