call time limitation

classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

call time limitation

ik_5
Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/groups/opt_out.
 
 
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Ben Langfeld
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <[hidden email]> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/groups/opt_out.
 
 
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Giorgio Bianchi
I'm facing a problem with this : if an outbound call uses these instructions, it crashes when the timeout occurs. Please help me.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Il giorno mercoledì 22 maggio 2013 13:20:53 UTC+2, Ben Langfeld ha scritto:
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="oSnEUJdLSQ0J" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">ido...@...> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="oSnEUJdLSQ0J" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank" onmousedown="this.href='https://groups.google.com/groups/opt_out';return true;" onclick="this.href='https://groups.google.com/groups/opt_out';return true;">https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Ben Langfeld-2
Please provide code to reproduce this issue. Also, is that really the entire stack trace?

On 11 November 2014 10:42, Giorgio Bianchi <[hidden email]> wrote:
I'm facing a problem with this : if an outbound call uses these instructions, it crashes when the timeout occurs. Please help me.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Il giorno mercoledì 22 maggio 2013 13:20:53 UTC+2, Ben Langfeld ha scritto:
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <[hidden email]> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Giorgio Bianchi
The call is started using drb, here is an example :

Method in adhearsion drb shared object :

def start_call
  call
= Adhearsion::OutboundCall.new.tap do |call|
    call
.execute_controller_or_router_on_answer 'Test'
    call
.dial '1234'
 
end
end


Call controller example :

class Test < Adhearsion::CallController
 
def run
    call
.after(30) { hangup }
    play
"longmessage.wav"
    hangup
 
end
end


This happens when the call is answered and timeout occours.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
       
/usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.058] ERROR Adhearsion::Calls::Supervisor: Call 38e5f23c-f72f-4c9d-85ce-9de11c02fcab terminated abnormally due to no receiver given. Forcing hangup.
[2014-11-11 13:37:53.058] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
       
/usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.066] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
       
/usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'


Il giorno martedì 11 novembre 2014 13:48:44 UTC+1, Ben Langfeld ha scritto:
Please provide code to reproduce this issue. Also, is that really the entire stack trace?

On 11 November 2014 10:42, Giorgio Bianchi <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="9WQiEXRjp3wJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">gggg.b...@...> wrote:
I'm facing a problem with this : if an outbound call uses these instructions, it crashes when the timeout occurs. Please help me.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Il giorno mercoledì 22 maggio 2013 13:20:53 UTC+2, Ben Langfeld ha scritto:
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <[hidden email]> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank" onmousedown="this.href='https://groups.google.com/groups/opt_out';return true;" onclick="this.href='https://groups.google.com/groups/opt_out';return true;">https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="9WQiEXRjp3wJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Ben Klang-2

Il giorno Nov 11, 2014, alle ore 3:03 PM, Giorgio Bianchi <[hidden email]> ha scritto:

The call is started using drb, here is an example :

Method in adhearsion drb shared object :

def start_call
  call = Adhearsion::OutboundCall.new.tap do |call|
    call.execute_controller_or_router_on_answer 'Test'
    call.dial '1234'
  end
end


The stack trace is really not terribly helpful is it? I’m not 100% certain, but I suspect your problem is the “execute_controller_or_router_on_answer” call.

Here’s the method prototype:


The argument you are passing is a string, but it’s expecting either an CallController class or a block.  Try something like this:

call.execute_controller_or_router_on_answer Test # note there are no quotes around Test

Also, make sure you’ve require’d the ‘test.rb’ that contains your call controller, just to make sure it gets loaded first.

/BAK/
-- 
Ben Klang
Principal/Technology Strategist, Mojo Lingo
+1.404.475.4841

Mojo Lingo -- Voice applications that work like magic
Twitter: @MojoLingo


Call controller example :

class Test < Adhearsion::CallController
  def run
    call.after(30) { hangup }
    play "longmessage.wav"
    hangup
  end
end


This happens when the call is answered and timeout occours.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.058] ERROR Adhearsion::Calls::Supervisor: Call 38e5f23c-f72f-4c9d-85ce-9de11c02fcab terminated abnormally due to no receiver given. Forcing hangup.
[2014-11-11 13:37:53.058] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.066] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'


Il giorno martedì 11 novembre 2014 13:48:44 UTC+1, Ben Langfeld ha scritto:
Please provide code to reproduce this issue. Also, is that really the entire stack trace?

On 11 November 2014 10:42, Giorgio Bianchi <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="9WQiEXRjp3wJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;" class="">gggg.b...@...> wrote:
I'm facing a problem with this : if an outbound call uses these instructions, it crashes when the timeout occurs. Please help me.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Il giorno mercoledì 22 maggio 2013 13:20:53 UTC+2, Ben Langfeld ha scritto:
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <[hidden email]> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank" onmousedown="this.href='https://groups.google.com/groups/opt_out';return true;" onclick="this.href='https://groups.google.com/groups/opt_out';return true;" class="">https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="9WQiEXRjp3wJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;" class="">adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;" class="">https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

signature.asc (858 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Giorgio Bianchi
This is just an example of how to start and contains some inaccuracies. Even with the corrections, the problem occurs. The call start and works well but when the timeout occurs, the reported errors are triggered.

Il giorno martedì 11 novembre 2014 21:18:38 UTC+1, Ben Klang ha scritto:

Il giorno Nov 11, 2014, alle ore 3:03 PM, Giorgio Bianchi <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="cvig1EZg4pAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">gggg.b...@...> ha scritto:

The call is started using drb, here is an example :

Method in adhearsion drb shared object :

def start_call
  call = Adhearsion::OutboundCall.new.tap do |call|
    call.execute_controller_or_router_on_answer 'Test'
    call.dial '1234'
  end
end


The stack trace is really not terribly helpful is it? I’m not 100% certain, but I suspect your problem is the “execute_controller_or_router_on_answer” call.

Here’s the method prototype:

<a href="http://www.rubydoc.info/gems/adhearsion/Adhearsion/OutboundCall#execute_controller_or_router_on_answer-instance_method" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fwww.rubydoc.info%2Fgems%2Fadhearsion%2FAdhearsion%2FOutboundCall%23execute_controller_or_router_on_answer-instance_method\46sa\75D\46sntz\0751\46usg\75AFQjCNFzg9icS91teLIXPK7b14yc6w5ojg';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fwww.rubydoc.info%2Fgems%2Fadhearsion%2FAdhearsion%2FOutboundCall%23execute_controller_or_router_on_answer-instance_method\46sa\75D\46sntz\0751\46usg\75AFQjCNFzg9icS91teLIXPK7b14yc6w5ojg';return true;">http://www.rubydoc.info/gems/adhearsion/Adhearsion/OutboundCall#execute_controller_or_router_on_answer-instance_method

The argument you are passing is a string, but it’s expecting either an CallController class or a block.  Try something like this:

call.execute_controller_or_router_on_answer Test # note there are no quotes around Test

Also, make sure you’ve require’d the ‘test.rb’ that contains your call controller, just to make sure it gets loaded first.

/BAK/
-- 
Ben Klang
Principal/Technology Strategist, Mojo Lingo
<a href="javascript:" target="_blank" gdf-obfuscated-mailto="cvig1EZg4pAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">bkl...@...
+1.404.475.4841

Mojo Lingo -- Voice applications that work like magic
<a href="http://mojolingo.com/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;">http://mojolingo.com
Twitter: @MojoLingo


Call controller example :

class Test < Adhearsion::CallController
  def run
    call.after(30) { hangup }
    play "longmessage.wav"
    hangup
  end
end


This happens when the call is answered and timeout occours.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.058] ERROR Adhearsion::Calls::Supervisor: Call 38e5f23c-f72f-4c9d-85ce-9de11c02fcab terminated abnormally due to no receiver given. Forcing hangup.
[2014-11-11 13:37:53.058] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.066] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'


Il giorno martedì 11 novembre 2014 13:48:44 UTC+1, Ben Langfeld ha scritto:
Please provide code to reproduce this issue. Also, is that really the entire stack trace?

On 11 November 2014 10:42, Giorgio Bianchi <[hidden email]> wrote:
I'm facing a problem with this : if an outbound call uses these instructions, it crashes when the timeout occurs. Please help me.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Il giorno mercoledì 22 maggio 2013 13:20:53 UTC+2, Ben Langfeld ha scritto:
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <[hidden email]> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank" onmousedown="this.href='https://groups.google.com/groups/opt_out';return true;" onclick="this.href='https://groups.google.com/groups/opt_out';return true;">https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="cvig1EZg4pAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Ben Klang-2

