[issue21386] ipaddress.IPv4Address.is_global not implemented

2016-06-11 Thread Berker Peksag

Berker Peksag added the comment:

Thanks Roger!

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

___
Python tracker 

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2016-06-11 Thread Roundup Robot

Roundup Robot added the comment:

New changeset d65191861599 by Berker Peksag in branch '3.5':
Issue #21386: Implement missing IPv4Address.is_global property
https://hg.python.org/cpython/rev/d65191861599

New changeset 1519ca772e54 by Berker Peksag in branch 'default':
Issue #21386: Merge from 3.5
https://hg.python.org/cpython/rev/1519ca772e54

--
nosy: +python-dev

___
Python tracker 

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2016-06-10 Thread Berker Peksag

Berker Peksag added the comment:

Here is an updated patch that uses my proposal in msg219017. Since this is 
already documented at 
https://docs.python.org/3.5/library/ipaddress.html#ipaddress.IPv4Address.is_global
 I think it should also go into 3.5.

--
versions: +Python 3.6
Added file: http://bugs.python.org/file43337/issue21386_v3.diff

___
Python tracker 

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2014-06-06 Thread Roger Luethi

Roger Luethi added the comment:

Seeing that the patch merged for issue 21513 left the existing test for 
100.64.0.0 (IPv4 network) untouched, I think it would make more sense to make 
that address a constant everywhere in a separate patch (if that is indeed 
desirable).

--

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2014-05-23 Thread Berker Peksag

Berker Peksag added the comment:

+@property
+def is_global(self):
+return (not self in IPv4Network('100.64.0.0/10') and

Can IPv4Network('100.64.0.0/10') moved to the _IPv4Constants class (e.g. 
_IPv4Constants._global_network = IPv4Network('100.64.0.0/10')) after 
http://hg.python.org/cpython/rev/e5d963cb6afc (see also issue 21513)

+not self.is_private)

--
nosy: +berker.peksag
stage:  - patch review
versions:  -Python 3.4

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2014-05-19 Thread Santoso Wijaya

Changes by Santoso Wijaya santoso.wij...@gmail.com:


--
nosy: +santa4nt
type:  - enhancement

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2014-05-18 Thread Roger Luethi

Roger Luethi added the comment:

New patch includes tests.

Lightly tested with Python 3.4 (because trunk doesn't build for me right now): 
tests fail without patch, pass with patch.

Patch re-diffed against trunk.

--
Added file: http://bugs.python.org/file35281/ipv4addr_global2-hg.diff

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2014-05-17 Thread R. David Murray

R. David Murray added the comment:

The patch looks correct to me, but we also need tests.

--
nosy: +r.david.murray

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2014-04-29 Thread Roger Luethi

New submission from Roger Luethi:

Lib/ipaddress.py does not implement is_global for IPv4Address, in contrast to 
the documentation which states for IPv4Address.is_global: True if the address 
is allocated for public networks.

A patch like the one attached to this report should fix that.

--
components: Library (Lib)
files: ipv4addr_global.diff
keywords: patch
messages: 217511
nosy: rluethi
priority: normal
severity: normal
status: open
title: ipaddress.IPv4Address.is_global not implemented
versions: Python 3.4, Python 3.5
Added file: http://bugs.python.org/file35092/ipv4addr_global.diff

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



[issue21386] ipaddress.IPv4Address.is_global not implemented

2014-04-29 Thread Eric V. Smith

Changes by Eric V. Smith e...@trueblade.com:


--
nosy: +eric.smith, ncoghlan, pmoody

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