schemars icon indicating copy to clipboard operation
schemars copied to clipboard

Adds `ipnet` optional feature with JsonSchema for it.

Open xfbs opened this issue 4 years ago • 3 comments

IpNet is a commonly used crate for IP addresses with prefix (eg. 10.0.0.1/16). There is a merge request open on the repo, but looks like it hasn't been accepted in a 6 months. Can we add this to schemars instead?

xfbs avatar Dec 18 '21 23:12 xfbs

Preferably this can be added to the ipnet library itself. Because adding JsonSchema for all items in the ecosystem will be difficult to maintain. Seems ipnet is not updated that frequently, last update was also 6 months ago. Try contacting the maintainer (can via email, it is sometimes in the git commit history) and see if that gives any results. You can also try reviewing the PR code this might speed up how quickly the maintainer takes to review the PR.

These are usually the best ways of getting something merge. If you don't hear anything back (in a few weeks) we can look into adding it here further. (let us know one way or the other)

You can also use the repo directly in your project. https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html#specifying-dependencies-from-git-repositories That way you can use 'smklein' his schemars directly. (or fork it)

ralpha avatar Dec 20 '21 20:12 ralpha

I took a small look at the PR there ( https://github.com/krisprice/ipnet/pull/31 ). Maybe you can make some changes and get some life into the PR. Let me know if you have any questions.

ralpha avatar Dec 20 '21 20:12 ralpha

Issue/PR can be closed. Was merged in ipnetwork crate.

ralpha avatar Jul 09 '22 13:07 ralpha