faker icon indicating copy to clipboard operation
faker copied to clipboard

v3.2.3 correct?

Open rocket-turtle opened this issue 1 year ago • 3 comments

Is the Version v3.2.3 of faker correct? (https://github.com/faker-ruby/faker/blob/v3.2.3/CHANGELOG.md)

There are a lot of changes when I compare v3.2.2 and v3.2.3 on github: https://github.com/faker-ruby/faker/compare/v3.2.2...v3.2.3

But there are note the same changes in the gem: https://my.diffend.io/gems/faker/3.2.2/3.2.3

rocket-turtle avatar Feb 01 '24 17:02 rocket-turtle

Hi @rocket-turtle thanks for opening this! AFAIK, 3.2.3 is correct:

https://github.com/faker-ruby/faker/releases/tag/v3.2.3 https://github.com/faker-ruby/faker/blob/v3.2.3/CHANGELOG.md

But I am not sure how https://my.diffend.io/gems works. Not sure what they use to create those diffs. Could you ask them? not sure what to do on our end.

stefannibrasil avatar Feb 02 '24 15:02 stefannibrasil

I'm pretty sure they download the gem from https://rubygems.org/gems/faker and do some comparisons. If I download the gem and search for Music::SmashingPumpkins in the README.md it is not present.

bundle show faker ... /ruby-3.1.4@mhmr/gems/faker-3.2.3

cat ... /ruby-3.1.4@mhmr/gems/faker-3.2.3/README.md | grep 'Music::Rush'

  • Faker::Music::Rush cat ... ruby-3.1.4@mhmr/gems/faker-3.2.3/README.md | grep 'Music::SmashingPumpkins'

The github stuff seams correct maybe something in the build process of the gem was wrong?

rocket-turtle avatar Feb 05 '24 11:02 rocket-turtle

oh I see what you're saying @rocket-turtle . I think some things didn't make to the last release:

irb(main):008> Faker::VERSION
=> "3.2.3"
irb(main):009> Faker::Music::SmashingPumpkins.lyric
(irb):9:in `<main>': uninitialized constant Faker::Music::SmashingPumpkins (NameError)

We'll probably have to cut another release, thanks for reporting this!

thdaraujo avatar Feb 08 '24 01:02 thdaraujo

Hi @rocket-turtle thanks for reporting this issue. It's fixed now with the latest release: https://github.com/faker-ruby/faker/releases/tag/v3.3.0 Please let us know if you still have any issues. Thanks!

stefannibrasil avatar Mar 26 '24 00:03 stefannibrasil

For what it's worth in case anyone runs into this same issue, there seems to be a discrepancy between the released 3.2.3 version of the gem and the v3.2.3 git tag on this repo, which currently points to 50146e0582d8af486d7fbe3c0ab833cdbe6e1eed.

Compare:

# On the v3.2.3 git tag
Faker::Config.locale = "en-US"
Faker::PhoneNumber.translate("faker.cell_phone.formats")
# => ["###-###-####", "(###) ###-####", "###.###.####", "### ### ####"]

Within an app I maintain, this isn't the same value:

Faker::VERSION
# => "3.2.3"
Faker::Config.locale = "en-US"
Faker::PhoneNumber.translate("faker.cell_phone.formats")
# => 
# ["\#{PhoneNumber.area_code}-\#{PhoneNumber.exchange_code}-\#{PhoneNumber.subscriber_number}",
#  "(\#{PhoneNumber.area_code}) \#{PhoneNumber.exchange_code}-\#{PhoneNumber.subscriber_number}",
#  "\#{PhoneNumber.area_code}-\#{PhoneNumber.exchange_code}-\#{PhoneNumber.subscriber_number}",
#  "\#{PhoneNumber.area_code}.\#{PhoneNumber.exchange_code}.\#{PhoneNumber.subscriber_number}",
#  "\#{PhoneNumber.area_code}-\#{PhoneNumber.exchange_code}-\#{PhoneNumber.subscriber_number}",
#  "(\#{PhoneNumber.area_code}) \#{PhoneNumber.exchange_code}-\#{PhoneNumber.subscriber_number}",
#  "\#{PhoneNumber.area_code}-\#{PhoneNumber.exchange_code}-\#{PhoneNumber.subscriber_number}",
#  "\#{PhoneNumber.area_code}.\#{PhoneNumber.exchange_code}.\#{PhoneNumber.subscriber_number}"]

I expected the v3.2.3 tag to point to the same code that the application was using, but that wasn't the case, which hindered some debugging.

aprescott avatar Mar 27 '24 16:03 aprescott

Hi, @aprescott thank you for the detailed notes! I appreciate it.

I'm getting an error after setting the locale to 'en-US', will investigate the issue.

stefannibrasil avatar Mar 28 '24 15:03 stefannibrasil

Ah, I missed this PR: https://github.com/faker-ruby/faker/pull/2924 that solves the phone number issue. Closing this one again. Thanks, everyone!

stefannibrasil avatar Apr 02 '24 13:04 stefannibrasil

@stefannibrasil my apologies! I should have made it clear that the actual issue that led to discovering the tagging issue was handled separately. Sorry about that.

aprescott avatar Apr 02 '24 14:04 aprescott

No problem at all @aprescott 👍

stefannibrasil avatar Apr 02 '24 15:04 stefannibrasil