Il giorno Nov 13, 2014, alle ore 6:59 PM, Giorgio Bianchi <[hidden email]> ha scritto:

This is just an example of how to start and contains some inaccuracies. Even with the corrections, the problem occurs. The call start and works well but when the timeout occurs, the reported errors are triggered.


If this example isn’t the actual code that’s failing, it’s much harder to guess at what the problem is.

Would you collect the code that’s causing the issue, along with TRACE level logs, and put them into a gist? https://gist.github.com

It will be much easier if we can see all the information with line numbers at the same time. Otherwise we’re not really sure what we’re debugging.

/BAK/
-- 
Ben Klang
Principal/Technology Strategist, Mojo Lingo
+1.404.475.4841

Mojo Lingo -- Voice applications that work like magic
Twitter: @MojoLingo

Il giorno martedì 11 novembre 2014 21:18:38 UTC+1, Ben Klang ha scritto:

Il giorno Nov 11, 2014, alle ore 3:03 PM, Giorgio Bianchi <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="cvig1EZg4pAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;" class="">gggg.b...@...> ha scritto:

The call is started using drb, here is an example :

Method in adhearsion drb shared object :

def start_call
  call = Adhearsion::OutboundCall.new.tap do |call|
    call.execute_controller_or_router_on_answer 'Test'
    call.dial '1234'
  end
end


The stack trace is really not terribly helpful is it? I’m not 100% certain, but I suspect your problem is the “execute_controller_or_router_on_answer” call.

Here’s the method prototype:

<a href="http://www.rubydoc.info/gems/adhearsion/Adhearsion/OutboundCall#execute_controller_or_router_on_answer-instance_method" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fwww.rubydoc.info%2Fgems%2Fadhearsion%2FAdhearsion%2FOutboundCall%23execute_controller_or_router_on_answer-instance_method\46sa\75D\46sntz\0751\46usg\75AFQjCNFzg9icS91teLIXPK7b14yc6w5ojg';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fwww.rubydoc.info%2Fgems%2Fadhearsion%2FAdhearsion%2FOutboundCall%23execute_controller_or_router_on_answer-instance_method\46sa\75D\46sntz\0751\46usg\75AFQjCNFzg9icS91teLIXPK7b14yc6w5ojg';return true;" class="">http://www.rubydoc.info/gems/adhearsion/Adhearsion/OutboundCall#execute_controller_or_router_on_answer-instance_method

The argument you are passing is a string, but it’s expecting either an CallController class or a block.  Try something like this:

call.execute_controller_or_router_on_answer Test # note there are no quotes around Test

Also, make sure you’ve require’d the ‘test.rb’ that contains your call controller, just to make sure it gets loaded first.

/BAK/
-- 
Ben Klang
Principal/Technology Strategist, Mojo Lingo
<a href="javascript:" target="_blank" gdf-obfuscated-mailto="cvig1EZg4pAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;" class="">bkl...@...
+1.404.475.4841

Mojo Lingo -- Voice applications that work like magic
<a href="http://mojolingo.com/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;" class="">http://mojolingo.com
Twitter: @MojoLingo


Call controller example :

class Test < Adhearsion::CallController
  def run
    call.after(30) { hangup }
    play "longmessage.wav"
    hangup
  end
end


This happens when the call is answered and timeout occours.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.058] ERROR Adhearsion::Calls::Supervisor: Call 38e5f23c-f72f-4c9d-85ce-9de11c02fcab terminated abnormally due to no receiver given. Forcing hangup.
[2014-11-11 13:37:53.058] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.066] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'


Il giorno martedì 11 novembre 2014 13:48:44 UTC+1, Ben Langfeld ha scritto:
Please provide code to reproduce this issue. Also, is that really the entire stack trace?

On 11 November 2014 10:42, Giorgio Bianchi <[hidden email]> wrote:
I'm facing a problem with this : if an outbound call uses these instructions, it crashes when the timeout occurs. Please help me.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Il giorno mercoledì 22 maggio 2013 13:20:53 UTC+2, Ben Langfeld ha scritto:
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <[hidden email]> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank" onmousedown="this.href='https://groups.google.com/groups/opt_out';return true;" onclick="this.href='https://groups.google.com/groups/opt_out';return true;" class="">https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;" class="">https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="cvig1EZg4pAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;" class="">adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;" class="">https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.


signature.asc (858 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Giorgio Bianchi
I've found the problem : celluloid rescue the exception raised by the call controller hangup method and manage it like a call crash.
There is a workaround :

call.after(10.seconds) do

 
begin
    hangup
 
rescue => e
    logger
.info "!!!Call timeout triggered!!!"
 
end
end

Hope this helps.

Il giorno giovedì 13 novembre 2014 21:46:23 UTC+1, Ben Klang ha scritto:

Il giorno Nov 13, 2014, alle ore 6:59 PM, Giorgio Bianchi <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="9WdeWv8P9KAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">gggg.b...@...> ha scritto:

This is just an example of how to start and contains some inaccuracies. Even with the corrections, the problem occurs. The call start and works well but when the timeout occurs, the reported errors are triggered.


If this example isn’t the actual code that’s failing, it’s much harder to guess at what the problem is.

Would you collect the code that’s causing the issue, along with TRACE level logs, and put them into a gist? <a href="https://gist.github.com" target="_blank" onmousedown="this.href='https://www.google.com/url?q\75https%3A%2F%2Fgist.github.com\46sa\75D\46sntz\0751\46usg\75AFQjCNGbQPJUwexo1pHRYrizhfMG1_9Z_A';return true;" onclick="this.href='https://www.google.com/url?q\75https%3A%2F%2Fgist.github.com\46sa\75D\46sntz\0751\46usg\75AFQjCNGbQPJUwexo1pHRYrizhfMG1_9Z_A';return true;">https://gist.github.com

It will be much easier if we can see all the information with line numbers at the same time. Otherwise we’re not really sure what we’re debugging.

/BAK/
-- 
Ben Klang
Principal/Technology Strategist, Mojo Lingo
<a href="javascript:" target="_blank" gdf-obfuscated-mailto="9WdeWv8P9KAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">bkl...@...
+1.404.475.4841

Mojo Lingo -- Voice applications that work like magic
<a href="http://mojolingo.com/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;">http://mojolingo.com
Twitter: @MojoLingo

Il giorno martedì 11 novembre 2014 21:18:38 UTC+1, Ben Klang ha scritto:

Il giorno Nov 11, 2014, alle ore 3:03 PM, Giorgio Bianchi <[hidden email]> ha scritto:

The call is started using drb, here is an example :

Method in adhearsion drb shared object :

def start_call
  call = Adhearsion::OutboundCall.new.tap do |call|
    call.execute_controller_or_router_on_answer 'Test'
    call.dial '1234'
  end
end


The stack trace is really not terribly helpful is it? I’m not 100% certain, but I suspect your problem is the “execute_controller_or_router_on_answer” call.

Here’s the method prototype:

<a href="http://www.rubydoc.info/gems/adhearsion/Adhearsion/OutboundCall#execute_controller_or_router_on_answer-instance_method" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fwww.rubydoc.info%2Fgems%2Fadhearsion%2FAdhearsion%2FOutboundCall%23execute_controller_or_router_on_answer-instance_method\46sa\75D\46sntz\0751\46usg\75AFQjCNFzg9icS91teLIXPK7b14yc6w5ojg';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fwww.rubydoc.info%2Fgems%2Fadhearsion%2FAdhearsion%2FOutboundCall%23execute_controller_or_router_on_answer-instance_method\46sa\75D\46sntz\0751\46usg\75AFQjCNFzg9icS91teLIXPK7b14yc6w5ojg';return true;">http://www.rubydoc.info/gems/adhearsion/Adhearsion/OutboundCall#execute_controller_or_router_on_answer-instance_method

The argument you are passing is a string, but it’s expecting either an CallController class or a block.  Try something like this:

call.execute_controller_or_router_on_answer Test # note there are no quotes around Test

Also, make sure you’ve require’d the ‘test.rb’ that contains your call controller, just to make sure it gets loaded first.

/BAK/
-- 
Ben Klang
Principal/Technology Strategist, Mojo Lingo
+1.404.475.4841

Mojo Lingo -- Voice applications that work like magic
<a href="http://mojolingo.com/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;">http://mojolingo.com
Twitter: @MojoLingo


Call controller example :

class Test < Adhearsion::CallController
  def run
    call.after(30) { hangup }
    play "longmessage.wav"
    hangup
  end
end


This happens when the call is answered and timeout occours.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.058] ERROR Adhearsion::Calls::Supervisor: Call 38e5f23c-f72f-4c9d-85ce-9de11c02fcab terminated abnormally due to no receiver given. Forcing hangup.
[2014-11-11 13:37:53.058] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.066] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'


