nuxt-modules / i18n

I18n module for Nuxt
https://i18n.nuxtjs.org
MIT License
1.71k stars 478 forks source link

Update `nuxt-module-builder` to fix broken plugin inejcted types with `vue-tsc` 2.0+ #2938

Closed ennioVisco closed 3 months ago

ennioVisco commented 5 months ago

Environment

-

Reproduction

https://github.com/nuxt-modules/i18n/blob/b3114556a92f5f7622b37d7b57e681e1f7e3660d/package.json#L111

Describe the bug

This upstream bug has been solved in 0.6.0: https://github.com/nuxt/module-builder/pull/255, so the dependency should be bumped asap to avoid the following type issue:

Screenshot 2024-04-28 at 14 42 52

Additional context

No response

Logs

No response

github-actions[bot] commented 5 months ago

Would you be able to provide a reproduction? 🙏

More info ### Why do I need to provide a reproduction? Reproductions make it possible for us to triage and fix issues quickly with a relatively small team. It helps us discover the source of the problem, and also can reveal assumptions you or we might be making. ### What will happen? If you've provided a reproduction, we'll remove the label and try to reproduce the issue. If we can, we'll mark it as a bug and prioritise it based on its severity and how many people we think it might affect. If `needs reproduction` labeled issues don't receive any substantial activity (e.g., new comments featuring a reproduction link), we'll close them. That's not because we don't care! At any point, feel free to comment with a reproduction and we'll reopen it. ### How can I create a reproduction? We have a couple of templates for starting with a minimal reproduction: 👉 [Reproduction starter (v8 and higher)](https://stackblitz.com/fork/github/BobbieGoede/nuxt-i18n-starter/tree/v8) 👉 [Reproduction starter (edge)](https://stackblitz.com/fork/github/BobbieGoede/nuxt-i18n-starter/tree/edge) A public GitHub repository is also perfect. 👌 Please ensure that the reproduction is as **minimal** as possible. See more details [in our guide](https://nuxt.com/docs/community/reporting-bugs/#create-a-minimal-reproduction). You might also find these other articles interesting and/or helpful: - [The Importance of Reproductions](https://antfu.me/posts/why-reproductions-are-required) - [How to Generate a Minimal, Complete, and Verifiable Example](https://stackoverflow.com/help/mcve)
ennioVisco commented 5 months ago

@BobbieGoede this does not need a reproduction, it's related to vue-tsc v2 that breaks the type checking in almost any nuxt instance (you can try in a vanilla nuxt environment using vue-tsc2). If you missed the countless issues related to this (some of which are mentioned in the PR I linked), I can add them, I don't really see the point though.

BobbieGoede commented 5 months ago

@ennioVisco Have you read the explanation provided by the github-actions comment asking for a reproduction?

I could update the nuxt-module-builder dependency and create a reproduction myself to confirm that this actually resolves your issue but I'm busy with my day job at the moment.

ennioVisco commented 5 months ago

@ennioVisco Have you read the explanation provided by the github-actions comment asking for a reproduction?

I could update the nuxt-module-builder dependency and create a reproduction myself to confirm that this actually resolves your issue but I'm busy with my day job at the moment.

I did read the github-action, in fact, I'm a long time member of the nuxt community, I know the message by heart now, and I usually provide reproductions, but in this case it is honestly unneeded bureaucracy for everybody:

  1. it's about updating a dependency, which is something maintainers would do anyway
  2. I'm pointing out a merged fix to the dependency where three (3!) issues w/ reproductions were provided confirming the issue and related fix.
  3. It's about the most known bug in the whole vue community that is present since this release https://github.com/vuejs/language-tools/releases/tag/v2.0.0 two months ago, with issues spammed everywhere from vue's repo, twitter, and nuxt.
  4. Btw I also happen to have a day job and give value to my time.
  5. I did not disappear, I'm here, I would be happy to support further studies if updating the dep does not solve the issue.

What exactly would be the added value of spending even 5 minutes in preparing a reproduction in this case? I'd love if you could enlighten me, because I just don't get it.

BobbieGoede commented 5 months ago

What exactly would be the added value of spending even 5 minutes in preparing a reproduction in this case? I'd love if you could enlighten me, because I just don't get it.

Because I am the one who ends up creating a reproduction otherwise I won't be able to confirm if updating the dependency actually resolves the issue you describe, while you already know which steps are required to trigger the type error.

but in this case it is honestly unneeded bureaucracy for everybody:

  1. Btw I also happen to have a day job and give value to my time.
  2. I did not disappear, I'm here, I would be happy to support further studies if updating the dep does not solve the issue.

I don't doubt your intentions, but my initial impression was the following: issue is opened and required fields in issue template are ignored while requesting a dependency update ASAP.

You could have opened a PR to update the dependency and mentioned the same info as points 2 and 3 instead, if all worked well it likely would have been merged already.

Even though I have only been part of this project for little over a year, I have spent many hours (if not days) on issues without a reproduction, these issues often turn out to be a local issue or misconfiguration.

ennioVisco commented 5 months ago

Because I am the one who ends up creating a reproduction otherwise I won't be able to confirm if updating the dependency actually resolves the issue you describe, while you already know which steps are required to trigger the type error.

I apologize, I didn't get you'd need to reproduce it in the case of updating a dependency, I've seen several time a request for re-check by the issuer after the update in these cases.

I don't doubt your intentions, but my initial impression was the following: issue is opened and required fields in issue template are ignored while requesting a dependency update ASAP. It makes sense, I was not clear enough. My mistake.

You could have opened a PR to update the dependency and mentioned the same info as points 2 and 3 instead, if all worked well it likely would have been merged already.

That's true, I didn't have the time to fork, update and re-test unfortunately, which I assumed to be much more than the one needed by a maintainer to bump the dependencies and re-run the unit tests.

Even though I have only been part of this project for little over a year, I have spent many hours (if not days) on issues without a reproduction, these issues often turn out to be a local issue or misconfiguration.

Yeah, I know, this makes sense. In any case, should you need a reproduction/PR I will try to reserve some time for it in the upcoming days.

BobbieGoede commented 4 months ago

Can you confirm if this issue is resolved using edge release? @nuxtjs/i18n-edge