Getting an error fetching i18n data for Lock when run test in Bitbucket

When running a pipeline in bitbucket it runs the tests with coverage and always fails 2 random tests and throws this error:

Error: Error: An error occurred when fetching i18n data for Lock: https://cdn.auth0.com/js/lock/11.20.3/c.js could not be loaded. thrown

At this moment can’t find some reference to fix this :frowning:

Hey there @mbermudez!

I’ve got two questions regarding that:

  • Can you post full error message here?
  • Are you using any of our docs / quickstarts for doing those tests?

Hi @mbermudez, I think the issue is ‘c.js’ is not one of our Language Dictionaries. Please see the full list here: https://github.com/auth0/lock/tree/master/src/i18n

1 Like

Thanks for pointing that Steve!

thansk for the answer, I’m gonna check that

1 Like

Thanks! Let us know if it was it

I think y found the problem, i have to let the languaje as a variable according browser lang, so I made an function. When I set any lag ‘es’ / ‘en’ on params, the pipeline run without troubles. There ir a secure way to make that param variable?