[issue25735] math.factorial doc should mention integer return type

2019-05-31 Thread miss-islington


miss-islington  added the comment:


New changeset fc3b8437c86167983cc75e5a9a3ed1dc542a1b79 by Miss Islington (bot) 
in branch '3.7':
bpo-25735: math.factorial doc should mention integer return type (GH-6420)
https://github.com/python/cpython/commit/fc3b8437c86167983cc75e5a9a3ed1dc542a1b79


--
nosy: +miss-islington

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2019-05-31 Thread Cheryl Sabella


Cheryl Sabella  added the comment:

@John.Yeung, thank you for the report.  @mine0901, thanks for the initial patch 
and @akshaysharma, thank you for the PR.

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2019-05-31 Thread miss-islington


Change by miss-islington :


--
pull_requests: +13588
pull_request: https://github.com/python/cpython/pull/13702

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2019-05-31 Thread Cheryl Sabella


Cheryl Sabella  added the comment:


New changeset 4612671df2742eade8ecf8003a6ce1247973c135 by Cheryl Sabella 
(Akshay Sharma) in branch 'master':
bpo-25735: math.factorial doc should mention integer return type (GH-6420)
https://github.com/python/cpython/commit/4612671df2742eade8ecf8003a6ce1247973c135


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2018-04-08 Thread Akshay Sharma

Change by Akshay Sharma :


--
pull_requests: +6123
stage: needs patch -> patch review

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2018-03-15 Thread Mark Dickinson

Mark Dickinson  added the comment:

I opened #33083, and copied the nosy list from this issue across.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2018-03-15 Thread Cheryl Sabella

Cheryl Sabella  added the comment:

Sounds good.  Thanks, Mark.

@mine0901, would you like to open a Github pull request for your patch?  Thanks!

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com




[issue25735] math.factorial doc should mention integer return type

2018-03-15 Thread Mark Dickinson

Mark Dickinson  added the comment:

> Should the documentation patch for this be converted to a PR

I think so, yes. How about we open a new issue for the factorial(Decimal(...)) 
behaviour, and keep this one focused on the original reported issue?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2018-03-15 Thread Cheryl Sabella

Cheryl Sabella  added the comment:

Should the documentation patch for this be converted to a PR or does this need 
to change to a bug issue to address Mark's concerns?

Thanks!

--
nosy: +csabella
stage:  -> needs patch
versions: +Python 3.7, Python 3.8 -Python 3.5

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2015-12-01 Thread Sonali Gupta

Sonali Gupta added the comment:

States that math.factorial(x) returns x factorial as an integer.

--
keywords: +patch
nosy: +mine0901
Added file: http://bugs.python.org/file41206/bug.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2015-11-28 Thread Mark Dickinson

Mark Dickinson added the comment:

[Terry]

>>> factorial(decimal.Decimal(5.2))
120

Yep, that's definitely wrong. If we want to behave the same way as for float, 
we should accept only integral Decimal values. (Though I'm not much of a fan of 
the float behaviour: I would have preferred math.factorial not to accept floats 
at all.)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25735] math.factorial doc should mention integer return type

2015-11-25 Thread John Yeung

New submission from John Yeung:

The math module docs state

Except when explicitly noted otherwise, all return values are floats.

But math.factorial isn't what I would call explicit about returning int:

math.factorial(x)
Return x factorial. Raises ValueError if x is not integral or is negative.

At minimum, shouldn't the first sentence be "Return x factorial as an int."? I 
haven't tested on all Python versions, but math.factorial on 2.7 and 3.2 
definitely return int (or long in Python 2 when necessary).

--
assignee: docs@python
components: Documentation
messages: 255382
nosy: John.Yeung, docs@python
priority: normal
severity: normal
status: open
title: math.factorial doc should mention integer return type
versions: Python 3.5

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com