[issue42958] filecmp.cmp(shallow=True) isn't actually shallow when only mtime differs

2021-07-12 Thread Christof Hanke
Christof Hanke added the comment: Andrei, cmp is the deep-compare part of filecmp. I thought we were taking about the shallow one. Thus, - shallow like rsync "quick": size + mtime. - deep like cmp -- ___ Python tracker <https://bu

[issue42958] filecmp.cmp(shallow=True) isn't actually shallow when only mtime differs

2021-07-12 Thread Christof Hanke
Christof Hanke added the comment: Hi Andrei, I would follow rsync. >From the man page: """ [...] -c, --checksum This changes the way rsync checks if the files have been changed and are in need of a transfer. Without this option, rsync uses

[issue42958] filecmp.cmp(shallow=True) isn't actually shallow when only mtime differs

2021-07-12 Thread Christof Hanke
Christof Hanke added the comment: Hi, this is also discussed in https://bugs.python.org/issue41354. Ciao, Christof -- nosy: +chanke ___ Python tracker <https://bugs.python.org/issue42

[issue41354] filecmp.cmp documentation does not match actual code

2021-07-12 Thread Christof Hanke
Christof Hanke added the comment: Andrei, See https://bugs.python.org/issue42958 Someone else stumbled over this topic. Maybe you can merge these two requests? Otherwise, I'm fine with a new arg. Christof -- ___ Python tracker <ht

[issue41354] filecmp.cmp documentation does not match actual code

2020-12-27 Thread Christof Hanke
Christof Hanke added the comment: I understand that you are reluctant to change existing code. But for me as a sysadmin, the current behavior doesn't make sense for two reasons: * st.st_size is part of _sig. why would you do a deep compare if the two files have a different length

[issue41354] filecmp.cmp documentation does not match actual code

2020-07-21 Thread Christof Hanke
Change by Christof Hanke : -- keywords: +patch pull_requests: +20722 stage: -> patch review pull_request: https://github.com/python/cpython/pull/21580 ___ Python tracker <https://bugs.python.org/issu

[issue41354] filecmp.cmp documentation does not match actual code

2020-07-21 Thread Christof Hanke
New submission from Christof Hanke : help(filecmp.cmp) says: """ cmp(f1, f2, shallow=True) Compare two files. Arguments: f1 -- First file name f2 -- Second file name shallow -- Just check stat signature (do not read the files).

[issue33638] condition lock not re-acquired

2018-05-24 Thread christof
christof <chbai...@gmail.com> added the comment: In my previous comment, what I want to implement is not a timeout for a task to complete but more precisely a timeout triggered if the coroutine was not wake up by a notify on the con

[issue33638] condition lock not re-acquired

2018-05-24 Thread christof
New submission from christof <chbai...@gmail.com>: Hello, I have a simple code which triggers a timeout if a task did not complete import asyncio async def task_timeout(): condition = asyncio.Condition() with await condition: try: await asyncio.wa

[issue26047] argparse.ArgumentError documentation wrong

2016-01-08 Thread Christof Hanke
New submission from Christof Hanke: On https://docs.python.org/2/library/argparse.html (and on those of the 3.6-Version) it says at the bottom: """ ArgumentParser.error(message) This method prints a usage message including the message to the standard error and termina

[issue5786] len(reversed([1,2,3])) does not work anymore in 2.6.2

2009-04-19 Thread Christof
Christof cthe...@gmail.com added the comment: A compatibility break in a minor bugfix version is never a good idea I guess. I understand the reasoning but this change may break quite a few packages (at least it broke mine). A workaround in programs is easy but for already released and deployed