| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,4 +1,10 @@ | |||
| 1 | + ## 2.0.2 | ||
| 2 | + | ||
| 3 | + Enhance: | ||
| 4 | + - Added logger name | ||
| 5 | + | ||
| 1 | 6 | ## 2.0.1 | |
| 7 | + | ||
| 2 | 8 | Issue: | |
| 3 | 9 | - Remove `HTTP_VIA` header support (unreliable IP information) (@yourcelf) | |
| 4 | 10 | ||
@@ -11,7 +17,7 @@ Enhance: | |||
| 11 | 17 | - Renamed the imported module from `ipware` to `python_ipware` in the `python-ipware` package. | |
| 12 | 18 | - Old usage: `from ipware import IpWare` | |
| 13 | 19 | - New usage: `from python_ipware import IpWare` | |
| 14 | - | ||
| 20 | + | ||
| 15 | 21 | ## 1.0.5 | |
| 16 | 22 | ||
| 17 | 23 | - Enhance: Readme updates | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1 +1 @@ | |||
| 1 | - __version__ = "2.0.1" | ||
| 1 | + __version__ = "2.0.2" | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -6,6 +6,8 @@ | |||
| 6 | 6 | IpAddressType = Union[ipaddress.IPv4Address, ipaddress.IPv6Address] | |
| 7 | 7 | OptionalIpAddressType = Optional[IpAddressType] | |
| 8 | 8 | ||
| 9 | + logger = logging.getLogger(__name__) | ||
| 10 | + | ||
| 9 | 11 | ||
| 10 | 12 | class IpWareMeta: | |
| 11 | 13 | """ | |
@@ -105,7 +107,7 @@ def get_ip_object( | |||
| 105 | 107 | ip = ipaddress.IPv4Address(ipv4) | |
| 106 | 108 | except ipaddress.AddressValueError: | |
| 107 | 109 | # not a valid IP address, return None | |
| 108 | - logging.info("Invalid ip address. {0}".format(ip_str)) | ||
| 110 | + logger.info("Invalid ip address. {0}".format(ip_str)) | ||
| 109 | 111 | ip = None | |
| 110 | 112 | return ip | |
| 111 | 113 | ||
@@ -324,7 +326,7 @@ def get_best_ip( | |||
| 324 | 326 | """ | |
| 325 | 327 | ||
| 326 | 328 | if not ip_list: | |
| 327 | - logging.warning("Invalid ip list provided.") | ||
| 329 | + logger.warning("Invalid ip list provided.") | ||
| 328 | 330 | return None, False | |
| 329 | 331 | ||
| 330 | 332 | # the incoming ips match our trusted proxy list | |
| Back | FazBrowse Home | New Git URL |
0 commit comments