Firstly this has been solved. the post is to understand the logic.
On a system with a pair of wctdm24xxx cards (39 fxs ports) we had the situation of 0 would get the operator but any other digit 1st failed. In the cli we saw the extension immediately dialled.
The error was tracked down to this in the extensions.conf file under internal
_[*#0-9]!,1,agi(sarkhpe,OutCos,\${EXTEN},,)\n"
The ! mark means do not wait but process now. If we edited the extensions.conf file the adjustment was lost as soon as the configuration was reloaded.
We eventually found it came from the generator/extensions.php
// Class Of Service and Tenants if they are enabled
//
if ($global['COSSTART'] == "ON") {
/*
$OUT .= "\texten => _X.,1,agi(sarkhpe,OutCos,\${EXTEN},,)\n";
$OUT .= "\texten => _[+*]X.,1,agi(sarkhpe,OutCos,\${EXTEN},,)\n";
$OUT .= "\texten => _**X.,1,agi(sarkhpe,OutCos,\${EXTEN},,)\n";
$OUT .= "\texten => _***X.,1,agi(sarkhpe,OutCos,\${EXTEN},,)\n";
*/
$OUT .= "\texten => _[*#0-9]!,1,agi(sarkhpe,OutCos,\${EXTEN},,)\n";
}
elseif ($global['CLUSTER'] == "ON") {
/*
$OUT .= "\texten => _X.,1,agi(sarkhpe,OutCluster,\${EXTEN},,)\n";
$OUT .= "\texten => _[+*]X.,1,agi(sarkhpe,OutCluster,\${EXTEN},,)\n";
$OUT .= "\texten => _**X.,1,agi(sarkhpe,OutCluster,\${EXTEN},,)\n";
$OUT .= "\texten => _***X.,1,agi(sarkhpe,OutCluster,\${EXTEN},,)\n";
*/
$OUT .= "\texten => _[*#0-9]!,1,agi(sarkhpe,OutCluster,\${EXTEN},,)\n";
}
else {
$OUT .= "\tinclude => qrxvtmny \n";
}
$OUT .= "\n\texten => " . $global['OPERATOR'] . ",1,Goto(extensions,\${SYSOP},1)\n\n";
So turning on the COS box in the globals/services box generated to single digit code.
The question is this an error or was the code meant to do something else?