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

could not find implicit value for parameter tokensReader: mainargs.TokensReader[os.Path] #2857

Closed
james-s-w-clark opened this issue Nov 3, 2023 · 0 comments · Fixed by #3504
Milestone

Comments

@james-s-w-clark
Copy link
Contributor

james-s-w-clark commented Nov 3, 2023

Continuation from Discord thread.

I started from the simple reproducible case (thanks @Baccata for raising) and tried some of the suggested changes in my mill fork.

In summary I understand there are two concerns:

  1. It would be nice to have implicit value for parameter tokensReader: mainargs.TokensReader[os.Path] available by default
  2. Custom TokensReaders aren't discovered. The mainargs library provides a few readers (String, Boolean, Byte, etc.)

The former works with adding import mill.runner.MillCliConfigParser.PathRead to MillBuildRootModule, but I didn't have luck with the latter.

I didn't raise a PR here with the changes as I suppose we don't want a custom TokensReader example (covered in mainargs readme).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants