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.
Created on 2011年11月03日 18:06 by vinay.sajip, last changed 2022年04月11日 14:57 by admin. This issue is now closed.
| Messages (3) | |||
|---|---|---|---|
| msg146957 - (view) | Author: Vinay Sajip (vinay.sajip) * (Python committer) | Date: 2011年11月03日 18:06 | |
The packaging.command.Command.copy_file method does not honour the preserve_mode and preserve_times keyword arguments. Likewise, packaging.command.Command.copy_tree does not honour the preserve_mode, preserve_times and preserve_symlinks keyword arguments. |
|||
| msg147476 - (view) | Author: Éric Araujo (eric.araujo) * (Python committer) | Date: 2011年11月12日 11:39 | |
Thanks for the report. Have you found the bug with a real setup.cfg or hook, or were you just reading the code? I’m not sure how hard to fix this will be. The copy_file method delegates to shutil.copyfile, but this does not have the arguments we need, contrary to the former distutils file_util.copy_file function. Currently it’s only build_py that uses this parameter: # if a file is read-only in the working # directory, we want it to be installed read/write so that the next # installation of the same module distribution can overwrite it # without problems. (This might be a Unix-specific issue.) Thus # we turn off 'preserve_mode' when copying to the build directory, # since the build directory is supposed to be exactly what the # installation will look like (ie. we preserve mode when # installing). Depending on whether shutil supports what we need, different patches could be made: - Change code to use the right shutil function - Add code in copy_file to walk and chmod - Remove the preserve_* arguments and add another method for build_py |
|||
| msg147506 - (view) | Author: Vinay Sajip (vinay.sajip) * (Python committer) | Date: 2011年11月12日 15:48 | |
> > > Éric Araujo <merwok@netwok.org> added the comment: > > Thanks for the report. Have you found the bug with a real setup.cfg or hook, or > were you just reading the code? > I found the bug with a real setup.cfg (executable permission not set IIRC) and tracked it to copy_file. The copy_tree function wasn't used, I was just making an observation from scanning the code. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:57:23 | admin | set | github: 57545 |
| 2014年03月13日 03:33:16 | eric.araujo | set | status: open -> closed resolution: out of date stage: resolved |
| 2011年11月12日 15:48:56 | vinay.sajip | set | messages: + msg147506 |
| 2011年11月12日 11:39:17 | eric.araujo | set | messages: + msg147476 |
| 2011年11月03日 18:06:36 | vinay.sajip | create | |