Patch 7.4.1622
Problem: Channel demo doesn't work with Python 2.6.
Solution: Add number in formatting placeholder
Files: runtime/tools/demoserver.py
*** ../vim-7.4.1621/runtime/tools/demoserver.py 2016-02-02 20:46:29.715412004
+0100
--- runtime/tools/demoserver.py 2016-03-20 18:52:22.025315563 +0100
***************
*** 2,8 ****
#
# Server that will accept connections from a Vim channel.
# Run this server and then in Vim you can open the channel:
! # :let handle = ch_open('localhost:8765', 'json')
#
# Then Vim can send requests to the server:
# :let response = ch_sendexpr(handle, 'hello!')
--- 2,8 ----
#
# Server that will accept connections from a Vim channel.
# Run this server and then in Vim you can open the channel:
! # :let handle = ch_open('localhost:8765')
#
# Then Vim can send requests to the server:
# :let response = ch_sendexpr(handle, 'hello!')
***************
*** 50,56 ****
if data == '':
print("=== socket closed ===")
break
! print("received: {}".format(data))
try:
decoded = json.loads(data)
except ValueError:
--- 50,56 ----
if data == '':
print("=== socket closed ===")
break
! print("received: {0}".format(data))
try:
decoded = json.loads(data)
except ValueError:
***************
*** 65,71 ****
else:
response = "what?"
encoded = json.dumps([decoded[0], response])
! print("sending {}".format(encoded))
self.request.sendall(encoded.encode('utf-8'))
thesocket = None
--- 65,71 ----
else:
response = "what?"
encoded = json.dumps([decoded[0], response])
! print("sending {0}".format(encoded))
self.request.sendall(encoded.encode('utf-8'))
thesocket = None
***************
*** 87,93 ****
server_thread.start()
print("Server loop running in thread: ", server_thread.name)
! print("Listening on port {}".format(PORT))
while True:
typed = sys.stdin.readline()
if "quit" in typed:
--- 87,93 ----
server_thread.start()
print("Server loop running in thread: ", server_thread.name)
! print("Listening on port {0}".format(PORT))
while True:
typed = sys.stdin.readline()
if "quit" in typed:
***************
*** 96,102 ****
if thesocket is None:
print("No socket yet")
else:
! print("sending {}".format(typed))
thesocket.sendall(typed.encode('utf-8'))
server.shutdown()
--- 96,102 ----
if thesocket is None:
print("No socket yet")
else:
! print("sending {0}".format(typed))
thesocket.sendall(typed.encode('utf-8'))
server.shutdown()
*** ../vim-7.4.1621/src/version.c 2016-03-20 18:24:40.502259462 +0100
--- src/version.c 2016-03-20 18:53:12.900796324 +0100
***************
*** 750,751 ****
--- 750,753 ----
{ /* Add new patch number below this line */
+ /**/
+ 1622,
/**/
--
>From "know your smileys":
+<(:-) The Pope
/// Bram Moolenaar -- [email protected] -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.