Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Upgrade faker to be compatible with Elixir 1.17 #2189

Merged
merged 1 commit into from
Oct 7, 2024

Conversation

joshlarson
Copy link
Contributor

This removes the following warning, which appears any time we run any test:

warning: using map.field notation (without parentheses) to invoke function Faker.Random.Elixir.random_uniform() is deprecated, you must add parentheses instead: remote.function()
  (faker 0.18.0) lib/faker.ex:109: Faker.random_uniform/0
  (faker 0.18.0) lib/faker/address.ex:188: Faker.Address.latitude/0
  (dotcom 0.0.1) test/support/factories/stops/stop.ex:30: Test.Support.Factories.Stops.Stop.stop_factory/0
  (ex_machina 2.8.0) lib/ex_machina.ex:228: ExMachina.build/3
  (elixir 1.17.0) lib/stream.ex:1623: Stream.do_repeatedly/3
  (elixir 1.17.0) lib/enum.ex:3532: Enum.take/2
  test/stops/route_stops_test.exs:530: Stops.RouteStopsTest."test by_direction/2 returns a list of stops in one direction in the correct order doesn't crash if we didn't have stops and/or shapes"/1
  (ex_unit 1.17.0) lib/ex_unit/runner.ex:485: ExUnit.Runner.exec_test/2
  (ex_unit 1.17.0) lib/ex_unit/capture_log.ex:113: ExUnit.CaptureLog.with_log/2
  (ex_unit 1.17.0) lib/ex_unit/runner.ex:434: anonymous fn/3 in ExUnit.Runner.maybe_capture_log/3
  (stdlib 6.0) timer.erl:590: :timer.tc/2
  (ex_unit 1.17.0) lib/ex_unit/runner.ex:407: anonymous fn/6 in ExUnit.Runner.spawn_test_monitor/4

There's an open issue on the Faker repo (actually two) to cut a new release, but for now, in order to get Faker to run without warnings, we need to grab a specific SHA.

@joshlarson joshlarson requested a review from a team as a code owner October 7, 2024 14:06
@joshlarson joshlarson enabled auto-merge (squash) October 7, 2024 14:57
Copy link
Collaborator

@thecristen thecristen left a comment

Choose a reason for hiding this comment

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

Didn't realize they'd finally fixed this on their end, nice 🥳

@joshlarson joshlarson merged commit f98ea76 into main Oct 7, 2024
26 checks passed
@joshlarson joshlarson deleted the jdl/fix-faker-warnings branch October 7, 2024 15:05
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.

2 participants