laravel-enso/core

localizations key collection requests are broken (config get's nullified)

Closed this issue · 4 comments

This is a bug.

Prerequisites

  • Are you running the latest version?
  • Are you reporting to the correct repository?
  • Did you check the documentation?
  • Did you perform a cursory search?

Description

axios.js plugin breaks localization's key capturing

Steps to Reproduce

  1. Log in on the framework
  2. turn on key collection
  3. notice errors in console

Expected behavior

Keys to be generated

Actual behavior

vendor/laravel-enso/core/src/resources/js/modules/enso/plugins/axios.js (or it's published counterpart)
returns false to the config in certain cases; this causes axios to break. (see axios/axios#1497)

For the last couple of days we just translated a whole app without issues, so it must be something else.

The interceptor should block only identical requests (same payload), which should not be a problem.

@dorincarsin did you encounter any console errors during the translation process?

Weird, keys were not posted; modifying the interceptor to return true instead did create them all (after fixing the translation file's permissions; which gave an extra indication it never got so far as I only got the permission error after returning the config again)

i had console errors, pasted below, but the key collector worked, i found them in localisation.
image

decided to remove the experimental "feature" of filtering repetitive and possibly unwanted requests and leave this concern on the dev side.

@gandesc