This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: asynchat documentation needs to be more precise
Type: Stage: resolved
Components: Documentation Versions: Python 3.5
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: BreamoreBoy, beazley, docs@python, georg.brandl, giampaolo.rodola, josiah.carlson, martin.panter, matrixise, nitika, r.david.murray
Priority: normal Keywords: patch

Created on 2008-12-25 01:22 by beazley, last changed 2022-04-11 14:56 by admin. This issue is now closed.

File name Uploaded Description Edit
issue4744_2.patch nitika, 2014-03-16 16:57
issue4744_3.patch nitika, 2014-03-19 18:58
Messages (21)
msg78277 - (view) Author: David M. Beazley (beazley) Date: 2008-12-25 01:22
The documentation for asynchat needs to be more precise in its use of 
strings vs. bytes.   Unless the undocumented use_encoding attribute is 
set, it seems that all data should be bytes throughout (e.g., the 
terminator, inputs to push methods, etc.).  

I have no idea if the use_encoding attribute is officially blessed or 
not.  However, to avoid "magic behavior", I'm guessing that it would be 
better practice to be explicit in one's use of bytes vs. text rather 
than having take place in the internals of asynchat.   Advice welcome.
msg112137 - (view) Author: Mark Lawrence (BreamoreBoy) * Date: 2010-07-31 11:35
Is there anyone with knowledge of asynchat who could provide a patch for this?
msg213709 - (view) Author: Nitika Agarwal (nitika) * Date: 2014-03-16 04:41
I would like to propose a patch for this issue.
msg213738 - (view) Author: Nitika Agarwal (nitika) * Date: 2014-03-16 16:57
Please review my patch attached.Any comments and feedback are welcome.
msg214125 - (view) Author: Nitika Agarwal (nitika) * Date: 2014-03-19 18:58
Attached patch with some corrections
msg215609 - (view) Author: Nitika Agarwal (nitika) * Date: 2014-04-05 13:51
I hvae attached the patch for review.I am waiting for reviewal.Please review the attached patch as soon as possible.
msg216157 - (view) Author: Stéphane Wirtel (matrixise) * (Python committer) Date: 2014-04-14 18:29
Could you review your patch, there is a mistake in the name of the project, it's asynchat and not asychat. The content seems to be right, not the reference and the title.

Thank you so much for your help.
msg216566 - (view) Author: Nitika Agarwal (nitika) * Date: 2014-04-16 19:47
@Stéphane Wirtel (matrixise)
I am really sorry but i just couldn't find where have i done a typo and have written 'asychat' insstead of asynchat.Will you please help me out in pointing out my error.
msg216586 - (view) Author: Stéphane Wirtel (matrixise) * (Python committer) Date: 2014-04-16 20:48
In your issue4744_2.patch, the anchor contains 'asychat' and not 'asynchat'.
msg216667 - (view) Author: Nitika Agarwal (nitika) * Date: 2014-04-17 07:13
But then I have submitted another patch issue4744_3 with the corrections.Please review my patch issue4744_3.patch
msg216881 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2014-04-19 21:26
The change covered by the patch (which patch rejected as garbage, by the way, I have no idea why) has already been applied by Serhiy Storchaka, apparently as a blanket change of 'empty string' to 'empty bytes object'.

There are several other places in the asynchat doc page that mention string.  I suspect that none of them is correct, but I haven't read through the page to be sure.
msg255091 - (view) Author: Stéphane Wirtel (matrixise) * (Python committer) Date: 2015-11-22 10:33
Ping, what's the status of this issue ? maybe we can close it and open an new one with a new description.
msg255112 - (view) Author: Martin Panter (martin.panter) * (Python committer) Date: 2015-11-22 21:53
I think it would be okay to keep this issue open to address the other mentions of “strings”.

Nitika’s patch is missing the special --- and @@ indicator lines at the top, which is probably why it was rejected. Usually you make a patch by using a “diff” command (standalone, with Mercurial, etc).
msg255161 - (view) Author: Stéphane Wirtel (matrixise) * (Python committer) Date: 2015-11-23 14:07
Hi Martin,

About the patch of Nikita, I am going to rewrite it asap.

Will you have time to check it ?

Stéphane Wirtel - - @matrixise
msg255180 - (view) Author: Mark Lawrence (BreamoreBoy) * Date: 2015-11-23 15:51
Does it make sense to spend time updating the asychat docs when states "Note. This module exists for backwards compatibility only. For new code we recommend using asyncio."?
msg255187 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2015-11-23 16:34
Yes.  The docs should be accurate, even if the module is deprecated.
msg255188 - (view) Author: Stéphane Wirtel (matrixise) * (Python committer) Date: 2015-11-23 16:38
Ok, in this case, I will provide the patch 

On 11/23, R. David Murray wrote:
> R. David Murray added the comment:
> Yes.  The docs should be accurate, even if the module is deprecated.
> ----------
> _______________________________________
> Python tracker <>
> <>
> _______________________________________
> _______________________________________________
> Python-bugs-list mailing list
> Unsubscribe:
msg255191 - (view) Author: Stéphane Wirtel (matrixise) * (Python committer) Date: 2015-11-23 16:52
Martin, About the patch of Nikita, this one has already been applied. I have
checked the source.

David, maybe we should close this issue. And open a new one if we find
an other issue in the documentation.

What do you suggest? Should I continue on this issue?
msg255199 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2015-11-23 17:18
If you've read through the asynchat docs and don't think any of the other mentions of string are incorrect or ambiguous, then we should close it.
msg255204 - (view) Author: Stéphane Wirtel (matrixise) * (Python committer) Date: 2015-11-23 17:45
For my part, you can close this issue. I have read the asynchat.rst and files and think the rest of the documentation is clear.
msg255221 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2015-11-23 20:38
OK, let's close it then.  If someone finds something wrong they can open a new issue.
Date User Action Args
2022-04-11 14:56:43adminsetgithub: 48994
2015-11-23 20:38:37r.david.murraysetstatus: open -> closed
resolution: fixed
messages: + msg255221

stage: needs patch -> resolved
2015-11-23 17:45:06matrixisesetmessages: + msg255204
2015-11-23 17:18:25r.david.murraysetmessages: + msg255199
2015-11-23 16:52:01matrixisesetmessages: + msg255191
2015-11-23 16:38:16matrixisesetmessages: + msg255188
2015-11-23 16:34:56r.david.murraysetmessages: + msg255187
2015-11-23 15:51:42BreamoreBoysetnosy: + BreamoreBoy
messages: + msg255180
2015-11-23 14:07:19matrixisesetmessages: + msg255161
2015-11-22 21:53:22martin.pantersetnosy: + martin.panter
messages: + msg255112
2015-11-22 10:33:17matrixisesetmessages: + msg255091
2014-04-19 21:26:49r.david.murraysetmessages: - msg216880
2014-04-19 21:26:39r.david.murraysetmessages: + msg216881
2014-04-19 21:25:35r.david.murraysetnosy: + r.david.murray
messages: + msg216880
2014-04-17 07:13:34nitikasetmessages: + msg216667
2014-04-16 20:48:41matrixisesetmessages: + msg216586
2014-04-16 19:47:16nitikasetmessages: + msg216566
2014-04-14 18:29:01matrixisesetnosy: + matrixise

messages: + msg216157
versions: + Python 3.5, - Python 2.7, Python 3.3, Python 3.4
2014-04-05 13:51:22nitikasetmessages: + msg215609
2014-03-19 18:58:53nitikasetfiles: + issue4744_3.patch

messages: + msg214125
2014-03-16 16:57:21nitikasetfiles: + issue4744_2.patch
keywords: + patch
messages: + msg213738
2014-03-16 04:41:28nitikasetnosy: + nitika
messages: + msg213709
2014-03-12 20:04:36eric.araujosetversions: + Python 3.3, Python 3.4, - Python 3.1, Python 3.2
2014-02-03 19:52:14BreamoreBoysetnosy: - BreamoreBoy
2010-07-31 11:35:49BreamoreBoysetversions: + Python 3.1, Python 2.7, Python 3.2, - Python 3.0
nosy: + BreamoreBoy, docs@python

messages: + msg112137

assignee: georg.brandl -> docs@python
stage: needs patch
2008-12-27 02:41:46giampaolo.rodolasetnosy: + giampaolo.rodola, josiah.carlson
2008-12-25 01:22:50beazleycreate