minor grammar and syntax fixes #148

Merged
merged 4 commits into from Jan 3, 2017

Projects

None yet

2 participants

@stevepiercy
Member

No description provided.

stevepiercy added some commits Oct 25, 2016
@stevepiercy stevepiercy minor grammar and syntax fixes
c59d4b0
@stevepiercy stevepiercy Merge remote-tracking branch 'upstream/master'
7093e81
@stevepiercy stevepiercy remove deprecated supported versions of Python
268036f
@stevepiercy stevepiercy requested a review from bertjwregeer Jan 3, 2017
-filelike object using the provided block_size is used (and copying is done,
-negating any benefit of the file wrapper). It *should* support a ``close()``
-method.
+``filelike_object`` using the provided ``block_size`` is used (and copying is
@bertjwregeer
bertjwregeer Jan 3, 2017 Member

It's fine to keep this filelike_object

@stevepiercy
stevepiercy Jan 3, 2017 Member

"filelike object" is wrong. It should be either "file-like object" when used in plain old English or "filelike_object" when referring to programming language.

In this instance, the latter is seems more contextually appropriate to me, since it aligns with block_size

docs/filewrapper.rst
Waitress will set a ``Content-Length`` header on the behalf of an application
-when a file wrapper with a sufficiently filelike object is used if the
+when a file wrapper with a sufficient ``filelike_object`` is used if the
@bertjwregeer
bertjwregeer Jan 3, 2017 Member

Why did you change it to filelike_object? That's not correct here.

@stevepiercy
stevepiercy Jan 3, 2017 Member

I thought it was a typo. I'll change it to "sufficiently file-like object".

docs/filewrapper.rst
application hasn't already set one.
The machinery which handles a file wrapper currently doesn't do anything
particularly special using fancy system calls (it doesn't use ``sendfile``
for example); using it currently just prevents the system from needing to
copy data to a temporary buffer in order to send it to the client. No
copying of data is done when a WSGI app returns a file wrapper that wraps a
-sufficiently filelike object. It may do something fancier in the future.
+sufficient ``filelike_object``. It may do something fancier in the future.
@bertjwregeer
bertjwregeer Jan 3, 2017 Member

filelike object here is a general term to describe an object that is file like, filelike_object refers to a single instance of said object.

"wraps a sufficient filelike_object" is wrong, because we are not wrapping a filelike_object, we are wrapping an object that happens to behave and look like a Python file.

@stevepiercy stevepiercy Proper use of "file-like object" or ``filelike_object``, based on con…
…text
43fae80
@bertjwregeer bertjwregeer merged commit 9ecb4b9 into Pylons:master Jan 3, 2017

2 checks passed

continuous-integration/appveyor/pr AppVeyor build succeeded
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment