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

Allow TFuncKey to be used without specifying the namespace, in the … #1262

Merged
merged 6 commits into from
Feb 24, 2021
Merged

Allow TFuncKey to be used without specifying the namespace, in the … #1262

merged 6 commits into from
Feb 24, 2021

Conversation

raynor85
Copy link

@raynor85 raynor85 commented Feb 18, 2021

…same way TFunction and useTranslation work

Checklist

  • only relevant code is changed (make a diff before you submit the PR)
  • run tests npm run test
  • tests are included
  • documentation is changed or added

…same way `TFunction` and `useTranslation` work
Copy link
Member

@pedrodurek pedrodurek left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks for your contribution! 🙌

@jamuhl
Copy link
Member

jamuhl commented Feb 20, 2021

@raynor85 @pedrodurek there is a breaking test - I'm not sure about what and why - but can't be merged before fixed

https://app.circleci.com/pipelines/github/i18next/react-i18next/582/workflows/2c506949-6fcc-4e30-80ed-c48e049b5711/jobs/526

@raynor85
Copy link
Author

@raynor85 @pedrodurek there is a breaking test - I'm not sure about what and why - but can't be merged before fixed

https://app.circleci.com/pipelines/github/i18next/react-i18next/582/workflows/2c506949-6fcc-4e30-80ed-c48e049b5711/jobs/526

The same test was failing on my local branch just after I forked the project, before adding my changes.

@raynor85
Copy link
Author

@raynor85 @pedrodurek there is a breaking test - I'm not sure about what and why - but can't be merged before fixed
https://app.circleci.com/pipelines/github/i18next/react-i18next/582/workflows/2c506949-6fcc-4e30-80ed-c48e049b5711/jobs/526

The same test was failing on my local branch just after I forked the project, before adding my changes.

For some weird reason, I just retried locally and all the tests passed. @jamuhl @pedrodurek can any of you retrigger the circleci build? I think it was a temporary failure. I can't do it on my end without pushing other code

@raynor85
Copy link
Author

raynor85 commented Feb 23, 2021

It looks like circleci is reusing a corrupted node_module folder as highlighted in the Restoring cache section:

Found a cache from build 525 at dependency-cache-r9gAW0IGK7w2nqduXpPf_YLxJmRqL7As2VJ56Km4t64=
Size: 39 MiB
Cached paths:
  * /home/circleci/project/node_modules

I think someone should try to invalidate the cache and rerun the build. The tests pass locally, but they still fail in the remote server.

@jamuhl
Copy link
Member

jamuhl commented Feb 23, 2021

not found any way to invalidate that

@pedrodurek
Copy link
Member

pedrodurek commented Feb 23, 2021

Hey @jamuhl, usually when we cache dependencies on CircleCI we add v#- as a prefix to the cache key, for instance: v1-dependency-cache-{{ checksum "package.json" }}. This way, in case the cached node_modules corrupts, we don't need to wait 15 days for the cached dependencies to become invalid, we can simply bump the version under restore_cache and save_cache (config.yml file). Like this: v2-dependency-cache-{{ checksum "package.json" }}.
Here you can find more info about that.

@coveralls
Copy link

coveralls commented Feb 23, 2021

Coverage Status

Coverage remained the same at 96.163% when pulling f47be75 on raynor85:master into ce14f34 on i18next:master.

@pedrodurek
Copy link
Member

pedrodurek commented Feb 23, 2021

To prevent from manually bumping the version in the config.yml file, you can create an environment variable, and control the cache version from there. For example:
${CACHE_VERSION}-dependency-cache-{{ checksum "package.json" }}

@raynor85
Copy link
Author

raynor85 commented Feb 23, 2021

Yeah, I pushed a change in one of the dependency in package.json which forced circleci to run a fresh build, which was successful https://app.circleci.com/pipelines/github/i18next/react-i18next/584/workflows/2c1a055d-b2a4-4dc4-b8da-7142bcc265a3/jobs/531
I then rollback it in another commit, but the cached version for that one is still there. I am afraid that every other PR will encounter the same issue, unless they change some dependencies.

@raynor85
Copy link
Author

raynor85 commented Feb 23, 2021

I ended up bumping the dependencies to invalidate the cache. This prevents circleci to cache the corrupted build, and it will prevent other contributors to have the same issue if this PR is merged. Ideally this should be handled separately, but this workaround is the best I can do in my power. I hope to see this merged soon :)

@jamuhl jamuhl merged commit 232efef into i18next:master Feb 24, 2021
@jamuhl
Copy link
Member

jamuhl commented Feb 24, 2021

thank you for solving this...

the PR was merged and published in react-i18next@11.8.8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants