Chris Jerdonek added the comment:
In addition, before changing ImpImporter.iter_modules(), we should probably
also add some tests of the method for values of self.path that do work (i.e.
for when self.path is not None). The method is currently untested.
I can work on adding tests for that
Chris Jerdonek added the comment:
I agree pkgutil is pretty much useless right now and deprecation worth
considering. But isn't another option simply to change pkgutil's internals to
provide its own iter_modules whenever it finds that method missing? This seems
to be what it h
Chris Jerdonek added the comment:
In Python 2.7, I just did this test:
>>> import sys, pkgutil
>>> for path in sys.path:
... print pkgutil.get_importer(path)
And got only pkgutil.ImpImporter instances and imp.NullImporter objects.
So even before, at least in the most com
Chris Jerdonek added the comment:
Thanks for the interesting background and feedback. I was aware of the
__enter__/__exit__ option but not the other information. And yes, I agree on
the importance of trying and discussing any API before settling on it. The one
I suggested was merely a point
New submission from Chris Jerdonek :
I think the generator.__next__() documentation should say that it raises an
exception if the generator is already executing:
http://docs.python.org/dev/reference/expressions.html#generator.__next__
I don't think this is currently mentioned anywhere i
Chris Jerdonek added the comment:
For the record, this issue is still present after Nick's pkgutil changes
documented in issue 15343 (not that I expected it to be resolved since this
issue is a bit different).
--
___
Python tracker
Changes by Chris Jerdonek :
--
nosy: +cjerdonek
___
Python tracker
<http://bugs.python.org/issue15358>
___
___
Python-bugs-list mailing list
Unsubscribe:
Chris Jerdonek added the comment:
Closing as this is no longer an issue after Nick's pkgutil changes documented
in issue 15343.
--
status: open -> closed
___
Python tracker
<http://bugs.python.org
Chris Jerdonek added the comment:
Such helper functionality could also be used in the tests of
unittest.TestLoader.loadTestsFromName(). See, for example, the tests proposed
for issue 7559.
--
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
Thanks a lot for the feedback. The thinking was to use a stand-alone (even
testable) construct with dependencies made explicit. For example, it wasn't
obvious that the current iterator depended on forever, or whether the
args_tuple parameter
Chris Jerdonek added the comment:
> This isn't an easy one to fix - you basically need something along the lines
> of a PEP 406 style import engine API in order to do the import without having
> potentially adverse effects on the state in the sys module.
By adverse, do you
Chris Jerdonek added the comment:
Issue 15322 is a recently filed bug regarding srcdir:
"sysconfig.get_config_var('srcdir') returns unexpected value"
--
nosy: +cjerdonek
___
Python tracker
<http://bug
Chris Jerdonek added the comment:
Attached is a patch illustrating the API I suggested for discussion.
To add custom setup and teardown context managers, the user can override the
following method:
def executeTest(self):
with self.setUpContext():
self.runTestMethod
Chris Jerdonek added the comment:
I'd like to work on this if that's okay. I've already written test cases for
issue 7559 and issue 15299 that required creating temporary packages, so I
understand the need. And I'd also like to create test cases for issue 14787,
which s
New submission from Chris Jerdonek :
This issue is to refactor the create-package code in test_runpy into a helper
module, as suggested in issue 15358.
This is a prerequisite to moving the pkgutil.walk_package() tests from
test_runpy into test_pkgutil.
--
components: Tests
keywords
Changes by Chris Jerdonek :
--
dependencies: +Refactor the create-package code in test_runpy into a helper
module
___
Python tracker
<http://bugs.python.org/issue15
New submission from Chris Jerdonek :
The error message for os.path.join() is misleading when the first argument is
None. The message should probably say something about mixing "None" and
strings.
Python 3.3.0b1 (default:f954ee489896, Jul 16 2012, 22:42:29)
[GCC 4.2.1 Compatible A
New submission from Chris Jerdonek :
This issue addresses the "file creation" portion of issue 15376, which is to
refactor the walk_package support code in test_runpy into a common location.
--
components: Tests
keywords: easy
messages: 165910
nosy: cjerdonek
priority: norma
Chris Jerdonek added the comment:
I'm going to address this issue in parts to make it easier to review and see
what is going on.
The first patch I'm uploading shortly here: issue 15403. That issue I created
to address just the "file creation" part of the code.
The appro
Changes by Chris Jerdonek :
--
nosy: +ncoghlan
___
Python tracker
<http://bugs.python.org/issue15403>
___
___
Python-bugs-list mailing list
Unsubscribe:
Chris Jerdonek added the comment:
Attaching patch.
--
keywords: +patch
Added file: http://bugs.python.org/file26447/issue-15403-1.patch
___
Python tracker
<http://bugs.python.org/issue15
Chris Rebert added the comment:
Pinging on this, since it's been just short of a month since Éric's "last call"
comment.
--
___
Python tracker
<http://bug
Changes by Chris Rebert :
--
nosy: +cvrebert
___
Python tracker
<http://bugs.python.org/issue1100942>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Chris Jerdonek :
This issue is partly in service to issue 15376, which is to refactor
test_runpy's walk_package support code into a common location.
Currently, the temp_cwd() context manager in test.support does two things: it
creates a temp directory, and it change
Chris Jerdonek added the comment:
Attaching a patch with tests.
--
keywords: +patch
stage: -> patch review
Added file: http://bugs.python.org/file26468/issue-15415-1.patch
___
Python tracker
<http://bugs.python.org/issu
Chris Jerdonek added the comment:
Fixing patch so it will apply cleanly.
--
Added file: http://bugs.python.org/file26470/issue-15415-2.patch
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
> Given that we have self.left_list and self.left_only ( and self.right_list
> and self.right_only), I am not sure how adding self.left/self.right is going
> to add more meaning?
It adds more meaning because you can't construct self.left and s
Chris Jerdonek added the comment:
Trying again to have the patch apply cleanly (for the review link).
--
Added file: http://bugs.python.org/file26472/issue-15415-3.patch
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
For attribution purposes and to keep the issue focused, shouldn't those other
changes be added as part of a separate issue?
The changes you added are much larger than mine, and address cosmetic issues
and other issues unrelated to the original point
Chris Jerdonek added the comment:
Thanks, Senthil. I would prefer if you created a new issue in the tracker for
your additional changes, and then committed your changes as part of that issue.
By attribution, I was referencing the "Patch by Chris Jerdonek" which can go
in the comm
Chris Jerdonek added the comment:
Thanks a lot for committing this for me Senthil. And thanks also for creating
a separate issue for the other changes. I appreciate it.
--
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
Some comments on the patch:
+ The buffer size value which will be used to read the file contents. Defaults
+ to 8192 bytes.
I would consider including the units for the value here (e.g. "The buffer
size value in bytes...").
+ When *shallow* f
Chris Jerdonek added the comment:
I created issue 15415 and uploaded a patch there with this issue in mind.
test_runpy contains supporting _make_pkg() and _del_pkg() methods that,
among other things, create and delete a temp directory. That logic
would be better handled by a temp directory
Changes by Chris Jerdonek :
--
nosy: +cjerdonek
___
Python tracker
<http://bugs.python.org/issue15434>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Chris Jerdonek :
--
nosy: +cjerdonek
___
Python tracker
<http://bugs.python.org/issue15433>
___
___
Python-bugs-list mailing list
Unsubscribe:
Chris Jerdonek added the comment:
Allowing dircmp() to accept a file comparison function is another option to
consider that may address more needs going forward. shallow=False could be
achieved by passing lambda a, b: filecmp.cmp(a, b, shallow=False).
--
versions: +Python 3.4
New submission from Chris Jerdonek :
This issue is to merge the Doc/ACKS and Misc/ACKS files as discussed here:
http://mail.python.org/pipermail/python-dev/2012-July/121096.html
--
assignee: docs@python
components: Documentation
keywords: easy
messages: 166247
nosy: cjerdonek, docs
Chris Jerdonek added the comment:
I would be happy to prepare a patch. I can upload a script to this issue that
the committer can then run on the latest Misc/ACKS and Doc/ACKS.txt.
The script would preserve the ordering of Misc/ACKS. It would iterate through
the names in Doc/ACKS.txt and
Chris Jerdonek added the comment:
Attached is a script that seems to do the job (except for the rst formatting,
which can be added later. This was so that you can see by the diff what has
changed).
In the process of doing this, I found that Jeff McNeil is far out of order in
Misc/ACKS, and
Chris Jerdonek added the comment:
Attaching sample output of running the script.
--
keywords: +patch
Added file: http://bugs.python.org/file26494/issue-15437-sample-output.patch
___
Python tracker
<http://bugs.python.org/issue15
New submission from Chris Jerdonek :
This issue is to include the names in Misc/ACKS into the documentation --
in place of the names from Doc/ACKS.txt. This was mentioned in the
discussion for issue 15437, which is to add the names from Doc/ACKS.txt
into Misc/ACKS.
This issue should be done
Changes by Chris Jerdonek :
--
dependencies: +Merge Doc/ACKS and Misc/ACKS
___
Python tracker
<http://bugs.python.org/issue15439>
___
___
Python-bugs-list mailin
Chris Jerdonek added the comment:
I created a new issue 15439 for including the combined Misc/ACKS into the
documentation (as Éric mentioned) because the nature of that discussion is
different, and because the changes will be easier to observe and understand if
committed separately
Chris Jerdonek added the comment:
Martin, just to be sure, this is to be done after issue 15437 (a dependency),
and the location of Misc/ACKS will not change. Have you already read the
discussion there? Éric said that he recalled it was Georg's preference to do
this if Doc/ACKS.t
Chris Jerdonek added the comment:
I did think through those issues and made a special effort to address them in
the script.
For starters, the script does not change the order of any names in Misc/ACKS.
This is to preserve the existing rough alphabetical ordering, and to ensure
that the
Chris Jerdonek added the comment:
That is correct, Antoine. Duplicates need to be removed by hand.
To assist in this process, the script currently prints "possible duplicates" to
stdout after running. However, the script could easily be modified to display
an in-line indica
Chris Jerdonek added the comment:
Thanks a lot, Eli.
--
___
Python tracker
<http://bugs.python.org/issue15231>
___
___
Python-bugs-list mailing list
Unsubscribe:
Chris Jerdonek added the comment:
The second sense of the word "include" is in the possible implementation. Éric
pointed out in the other issue's thread that this can be achieved by modifying
the existing include directive, for example--
--- a/Doc/about.rst
+++ b/Doc/abo
Chris Jerdonek added the comment:
Yes, I did. Even though it is throw-away.
By the way, I'm taking Antoine's advice to avoid perfectionism on this.
Otherwise I'd include your suggestion re: the special characters. :)
--
___
Python
Chris Jerdonek added the comment:
Thanks for taking the time to look at this, Eli.
In response to your question, here is one illustrated rationale.
When recursing through a directory using dircmp, it is simplest and cleanest to
be able to recurse on the subdirs attribute without having to
Chris Jerdonek added the comment:
It seems to be the latter: Žiga Seilnacht
http://mail.python.org/pipermail/python-dev/2007-March/071786.html
--
nosy: +cjerdonek
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
Is that a -0 then, Raymond?
I think either the combined Misc/ACKS list should be included in the docs, or
it should be removed entirely. If what Meador said is true (that people
already in Misc/ACKS who contribute documentation should not be added)--
>
Chris Jerdonek added the comment:
Okay, thanks for clarifying. Then I have no strong opinion.
However, if Doc/ACKS.txt is retained, then I think the Dev Guide should mention
Doc/ACKS.txt just as it mentions Misc/ACKS:
http://docs.python.org/devguide/patch.html#preparation
And it should
Chris Jerdonek added the comment:
Is there a reason not to correct that spelling in this issue? Otherwise, we
could create a new issue.
--
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
To be clear on this issue's scope, I would state in a single comment a white
list of which directories or individual files are being corrected (or if
necessary, the rules to determine such a list, e.g. any file whose name root is
"NEWS", etc)
Chris Jerdonek added the comment:
Thanks a lot, Eli, and for the suggestions. I would be happy to prepare a full
patch.
Regarding the stream argument, I think there are other changes to dircmp that
would be more useful (e.g. issue 12932), but I agree that some form of your
suggestion makes
Chris Jerdonek added the comment:
Antoine, does the latest patch look okay to you, or did you want something even
more minimal (e.g. by defining and acquiring the lock directly in main)?
--
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
Thanks, Antoine. Just a note: with that other implementation I think the call
to pending.close() would probably also warrant a lock since it appears close()
can't be called either if a generator is already executing (granted that
situation would be
Chris Jerdonek added the comment:
Attaching a patch to address Eli's requests (1) and (2).
Since this patch merely adds documentation and tests for existing
functionality, is there any reason why this cannot go into Python 3.3? Thanks.
--
Added file: http://bugs.python.org/file
New submission from Chris Jerdonek :
Currently, the subdirs attribute of filecmp.dircmp does not respect subclassing:
>>> from filecmp import dircmp
>>> class MyDirCmp(dircmp):
... pass
...
>>> my_dcmp = MyDirCmp('dir1', 'dir2')
>>> for
Chris Jerdonek added the comment:
Hi Nick, I was wondering if you'd have time to take a look at the patches I've
uploaded to issue 15403 and issue 15415 at some point.
Once those are addressed, I think we will be in a much better position to
address most of
Changes by Chris Rebert :
--
nosy: +cvrebert
___
Python tracker
<http://bugs.python.org/issue15436>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Chris Rebert :
--
nosy: +cvrebert
___
Python tracker
<http://bugs.python.org/issue15360>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Chris Rebert :
--
nosy: +cvrebert
___
Python tracker
<http://bugs.python.org/issue15451>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Chris Jerdonek :
Currently, filecmp.dircmp's report(), report_partial_closure(), and
report_full_closure() methods all only allow printing to stdout.
This issue is to provide some way for the caller to control the stream to which
these methods print their output (e
Chris Jerdonek added the comment:
Sounds good. And for the record, new issue created here: issue 15454
--
___
Python tracker
<http://bugs.python.org/issue15
New submission from Chris Jerdonek :
I haven't tracked down the reason for this, but certain index entries seem to
be getting skipped in the Glossary. If you view source on the Glossary page
and search for "index-":
http://docs.python.org/dev/glossary.html
You will find tha
Chris Jerdonek added the comment:
This is a very simple patch.
--
keywords: +patch
Added file: http://bugs.python.org/file26525/issue-15355-1.patch
___
Python tracker
<http://bugs.python.org/issue15
New submission from Chris Jerdonek :
The documentation on generators (outside of PEP 255) does not currently educate
the reader on the more specific "generator function" and "generator iterator"
terminology, or at least not in any consistent or systematic way.
For e
Changes by Chris Jerdonek :
--
stage: -> patch review
___
Python tracker
<http://bugs.python.org/issue15355>
___
___
Python-bugs-list mailing list
Unsubscri
Chris Jerdonek added the comment:
Attaching patch.
--
keywords: +patch
Added file: http://bugs.python.org/file26526/issue-15457-1.patch
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
It occurs to me that the filecmp/dircmp tests in Lib/test/test_filecmp.py would
also benefit from code like this (i.e. being able to create a nested directory
of files in one or two lines). And perhaps elsewhere in the tests.
This is an argument for
Chris Jerdonek added the comment:
Adding a patch with a failing test for the issue.
--
keywords: +patch
stage: -> needs patch
Added file: http://bugs.python.org/file26531/issue-15450-failing-test.patch
___
Python tracker
<http://bugs.pyth
Chris Jerdonek added the comment:
Attaching full patch (though Misc/NEWS would need to be moved a new section is
created for pre-alpha).
--
Added file: http://bugs.python.org/file26532/issue-15450-1.patch
___
Python tracker
<http://bugs.python.
Changes by Chris Jerdonek :
--
stage: needs patch -> patch review
___
Python tracker
<http://bugs.python.org/issue15450>
___
___
Python-bugs-list mai
Chris Jerdonek added the comment:
Actually, this should also be documented.
--
stage: patch review -> needs patch
___
Python tracker
<http://bugs.python.org/issu
Chris Jerdonek added the comment:
For discussion purposes, I'd like to mention an alternate approach. (I haven't
yet formed an opinion on what approach is preferable.)
Python's built-in print() function accepts more than just a 'file' keyword
argument:
http://do
Chris Jerdonek added the comment:
This might be obvious to some people, but for background purposes, this seems
to be where the file name gets truncated (in the dump_frame() function):
write(fd, "\"", 1);
dump_ascii(fd, code->co_filename);
write(fd, "\"
Chris Jerdonek added the comment:
In your test, is there a reason you don't need to verify that your callback is
actually called?
+def cb(packet):
+ self.assertGreater(len(packet), 0)
+ctx = ssl.SSLContext(ssl.PROTOCOL_S
Chris Jerdonek added the comment:
That is one way to do it. But it would be better to use a local variable
rather than an attribute of the class (because otherwise you have to worry
about resetting the value if more than one test uses the same pattern).
Something like this would be better
Changes by Chris Jerdonek :
--
nosy: +cjerdonek
___
Python tracker
<http://bugs.python.org/issue1234674>
___
___
Python-bugs-list mailing list
Unsubscribe:
Chris Jerdonek added the comment:
Hi Ned, you committed two of my Dev Guide patches in the recent past. I was
wondering if you would be willing to commit this one as well. Thanks a lot.
--
___
Python tracker
<http://bugs.python.org/issue15
Chris Jerdonek added the comment:
Thanks, Ned! Renaming the issue title to be more specific.
--
keywords: -easy, patch
title: Developer Guide doesn't get updated once a day -> Dev Guide update hook
broken
___
Python tracke
Chris Jerdonek added the comment:
Updating patch to include documentation changes.
--
keywords: -patch
stage: needs patch -> patch review
Added file: http://bugs.python.org/file26551/issue-15450-2.patch
___
Python tracker
<http://bugs.pyth
Chris Jerdonek added the comment:
The idea also to include a romanization is a good one.
While working on issue 15437, it occurred to me that storing the names in a
structured form might come in handy. This would let us do things like list the
username(s) associated with each contributor
Chris Jerdonek added the comment:
Thanks a lot for the excellent feedback. I'll update the patch to incorporate
it.
One background note: I tried not to be too strict about using "generator
iterator" or "generator function" in place of "generator" in the
Chris Jerdonek added the comment:
Attaching updated patch incorporating feedback.
It would be nice to have a good term for "the generator function code object
associated with a generator" to distinguish it from the original generator
function as you point out.
There are many pla
Chris Jerdonek added the comment:
Here is an even simpler failing test case:
>>> from textwrap import wrap
>>> wrap("a\nb", replace_whitespace=False)
['a\nb']
It should return--
['a', 'b']
I will start working on this issue by
Changes by Chris Jerdonek :
--
nosy: +eli.bendersky
___
Python tracker
<http://bugs.python.org/issue15450>
___
___
Python-bugs-list mailing list
Unsubscribe:
Chris Jerdonek added the comment:
> def wrap_paragraphs(text, width=70, **kwargs):
> return [line for para in text.splitlines() for line in
> textwrap.wrap(para, width, **kwargs)]
I just want to point out that, at least for the purposes of this issue, I don't
believ
New submission from Chris Jerdonek :
This issue is to add "code object" to the documentation glossary, as discussed
in issue 15457 regarding the documentation around generators.
This can be a minimal entry that links to the details here, for example--
http://docs.python.org
Chris Jerdonek added the comment:
I created issue 15476 to add "code object" to the glossary.
> Generator functions must have a special __call__ method that simply creates
> and returns a generator instance with the code object attached (instead of
> executing the code).
Chris Jerdonek added the comment:
> We may also add a function to change these limits at runtime.
This sounds like a good idea. Is there already an issue for this? If not, I
could create one.
Regardless of whether MAX_STRING_LENGTH is increased, my instinct is that the
test should w
New submission from Chris Jerdonek:
This issue is to allow the MAX_STRING_LENGTH limit defined in
Python/traceback.c to be changed at runtime, as discussed in issue 15463, as
well as the two related limits:
#define MAX_STRING_LENGTH 100
#define MAX_FRAME_DEPTH 100
#define MAX_NTHREADS 100
Chris Jerdonek added the comment:
> There is no such issue. You can create it: add me to the nosy list.
I created issue 15479 to allow the limits to be changed at runtime.
--
___
Python tracker
<http://bugs.python.org/issu
Chris Jerdonek added the comment:
> The purpose of the test is to check that the traceback is correct:
> it's important to check that the filename ends with "threading.py".
I agree with you. That is why I argued against including "or '...'" lo
Chris Jerdonek added the comment:
Here is a patch to the tests that allows the tests to pass when the install
path is long while still checking that file names show up correctly in the
traceback.
One advantage of this patch's approach is that it provides a way to test the
rendering of
Chris Jerdonek added the comment:
Terry, if when reviewing my patch for issue 15457, you also have time to review
this much simpler patch (also in the documentation on generators), I would
appreciate it. If not, that's okay.
--
nosy: +terry.
Chris Jerdonek added the comment:
Is there any way I could assist in closing this, perhaps by preparing patches
for the Distutils and Distutils2 components? Can someone point me to where the
changes to those components should be made (e.g. where they are located
Chris Jerdonek added the comment:
Thanks, Martin. Should Distutils2 be removed from the "Components" list of the
tracker form, then? Or was Éric referencing a third-party location?
--
___
Python tracker
<http://bugs.python.o
1001 - 1100 of 2758 matches
Mail list logo