Trouble connecting to Swank running on android

PR polos.ruetz at gmail.com
Thu Aug 24 12:10:40 UTC 2017


2017-08-24 13:40 GMT+02:00, Luís Oliveira <luismbo at gmail.com>:
> Heh, that's quite bizarre. Keep us posted.

ok, here the next update:

I wasn't really correct with my previous description, so I will be
more precise here:

- I start swank on android (the REPL uses ECL)
- now I connect from the pc, which breaks into the Slime debugger, as
expected (caused by 'break')
- as soon as I click on any function of the  "Backtrace:" list, the
Slime REPL is shown with its usual prompt (here: "EQL-USER>")

The Slime REPL is fully functioning.
Now if I provoke a condition, e.g. (/ 0), the debugger just adds 2
more restarts (as usual), and if I select the top most ABORT, the REPL
keeps functioning.

Of course if I select to abort from 'break' (for the record: set by me
at the start of swank::close-connection%), then I lose the connection
to swank.

Attached you find the fully expanded backtrace. The only condition is
from the inserted break (I clicked on all of the listed ones; it
always says "Break" after FORMAT-CONTROL, (see top of attached file).

In function close-connection (from backtrace), the condition simply says NIL.

I really have no clue so far...




>
> Luís
>
> On Thu, Aug 24, 2017, 10:42 PR <polos.ruetz at gmail.com> wrote:
>
>> 2017-08-23 23:36 GMT+02:00, Luís Oliveira <luismbo at gmail.com>:
>> > you could try to place a break at the start of
>> > swank::close-connection% to see what's triggering it
>>
>> Thank you very much, I'm closer now (although it doesn't work normally
>> yet).
>>
>> If I put a break at the start of swank::close-connection%, Emacs shows
>> the debugger right after I connect to swank; then (and this is
>> strange), after a few seconds, the REPL shows up in the other half of
>> Emacs, and it works!!
>>
>> So, I have now the debugger open, and a functioning REPL (until I
>> continue from the break); but the open debugger doesn't stop the REPL
>> from functioning, and on conditions on the REPL, another debugger
>> instance will show, so I can fully use the REPL.
>>
>> Now I'll need to examine the backtrace carefully...
>>
>> Thanks again,
>>
>> Paul
>>
>>
>> >
>> > HTH,
>> > Luís
>> >
>>
>
-------------- next part --------------
#<simple-condition  bcc6d1b0>
--------------------
Class: #<The STANDARD-CLASS SIMPLE-CONDITION>
--------------------
 Group slots by inheritance [ ]
 Sort slots alphabetically  [X]

All Slots:
[ ]  FORMAT-ARGUMENTS = NIL
[ ]  FORMAT-CONTROL   = "Break"
[ ]  REPORT-FUNCTION  = #<compiled-function bcd4bd80>

[set value]  [make unbound]


===============================================================================


Break
   [Condition of type SIMPLE-CONDITION]

Restarts:
 0: [CONTINUE] Return from BREAK.
 1: [ABORT] ABORT

Backtrace:
  0: #<bytecompiled-function CALL-WITH-DEBUGGING-ENVIRONMENT>
      Locals:
        SWANK/BACKEND::DEBUGGER-LOOP-FN = #<bytecompiled-closure #<bytecompiled-function bc2e4b40>>
        SWANK/BACKEND::F = #<bytecompiled-closure #<bytecompiled-function SWANK/BACKEND:CALL-WITH-DEBUGGING-ENVIRONMENT>>
  1: #<bytecompiled-function DEBUG-IN-EMACS>
      Locals:
        CONDITION = #<a SIMPLE-CONDITION>
  2: #<bytecompiled-function bc2e4fa0>
      Locals:
        CONDITION = #<a SIMPLE-CONDITION>
  3: #<bytecompiled-function CALL-WITH-DEBUGGER-HOOK>
      Locals:
        #:G1234 = SWANK/BACKEND:CALL-WITH-DEBUGGER-HOOK
        #:G1235 = SWANK/BACKEND::IMPLEMENTATION
        SWANK/ECL::HOOK = #<bytecompiled-function SWANK:SWANK-DEBUGGER-HOOK>
        SWANK/ECL::FUN = #<bytecompiled-closure #<bytecompiled-function bc2e4fa0>>
  4: #<bytecompiled-function CALL-WITH-DEBUGGER-HOOK>
      Locals:
        SWANK/BACKEND::HOOK = #<bytecompiled-function SWANK:SWANK-DEBUGGER-HOOK>
        SWANK/BACKEND::FUN = #<bytecompiled-closure #<bytecompiled-function bc2e4fa0>>
        SWANK/BACKEND::F = #<bytecompiled-closure #<bytecompiled-function SWANK/BACKEND:CALL-WITH-DEBUGGER-HOOK>>
  5: #<bytecompiled-function bc2e4f28>
      Locals:
        CONDITION = #<a SIMPLE-CONDITION>
        FUNCTION = #<bytecompiled-closure #<bytecompiled-function bc2e4fa0>>
        SWANK::CONNECTION = #<singlethreaded-connection  bcc6d4f8>
        #:G959 = #<singlethreaded-connection  bcc6d4f8>
        #:G961 = NIL
  6: #<bytecompiled-function CALL-WITH-BINDINGS>
      Locals:
        SWANK::ALIST = NIL
        SWANK::FUN = #<bytecompiled-closure #<bytecompiled-function bc2e4f28>>
  7: #<bytecompiled-function INVOKE-SLIME-DEBUGGER>
      Locals:
        CONDITION = #<a SIMPLE-CONDITION>
        FUNCTION = #<bytecompiled-closure #<bytecompiled-function bc2e4fa0>>
        SWANK::CONNECTION = #<singlethreaded-connection  bcc6d4f8>
        #:G959 = #<singlethreaded-connection  bcc6d4f8>
        #:G961 = NIL
  8: #<bytecompiled-function bc2e4e60>
      Locals:
        CONDITION = #<a SIMPLE-CONDITION>
        SWANK::HOOK = #<bytecompiled-closure #<bytecompiled-function bc1b5de8>>
        #:G967 = NIL
  9: #<bytecompiled-function CALL-WITH-DEBUGGER-HOOK>
      Locals:
        #:G1234 = SWANK/BACKEND:CALL-WITH-DEBUGGER-HOOK
        #:G1235 = SWANK/BACKEND::IMPLEMENTATION
        SWANK/ECL::HOOK = #<bytecompiled-function SWANK:SWANK-DEBUGGER-HOOK>
        SWANK/ECL::FUN = #<bytecompiled-closure #<bytecompiled-function bc2e4e60>>
 10: #<bytecompiled-function CALL-WITH-DEBUGGER-HOOK>
      Locals:
        SWANK/BACKEND::HOOK = #<bytecompiled-function SWANK:SWANK-DEBUGGER-HOOK>
        SWANK/BACKEND::FUN = #<bytecompiled-closure #<bytecompiled-function bc2e4e60>>
        SWANK/BACKEND::F = #<bytecompiled-closure #<bytecompiled-function SWANK/BACKEND:CALL-WITH-DEBUGGER-HOOK>>
 11: #<bytecompiled-function SWANK-DEBUGGER-HOOK>
      Locals:
        CONDITION = #<a SIMPLE-CONDITION>
        SWANK::HOOK = #<bytecompiled-closure #<bytecompiled-function bc1b5de8>>
        #:G967 = NIL
 12: #<bytecompiled-function bc1b5de8>
      Locals:
        SWANK/ECL::HOOK = #<bytecompiled-function SWANK:SWANK-DEBUGGER-HOOK>
        CONDITION = #<a SIMPLE-CONDITION>
        SWANK/ECL::OLD-HOOK = #<bytecompiled-closure #<bytecompiled-function bc1b5de8>>
 13: #<bytecompiled-function CLOSE-CONNECTION%>
      Locals:
        SWANK::C = #<singlethreaded-connection  bcc6d4f8>
        CONDITION = NIL
        SWANK:BACKTRACE = ((0 "#<bytecompiled-function CALL-WITH-DEBUGGING-ENVIRONMENT>") (1 "#<bytecompiled-function SAFE-BACKTRACE>") (2 "#<bytecompiled-function SIMPLE-SERVE-REQUESTS>") ..)
 14: #<bytecompiled-function SENTINEL-SERVE>
      Locals:
        SWANK::MSG = (:CLOSE-CONNECTION #<singlethreaded-connection  bcc6d4f8> NIL ..)
        #:|tmp-384| = (:CLOSE-CONNECTION #<singlethreaded-connection  bcc6d4f8> NIL ..)
        #:|op-382| = :CLOSE-CONNECTION
        #:|rand-383| = (#<singlethreaded-connection  bcc6d4f8> NIL ..)
        #:G388 = (#<singlethreaded-connection  bcc6d4f8> NIL ..)
        #:G389 = NIL
        SWANK::CONNECTION = #<singlethreaded-connection  bcc6d4f8>
        CONDITION = NIL
        SWANK:BACKTRACE = ((0 "#<bytecompiled-function CALL-WITH-DEBUGGING-ENVIRONMENT>") (1 "#<bytecompiled-function SAFE-BACKTRACE>") (2 "#<bytecompiled-function SIMPLE-SERVE-REQUESTS>") ..)
 15: #<bytecompiled-function SEND-TO-SENTINEL>
      Locals:
        SWANK::MSG = (:CLOSE-CONNECTION #<singlethreaded-connection  bcc6d4f8> NIL ..)
        SWANK::SENTINEL = NIL
 16: #<bytecompiled-function CLOSE-CONNECTION>
      Locals:
        SWANK::CONNECTION = #<singlethreaded-connection  bcc6d4f8>
        CONDITION = NIL
        SWANK:BACKTRACE = ((0 "#<bytecompiled-function CALL-WITH-DEBUGGING-ENVIRONMENT>") (1 "#<bytecompiled-function SAFE-BACKTRACE>") (2 "#<bytecompiled-function SIMPLE-SERVE-REQUESTS>") ..)
 17: #<bytecompiled-function SIMPLE-SERVE-REQUESTS>
      Locals:
        SWANK::CONNECTION = #<singlethreaded-connection  bcc6d4f8>
 18: #<bytecompiled-function SERVE-REQUESTS>
      Locals:
        SWANK::CONNECTION = #<singlethreaded-connection  bcc6d4f8>
        #:G438 = #<singlethreaded-connection  bcc6d4f8>
        #:G439 = NIL
 19: #<bytecompiled-function ACCEPT-CONNECTIONS>
      Locals:
        SWANK::SOCKET = #<inet-socket descriptor 26 bc94b018>
        SWANK::STYLE = NIL
        SWANK::DONT-CLOSE = T
        SWANK::CLIENT = #<two-way stream bc968268>
 20: #<bytecompiled-function SERVE>
      Locals:
        SWANK::PORT = 4005
        SWANK::ANNOUNCE-FN = #<bytecompiled-function SWANK::SIMPLE-ANNOUNCE-FUNCTION>
        SWANK::STYLE = NIL
        SWANK::DONT-CLOSE = T
        SWANK::BACKLOG = NIL
        SWANK::SOCKET = #<inet-socket descriptor 26 bc94b018>
        SWANK::PORT = 4005
 21: #<bytecompiled-function SERVE-LOOP>
      Locals:
        SWANK::PORT = 4005
        SWANK::ANNOUNCE-FN = #<bytecompiled-function SWANK::SIMPLE-ANNOUNCE-FUNCTION>
        SWANK::STYLE = NIL
        SWANK::DONT-CLOSE = T
        SWANK::BACKLOG = NIL
        SWANK::SOCKET = #<inet-socket descriptor 26 bc94b018>
        SWANK::PORT = 4005
 22: #<bytecompiled-function SETUP-SERVER>
      Locals:
        SWANK::PORT = 4005
        SWANK::ANNOUNCE-FN = #<bytecompiled-function SWANK::SIMPLE-ANNOUNCE-FUNCTION>
        SWANK::STYLE = NIL
        SWANK::DONT-CLOSE = T
        SWANK::BACKLOG = NIL
        SWANK::SOCKET = #<inet-socket descriptor 26 bc94b018>
        SWANK::PORT = 4005
        #:G435 = NIL
 23: #<bytecompiled-function CREATE-SERVER>
      Locals:
        SWANK::PORT = 4005
        SWANK::STYLE = NIL
        SWANK::DONT-CLOSE = T
        SWANK::INTERFACE = NIL
        SWANK::BACKLOG = NIL
 24: NIL



More information about the slime-devel mailing list