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: Fix (support package regression)
Type: behavior Stage: resolved
Components: Tests Versions: Python 3.3, Python 3.4
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: ncoghlan Nosy List: ezio.melotti, ncoghlan, python-dev, zach.ware
Priority: normal Keywords: patch

Created on 2013-09-07 04:22 by zach.ware, last changed 2022-04-11 14:57 by admin. This issue is now closed.

File name Uploaded Description Edit
move_test_data.diff zach.ware, 2013-09-07 04:22 Move Lib/test/data into Lib/test/support review
fix_support_open_urlresource.diff zach.ware, 2013-09-07 04:23 Alternative fix. review
Messages (4)
msg197132 - (view) Author: Zachary Ware (zach.ware) * (Python committer) Date: 2013-09-07 04:22
Since was moved into its own package, support.open_urlresource has been unable to work.  It expects <__file__ dir>/data to exist, but since <__file__ dir> is now Lib/test/support instead of Lib/test, it doesn't unless someone creates it manually.  Since open_urlresource turns all exceptions into SkipTest, this means that all test runs have been silently skipping test_codecmaps_* and a couple others since support became a package.

Here's a patch with my preferred fix, which is to move Lib/test/data to Lib/test/support/data.  This dir is only used by support.open_urlresource, and moving it does just a tiny bit to de-clutter Lib/test.
msg197133 - (view) Author: Zachary Ware (zach.ware) * (Python committer) Date: 2013-09-07 04:23
Here's an alternative fix, which just makes open_urlresource look one directory higher than where __file__ lives.
msg197170 - (view) Author: Nick Coghlan (ncoghlan) * (Python committer) Date: 2013-09-07 15:39
I was going to go with the "move the directory" solution, but realised that would mean existing checkouts end up downloading the data files again, and also with a stale copy of the data cluttering them up.

So adjusting the support module for the different relative path seems like the better option - I'll apply that one tomorrow (well, technically, later today...)
msg197216 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2013-09-08 02:51
New changeset 23770d446c73 by Nick Coghlan in branch '3.3':
Close #18952: correctly download test support data

New changeset cb8dabc113b8 by Nick Coghlan in branch 'default':
Merge #18952 fix from 3.3
Date User Action Args
2022-04-11 14:57:50adminsetgithub: 63152
2013-09-08 02:51:23python-devsetstatus: open -> closed

nosy: + python-dev
messages: + msg197216

resolution: fixed
stage: resolved
2013-09-07 15:39:51ncoghlansetmessages: + msg197170
2013-09-07 15:37:38ncoghlansetassignee: ncoghlan
2013-09-07 04:23:09zach.waresetfiles: + fix_support_open_urlresource.diff

messages: + msg197133
2013-09-07 04:22:13zach.warecreate