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

Bump cspell to 8.3.2 #2537

Merged
merged 1 commit into from
Jan 5, 2024

Conversation

IT-VBFK
Copy link
Contributor

@IT-VBFK IT-VBFK commented Jan 5, 2024

Reason:

Before it had a strange error when running yarn install (GHA build and locally)
image

After googling this error I found this issue: yarnpkg/yarn#4812

And one of the tips was: yarnpkg/yarn#4812 (comment)

So I deleted the lock file and run yarn install again, but this time it installs the latest 8 (8.3.2 at this moment) and the error was gone afterwards

IMPORTANT

  • If the PR touches the public API, the changes have been approved in a separate issue with the "api-approved" label.
  • The code complies with the Coding Guidelines for C#.
  • The changes are covered by unit tests which follow the Arrange-Act-Assert syntax and the naming conventions such as is used in these tests.
  • If the PR adds a feature or fixes a bug, please update the release notes with a functional description that explains what the change means to consumers of this library, which are published on the website.
  • If the PR changes the public API the changes needs to be included by running AcceptApiChanges.ps1 or AcceptApiChanges.sh.
  • If the PR affects the documentation, please include your changes in this pull request so the documentation will appear on the website.
    • Please also run ./build.sh --target spellcheck or .\build.ps1 --target spellcheck before pushing and check the good outcome

Copy link

github-actions bot commented Jan 5, 2024

Qodana for .NET

It seems all right 👌

No new problems were found according to the checks applied

💡 Qodana analysis was run in the pull request mode: only the changed files were checked
☁️ View the detailed Qodana report

Contact Qodana team

Contact us at [email protected]

@coveralls
Copy link

Pull Request Test Coverage Report for Build 7423435531

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 97.466%

Totals Coverage Status
Change from base Build 7419094749: 0.0%
Covered Lines: 11748
Relevant Lines: 11932

💛 - Coveralls

@jnyrup jnyrup changed the title Bump yarn to latest 8 manually Bump cspell to 8.3.2 Jan 5, 2024
@jnyrup
Copy link
Member

jnyrup commented Jan 5, 2024

Thanks for looking into this.

I was mislead by seemingly passing pipelines in #2531
The problematic changes are
https://github.com/fluentassertions/fluentassertions/pull/2531/files#diff-51e4f558fae534656963876761c95b83b6ef5da5103c4adef6768219ed76c2deR986-R1008

which, as far as I understand the lock-file, maps both string-width-cjs and string-width to string-width-cjs, which makes the disk caching mechanism trying to write both to same destination.

https://github.com/fluentassertions/fluentassertions/actions/runs/7378193454/job/20073037546
image

We need a way to distinguish between failing due to spelling mistakes and failing due to anything else...

@jnyrup jnyrup added the building Building and Infrastructure of Fluent Assertions label Jan 5, 2024
@jnyrup jnyrup merged commit 28c4fc2 into fluentassertions:develop Jan 5, 2024
5 checks passed
@IT-VBFK IT-VBFK deleted the fix/yarn_install_output branch January 5, 2024 15:54
@IT-VBFK
Copy link
Contributor Author

IT-VBFK commented Jan 5, 2024

Hmm.. I don't get why it keeps failing on develop? Locally it works (for me)

@jnyrup
Copy link
Member

jnyrup commented Jan 5, 2024

It already started failing with #2528

Reading more of yarnpkg/yarn#4812 and isaacs/jackspeak#5 it sounds like a yarn bug, that has been fixed in newer versions of yarn.

natemcmaster/Yarn.MSBuild#22 (comment)

Project is being archived now. This project will not be worked on any longer, even for maintenance.

@IT-VBFK
Copy link
Contributor Author

IT-VBFK commented Jan 5, 2024

Ok..
Because this package is no longer maintained.. Should we just ignore these sort of errors?

e.g. something like:

Node($"{YarnCli} --silent install", workingDirectory: RootDirectory,
    logger: (_, msg) =>
    {
        if (msg.Contains("warning Pattern")) Information(msg);
        else Error(msg);
    });

or even:

Node($"{YarnCli} --silent install", workingDirectory: RootDirectory,
    logger: (_, msg) =>
    {
        if (!msg.Contains("warning Pattern")) Error(msg);
    });

@IT-VBFK
Copy link
Contributor Author

IT-VBFK commented Jan 5, 2024

#2538

@jnyrup
Copy link
Member

jnyrup commented Jan 6, 2024

Running git clean -fdx; .\build.ps1 SpellCheck consistently provokes the error for me locally.
That explains why it behaves different locally than in GH pipelines.

Because this package is no longer maintained.. Should we just ignore these sort of errors?

Normally that implies to me, that I should start looking for an alternative to Yarn.MSBuild.
I have little experience with npm/yarn/bun/whatever and frankly what to spent as little time as possible myself with that ecosystem.

Brainstorming:

  • is there an easy way to use npm - spending five minutes Googling it seems that the speed benefits that Yarn gave has also been incorporated into npm.
  • Instead of downloading yarn via a nuget package, could we just download it from "somewhere" more official?

@IT-VBFK
Copy link
Contributor Author

IT-VBFK commented Jan 6, 2024

What about ignoring for now and hope for nuke-build/nuke#1151 ?

@jnyrup
Copy link
Member

jnyrup commented Jan 6, 2024

I'm fine with ignoring for now, I'm just thinking about the future.
e.g. when cspell or one it's dependencies start using a feature that is completely unsupported by yarn 1.22.19.
Then we're stuck with the previous version of cspell.

I'm also subscribing to that PR, but as I understand it, it doesn't include yarn, but expects it to be present on the system.

@dennisdoomen
Copy link
Member

Yes, we can switch to NPM as well, but we have to investiage whether we can do that without having to install NPM on the build agent.

@IT-VBFK
Copy link
Contributor Author

IT-VBFK commented Jan 6, 2024

We probably can mimic what this script does: https://www.npmjs.com/package/npm/v/10.2.5#direct-download

@IT-VBFK
Copy link
Contributor Author

IT-VBFK commented Jan 7, 2024

What's quite cool is: we don't have to install npm manually..
Digging into the package node.js.redist I noticed following:
image

So.. actually... this works, and also could be injected to a NUKE tool, like Node itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
building Building and Infrastructure of Fluent Assertions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants