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

refactor(locale): normalize animal data #2791

Merged
merged 5 commits into from
Apr 11, 2024

Conversation

xDivisionByZerox
Copy link
Member

Description

Follow-on to #2265

Normalize the entries in the animal module definitions in all locales.

I choose this module as only one file (src/locales/fr/animal/bird.ts) that exceeded the entry limit. Th rest of the changes come from sorting and deduping the datasets.

@xDivisionByZerox xDivisionByZerox added p: 1-normal Nothing urgent c: refactor PR that affects the runtime behavior, but doesn't add new features or fixes bugs c: locale Permutes locale definitions m: animal Something is referring to the animal module labels Apr 7, 2024
@xDivisionByZerox xDivisionByZerox added this to the vAnytime milestone Apr 7, 2024
@xDivisionByZerox xDivisionByZerox requested a review from a team April 7, 2024 21:35
@xDivisionByZerox xDivisionByZerox self-assigned this Apr 7, 2024
@xDivisionByZerox xDivisionByZerox requested a review from a team as a code owner April 7, 2024 21:35
Copy link

netlify bot commented Apr 7, 2024

Deploy Preview for fakerjs ready!

Name Link
🔨 Latest commit 093ccdd
🔍 Latest deploy log https://app.netlify.com/sites/fakerjs/deploys/661784dde0f6b0000948f65d
😎 Deploy Preview https://deploy-preview-2791.fakerjs.dev
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

ST-DDT
ST-DDT previously approved these changes Apr 7, 2024
Copy link
Member

@ST-DDT ST-DDT left a comment

Choose a reason for hiding this comment

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

The test snapshots need to be updated, but otherwise this looks good to me.

Copy link

codecov bot commented Apr 7, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.95%. Comparing base (fb65976) to head (093ccdd).

Additional details and impacted files
@@            Coverage Diff             @@
##             next    #2791      +/-   ##
==========================================
- Coverage   99.96%   99.95%   -0.01%     
==========================================
  Files        2971     2971              
  Lines      212696   212619      -77     
  Branches      949      945       -4     
==========================================
- Hits       212617   212526      -91     
- Misses         79       93      +14     
Files Coverage Δ
src/locales/en/animal/bear.ts 100.00% <100.00%> (ø)
src/locales/en/animal/bird.ts 100.00% <100.00%> (ø)
src/locales/en/animal/cat.ts 100.00% <100.00%> (ø)
src/locales/en/animal/cetacean.ts 100.00% <100.00%> (ø)
src/locales/en/animal/cow.ts 100.00% <100.00%> (ø)
src/locales/en/animal/crocodilia.ts 100.00% <100.00%> (ø)
src/locales/en/animal/dog.ts 100.00% <100.00%> (ø)
src/locales/en/animal/fish.ts 100.00% <100.00%> (ø)
src/locales/en/animal/horse.ts 100.00% <100.00%> (ø)
src/locales/en/animal/insect.ts 100.00% <100.00%> (ø)
... and 35 more

... and 1 file with indirect coverage changes

Copy link
Contributor

@matthewmayer matthewmayer left a comment

Choose a reason for hiding this comment

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

Is there anything we can do to speed up the normalisation code? It seems to add several seconds to every preflight run even when only running for a couple of modules.

ST-DDT
ST-DDT previously approved these changes Apr 8, 2024
Shinigami92
Shinigami92 previously approved these changes Apr 8, 2024
@xDivisionByZerox
Copy link
Member Author

Is there anything we can do to speed up the normalisation code?

Guess we can parallelize the processing of all methods in a module as well as the module processing in general. This would not fix the data normalization in general, tho. Any ideas on that?

@xDivisionByZerox xDivisionByZerox dismissed stale reviews from Shinigami92 and ST-DDT via bd505fe April 8, 2024 19:35
@xDivisionByZerox xDivisionByZerox force-pushed the refactor/locale/normalize-animal-data branch from bd505fe to 3cd809c Compare April 8, 2024 20:57
@ST-DDT ST-DDT requested review from a team, Shinigami92 and matthewmayer April 9, 2024 16:16
@ST-DDT ST-DDT enabled auto-merge (squash) April 10, 2024 13:11
@ST-DDT ST-DDT merged commit 03b965a into next Apr 11, 2024
20 checks passed
@ST-DDT ST-DDT deleted the refactor/locale/normalize-animal-data branch April 11, 2024 06:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c: locale Permutes locale definitions c: refactor PR that affects the runtime behavior, but doesn't add new features or fixes bugs m: animal Something is referring to the animal module p: 1-normal Nothing urgent
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants