rust-phonenumber icon indicating copy to clipboard operation
rust-phonenumber copied to clipboard

Improve Metadata initialization time, add benchmarking, check regexps during build & general housekeeping

Open yannleretaille opened this issue 4 years ago • 4 comments

Please note that these changes depend on the not yet released version 0.2.1 of regex-cache. This should fix #26 @meh @rustonaut would be great if you guys could have a look!

yannleretaille avatar Oct 15 '20 14:10 yannleretaille

changed to semantic commit messages

yannleretaille avatar Oct 15 '20 16:10 yannleretaille

Good points, I'll see what I can do!

On Sun, Oct 18, 2020, 19:34 Philipp Korber [email protected] wrote:

@rustonaut requested changes on this pull request.

I could merge it the way it is and do the noted changes later before publishing a new version. (@meh https://github.com/meh)

In src/lib.rs https://github.com/rustonaut/rust-phonenumber/pull/27#discussion_r507189267 :

@@ -70,7 +71,7 @@ pub use crate::carrier::Carrier; mod phone_number; pub use crate::phone_number::{PhoneNumber, Type};

-mod parser; +pub mod parser;

I guess you made this public because of the benchmark.

But it's not supposed to be part of the public API so it probably should be #[doc(hidden] or similar.

In src/metadata/database.rs https://github.com/rustonaut/rust-phonenumber/pull/27#discussion_r507190331 :

}

/// Create a database from a loaded database.

  • pub fn from(meta: Vecloader::Metadata) -> Result<Self, error::LoadMetadata> {
  • pub fn from(meta: Vecloader::Metadata, check_regex: bool) -> Result<Self, error::LoadMetadata> {

This is a braking change.

Furthermore the api between from, load and parse is no inconsistent.

If we anyway do a braking change we probably want to have some opaque Options type we can pass into all of from, load and parse.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/rustonaut/rust-phonenumber/pull/27#pullrequestreview-511164369, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAF3W33JHMVRR35BQ3XVLUTSLMRLJANCNFSM4SSDDMLQ .

yannleretaille avatar Oct 18 '20 23:10 yannleretaille

@yannleretaille do you think you will have time to resume work on that PR?

fabricedesre avatar Jan 08 '21 23:01 fabricedesre

Any updates on this pr?

atymic avatar Oct 06 '21 23:10 atymic

I'm closing this as I can't hide it in my Git overview, and it likely won't get any process, and has been superseeded by the fork AFIKT.

rustonaut avatar Jun 01 '23 15:06 rustonaut

@rustonaut, we don't maintain a fork, you are writing in the live repository.

The easiest way to get it out of your dashboard is probably to reduce your access rights in the repository (if you don't intend do exercise those rights any more), or to unassign issues and PRs.

We initially wanted to keep this open, but @gferon will open an issue to track the follow-up here.

rubdos avatar Jun 05 '23 13:06 rubdos

Oh, sorry I missed that this is now a PR on whisperfish:main instead of meh:main :see_no_evil: The problem was the reviewed-by filter (so non of the proposed steps would have helped, I would love to not use that filter but due to limitations of other filters and workflows I always end up coming back to it).

rustonaut avatar Jun 05 '23 18:06 rustonaut