Il giorno martedì 11 novembre 2014 13:48:44 UTC+1, Ben Langfeld ha scritto:
Please provide code to reproduce this issue. Also, is that really the entire stack trace?

On 11 November 2014 10:42, Giorgio Bianchi <[hidden email]> wrote:
I'm facing a problem with this : if an outbound call uses these instructions, it crashes when the timeout occurs. Please help me.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Il giorno mercoledì 22 maggio 2013 13:20:53 UTC+2, Ben Langfeld ha scritto:
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <[hidden email]> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank" onmousedown="this.href='https://groups.google.com/groups/opt_out';return true;" onclick="this.href='https://groups.google.com/groups/opt_out';return true;">https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="9WdeWv8P9KAJ" onmousedown="this.href='javascript:';return true;" onclick="this.href='javascript:';return true;">adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: call time limitation

Giorgio Bianchi
Sorry, that's not enough...
I think that the Adhearsion::Call::Hangup exception must pass to let Adhearsion works properly.
Rescue this exception causes other problems.

class ConfirmationController < Adhearsion::CallController
 
def run
    call
.after(1.seconds) {hangup}
    say
"Incoming call from #{call.from}. Hang up now to reject the call."
 
end
end


class SuperSecretProjectCall < Adhearsion::CallController
 
def run
    answer
    call
.after(5.seconds) {hangup}
    dial
'sip:[hidden email]', confirm: ConfirmationController, for: 10.seconds
    say
"We hope you had a nice chat!"
 
end
end

If you try Adhearsion examples adding timers, you'll see all the exceptions.
I think this must be handled in celluloid.

Il giorno venerdì 19 dicembre 2014 11:12:17 UTC+1, Giorgio Bianchi ha scritto:
I've found the problem : celluloid rescue the exception raised by the call controller hangup method and manage it like a call crash.
There is a workaround :

call.after(10.seconds) do

 
begin
    hangup
 
rescue => e
    logger
.info "!!!Call timeout triggered!!!"
 
end
end

Hope this helps.

Il giorno giovedì 13 novembre 2014 21:46:23 UTC+1, Ben Klang ha scritto:

Il giorno Nov 13, 2014, alle ore 6:59 PM, Giorgio Bianchi <[hidden email]> ha scritto:

This is just an example of how to start and contains some inaccuracies. Even with the corrections, the problem occurs. The call start and works well but when the timeout occurs, the reported errors are triggered.


If this example isn’t the actual code that’s failing, it’s much harder to guess at what the problem is.

Would you collect the code that’s causing the issue, along with TRACE level logs, and put them into a gist? <a href="https://gist.github.com" target="_blank" onmousedown="this.href='https://www.google.com/url?q\75https%3A%2F%2Fgist.github.com\46sa\75D\46sntz\0751\46usg\75AFQjCNGbQPJUwexo1pHRYrizhfMG1_9Z_A';return true;" onclick="this.href='https://www.google.com/url?q\75https%3A%2F%2Fgist.github.com\46sa\75D\46sntz\0751\46usg\75AFQjCNGbQPJUwexo1pHRYrizhfMG1_9Z_A';return true;">https://gist.github.com

It will be much easier if we can see all the information with line numbers at the same time. Otherwise we’re not really sure what we’re debugging.

/BAK/
-- 
Ben Klang
Principal/Technology Strategist, Mojo Lingo
+1.404.475.4841

Mojo Lingo -- Voice applications that work like magic
<a href="http://mojolingo.com/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;">http://mojolingo.com
Twitter: @MojoLingo

Il giorno martedì 11 novembre 2014 21:18:38 UTC+1, Ben Klang ha scritto:

Il giorno Nov 11, 2014, alle ore 3:03 PM, Giorgio Bianchi <[hidden email]> ha scritto:

The call is started using drb, here is an example :

Method in adhearsion drb shared object :

def start_call
  call = Adhearsion::OutboundCall.new.tap do |call|
    call.execute_controller_or_router_on_answer 'Test'
    call.dial '1234'
  end
end


The stack trace is really not terribly helpful is it? I’m not 100% certain, but I suspect your problem is the “execute_controller_or_router_on_answer” call.

Here’s the method prototype:

<a href="http://www.rubydoc.info/gems/adhearsion/Adhearsion/OutboundCall#execute_controller_or_router_on_answer-instance_method" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fwww.rubydoc.info%2Fgems%2Fadhearsion%2FAdhearsion%2FOutboundCall%23execute_controller_or_router_on_answer-instance_method\46sa\75D\46sntz\0751\46usg\75AFQjCNFzg9icS91teLIXPK7b14yc6w5ojg';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fwww.rubydoc.info%2Fgems%2Fadhearsion%2FAdhearsion%2FOutboundCall%23execute_controller_or_router_on_answer-instance_method\46sa\75D\46sntz\0751\46usg\75AFQjCNFzg9icS91teLIXPK7b14yc6w5ojg';return true;">http://www.rubydoc.info/gems/adhearsion/Adhearsion/OutboundCall#execute_controller_or_router_on_answer-instance_method

The argument you are passing is a string, but it’s expecting either an CallController class or a block.  Try something like this:

call.execute_controller_or_router_on_answer Test # note there are no quotes around Test

Also, make sure you’ve require’d the ‘test.rb’ that contains your call controller, just to make sure it gets loaded first.

/BAK/
-- 
Ben Klang
Principal/Technology Strategist, Mojo Lingo
+1.404.475.4841

Mojo Lingo -- Voice applications that work like magic
<a href="http://mojolingo.com/" target="_blank" onmousedown="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;" onclick="this.href='http://www.google.com/url?q\75http%3A%2F%2Fmojolingo.com%2F\46sa\75D\46sntz\0751\46usg\75AFQjCNEdz1VI9Wu7PPmqtzifmF6XsODIog';return true;">http://mojolingo.com
Twitter: @MojoLingo


Call controller example :

class Test < Adhearsion::CallController
  def run
    call.after(30) { hangup }
    play "longmessage.wav"
    hangup
  end
end


This happens when the call is answered and timeout occours.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.058] ERROR Adhearsion::Calls::Supervisor: Call 38e5f23c-f72f-4c9d-85ce-9de11c02fcab terminated abnormally due to no receiver given. Forcing hangup.
[2014-11-11 13:37:53.058] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

[2014-11-11 13:37:53.066] ERROR Adhearsion::Initializer: <ArgumentError> no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `
block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'


Il giorno martedì 11 novembre 2014 13:48:44 UTC+1, Ben Langfeld ha scritto:
Please provide code to reproduce this issue. Also, is that really the entire stack trace?

On 11 November 2014 10:42, Giorgio Bianchi <[hidden email]> wrote:
I'm facing a problem with this : if an outbound call uses these instructions, it crashes when the timeout occurs. Please help me.

[2014-11-11 13:37:53.054] ERROR Celluloid: Adhearsion::OutboundCall crashed!
ArgumentError: no receiver given
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/actor.rb:416:in `block in task'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks.rb:55:in `block in initialize'
        /usr/local/rvm/gems/ruby-2.1.3/gems/celluloid-0.15.2/lib/celluloid/tasks/task_fiber.rb:13:in `block in create'

Il giorno mercoledì 22 maggio 2013 13:20:53 UTC+2, Ben Langfeld ha scritto:
call.after(30) { hangup }

Regards,
Ben Langfeld

Em 22/05/2013, às 07:30, ik <[hidden email]> escreveu:

Hello,

How can I limit the amount of time for an incoming call from ahn code ?

Thanks,
Ido

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/groups/opt_out" target="_blank" onmousedown="this.href='https://groups.google.com/groups/opt_out';return true;" onclick="this.href='https://groups.google.com/groups/opt_out';return true;">https://groups.google.com/groups/opt_out.
 
 

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.


--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to adhearsion+...@googlegroups.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" onmousedown="this.href='https://groups.google.com/d/optout';return true;" onclick="this.href='https://groups.google.com/d/optout';return true;">https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "Adhearsion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.