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

gno-specific code linters #850

Open
thehowl opened this issue May 25, 2023 · 6 comments
Open

gno-specific code linters #850

thehowl opened this issue May 25, 2023 · 6 comments
Assignees
Labels
help wanted Want to contribute? We recommend these issues. 📦 🤖 gnovm Issues or PRs gnovm related 🧾 package/realm Tag used for new Realms or Packages. 🌱 feature New update to Gno

Comments

@thehowl
Copy link
Member

thehowl commented May 25, 2023

Kick-starting off this issue off of this discussion. A linter is definitely something we'll want, adding some more checks on top of the kind already done by go linters such as revive.

While I don't necessarily agree about the related discussion, I think we can start collecting ideas about what should be added to a future linter.

One first idea, for the current state of things, is that of not having a top-level variable declaration for a map as it is not persistent.

@ajnavarro ajnavarro added 🧾 package/realm Tag used for new Realms or Packages. 📦 🤖 gnovm Issues or PRs gnovm related 🌟 improvement performance improvements, refactors ... 🌱 feature New update to Gno and removed 🌟 improvement performance improvements, refactors ... labels May 30, 2023
@moul moul mentioned this issue Jul 20, 2023
15 tasks
moul added a commit that referenced this issue Jul 31, 2023
This PR introduces a new `gno lint` subcommand, currently focused on
checking for the presence of a `gno.mod` file in a package, and it's
linked with the CI. In the future, we plan to expand `gno lint` to
support additional checks, enhancing its utility for developers and CI
integration.

Addresses #850
Addresses #927
Related with
#965 (comment)

Signed-off-by: Manfred Touron <94029+moul@users.noreply.github.com>
Co-authored-by: Miloš Živković <milos@zmilos.com>
Doozers pushed a commit to Doozers/gno that referenced this issue Aug 31, 2023
This PR introduces a new `gno lint` subcommand, currently focused on
checking for the presence of a `gno.mod` file in a package, and it's
linked with the CI. In the future, we plan to expand `gno lint` to
support additional checks, enhancing its utility for developers and CI
integration.

Addresses gnolang#850
Addresses gnolang#927
Related with
gnolang#965 (comment)

Signed-off-by: Manfred Touron <94029+moul@users.noreply.github.com>
Co-authored-by: Miloš Živković <milos@zmilos.com>
@moul moul moved this to 🌟 Wanted for Launch in 🚀 The Launch [DEPRECATED] Sep 5, 2023
@moul moul added this to the 🌟 main.gno.land (wanted) milestone Sep 8, 2023
@kristovatlas
Copy link
Contributor

Type checking PR in progress: #1730

@zivkovicmilos
Copy link
Member

cc @notJoon

@notJoon
Copy link
Member

notJoon commented Sep 12, 2024

Although it's not revive, I'm continuing to create a lint tool based on gnolangci-lint to support most of linting rules. Recently I've been implementing gno-specific rules and other linting functionalities, like auto fix.

So, in my personal opinion, I think it might be good to move this entirely to the gno side and then integrate with previous tools. What do you think about this?

https://github.com/gnoswap-labs/tlin

cc @zivkovicmilos @thehowl @moul @dongwon8247

@zivkovicmilos
Copy link
Member

@notJoon

If I'm understanding correctly, you're suggesting migrating this linter to the gnolang org?

@notJoon
Copy link
Member

notJoon commented Sep 12, 2024

If I'm understanding correctly, you're suggesting migrating this linter to the gnolang org?

@zivkovicmilos
Yes, if possible. If not, I can start over from scratch.

@zivkovicmilos zivkovicmilos added the help wanted Want to contribute? We recommend these issues. label Sep 12, 2024
@dongwon8247
Copy link
Member

Makes sense as long as it helps Gno builders.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Want to contribute? We recommend these issues. 📦 🤖 gnovm Issues or PRs gnovm related 🧾 package/realm Tag used for new Realms or Packages. 🌱 feature New update to Gno
Projects
Status: Triage
Development

No branches or pull requests

8 participants