Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Descriptions of os.utime() and os.utimensat() use wrong notation #59075

Closed
hynek opened this issue May 21, 2012 · 3 comments
Closed

Descriptions of os.utime() and os.utimensat() use wrong notation #59075

hynek opened this issue May 21, 2012 · 3 comments
Labels
docs Documentation in the Doc dir easy type-feature A feature request or enhancement

Comments

@hynek
Copy link
Member

hynek commented May 21, 2012

BPO 14870
Nosy @birkenfeld, @ezio-melotti, @merwok, @akheron, @hynek

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = <Date 2012-12-27.10:05:03.756>
created_at = <Date 2012-05-21.11:50:05.885>
labels = ['easy', 'type-feature', 'docs']
title = 'Descriptions of os.utime() and os.utimensat() use wrong notation'
updated_at = <Date 2012-12-27.10:05:03.754>
user = 'https://github.com/hynek'

bugs.python.org fields:

activity = <Date 2012-12-27.10:05:03.754>
actor = 'hynek'
assignee = 'docs@python'
closed = True
closed_date = <Date 2012-12-27.10:05:03.756>
closer = 'hynek'
components = ['Documentation']
creation = <Date 2012-05-21.11:50:05.885>
creator = 'hynek'
dependencies = []
files = []
hgrepos = []
issue_num = 14870
keywords = ['easy']
message_count = 3.0
messages = ['161264', '161268', '178290']
nosy_count = 7.0
nosy_names = ['georg.brandl', 'ezio.melotti', 'eric.araujo', 'cvrebert', 'docs@python', 'petri.lehtinen', 'hynek']
pr_nums = []
priority = 'low'
resolution = 'fixed'
stage = 'resolved'
status = 'closed'
superseder = None
type = 'enhancement'
url = 'https://bugs.python.org/issue14870'
versions = ['Python 3.3']

@hynek
Copy link
Member Author

hynek commented May 21, 2012

It says:

os.utimensat(dirfd, path[, atime=(atime_sec, atime_nsec), mtime=(mtime_sec, mtime_nsec), flags=0])
Updates the timestamps of a file with nanosecond precision. The atime and mtime tuples default to None, which sets those values to the current time.

It should be the other way around: atime=None, mtime=None in the signature and explain in the body how they look like. It looks like atime_sec and atime_nsec are some magic constants this way.

@hynek hynek added docs Documentation in the Doc dir easy labels May 21, 2012
@akheron
Copy link
Member

akheron commented May 21, 2012

os.utime() uses the same notation:

os.utime(path[, times, *, ns=(atime_ns, mtime_ns)])

@akheron akheron changed the title os.utimensat's method description uses wrong notation Descriptions of os.utime() and os.utimensat() use wrong notation May 21, 2012
@ezio-melotti ezio-melotti added the type-feature A feature request or enhancement label Aug 7, 2012
@hynek
Copy link
Member Author

hynek commented Dec 27, 2012

Turns out, Larry fixed these two while working on bpo-14626.

@hynek hynek closed this as completed Dec 27, 2012
@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir easy type-feature A feature request or enhancement
Projects
None yet
Development

No branches or pull requests

3 participants