Skip to content

Conversation

@vivekvashist
Copy link
Contributor

No description provided.

@abates
Copy link
Contributor

abates commented Nov 14, 2022

I think if we're being pedantic, it should be classful with only one "l", see here

@vivekvashist
Copy link
Contributor Author

I think if we're being pedantic, it should be classful with only one "l", see here

Ah, that is technically correct - If you want I can update this RR and resubmit.

netutils/ip.py Outdated

def is_classfull(ip_network: str) -> bool: # noqa: D300,D301
"""Determines if a CIDR network address is within unicast class full boundaries.
"""Determines if a CIDR network address is within unicast classfull boundaries.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"""Determines if a CIDR network address is within unicast classfull boundaries.
"""Determines if a CIDR network address is within unicast classful boundaries.

netutils/ip.py Outdated

Returns:
Whether or not the network falls within class full boundaries.
Whether or not the network falls within classfull boundaries.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
Whether or not the network falls within classfull boundaries.
Whether or not the network falls within classful boundaries.

netutils/ip.py Outdated
"""
net = ipaddress.ip_network(ip_network)
# Only IPv4 addresses can be classified as class full
# Only IPv4 addresses can be classified as classfull
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Only IPv4 addresses can be classified as classfull
# Only IPv4 addresses can be classified as classful

netutils/ip.py Outdated
@@ -159,7 +159,7 @@ def ip_subtract(ip: str, val: int) -> str:


def is_classfull(ip_network: str) -> bool: # noqa: D300,D301
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
def is_classfull(ip_network: str) -> bool: # noqa: D300,D301
def is_classful(ip_network: str) -> bool: # noqa: D300,D301

@abates
Copy link
Contributor

abates commented Nov 15, 2022

Ah, that is technically correct - If you want I can update this RR and resubmit.

Since you already have a PR going those changes would be great. I still can't believe I spelled it wrong in the first place 🤦

@vivekvashist
Copy link
Contributor Author

Apologies, I got my branching messed up and accidentally created a new PR :(

@abates
Copy link
Contributor

abates commented Nov 16, 2022

@vivekvashist: No worries. Can the other PR be closed?

@vivekvashist
Copy link
Contributor Author

Done.

@qduk
Copy link
Collaborator

qduk commented Nov 29, 2022

Closing as #174 addressed the issue.

@qduk qduk closed this Nov 29, 2022
@vivekvashist
Copy link
Contributor Author

Not sure if this was closed by accident but the following changes are are still pending

91c777d

@abates
Copy link
Contributor

abates commented Nov 30, 2022

@vivekvashist we got confused with the other PR and thought these changes had already been merged.

@abates abates reopened this Nov 30, 2022
@abates
Copy link
Contributor

abates commented Nov 30, 2022

@vivekvashist can you please fix this PR so that the tests pass?

@vivekvashist
Copy link
Contributor Author

(netutils-py3.10) ~/D/netutils ❯❯❯ pytest -k test_docs_generated --no-header                                              ✘ 4 develop
======================================================== test session starts ========================================================
collected 438 items / 437 deselected / 1 selected

tests/unit/test_docs.py::test_docs_generated PASSED                                                                           [100%]

================================================= 1 passed, 437 deselected in 1.89s =================================================
(netutils-py3.10) ~/D/netutils ❯❯❯

@itdependsnetworks itdependsnetworks merged commit c43d253 into networktocode:develop Dec 16, 2022
michalis1 pushed a commit to michalis1/netutils that referenced this pull request Feb 2, 2026
* Minor updates

fix classfull address naming in ip.py

* PR#networktocode#173 Fix classful naming

* fixing broken tests
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants