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

Add ability to tweak display of fields in formatted output #93

Open
iamed2 opened this issue Jul 18, 2018 · 5 comments
Open

Add ability to tweak display of fields in formatted output #93

iamed2 opened this issue Jul 18, 2018 · 5 comments

Comments

@iamed2
Copy link
Member

iamed2 commented Jul 18, 2018

Ideas:

  • Give DefaultFormatter a dict of transforms
  • Use a more advance formatting string like Formatting.jl
@rofinn
Copy link
Member

rofinn commented Feb 10, 2020

My understanding is that this would mean that we should rewrite the formatter to use Formatting.jl.

@rofinn rofinn self-assigned this Feb 10, 2020
@rofinn rofinn added this to the 1.0 milestone Feb 10, 2020
@rofinn
Copy link
Member

rofinn commented Feb 14, 2020

After looking into Formatting.jl it seems like this package won't fit our requirements out of the box, so I'm not going to include this in our 1.0 release. Specifically, we'd need to add support for named arguments to format/printfmt.

@rofinn rofinn removed this from the 1.0 milestone Feb 14, 2020
@ScottPJones
Copy link

Have you looked at Format?
It is based off of Formatting.jl (there was a period where Formatting.jl was still in a personal repo, and was not getting maintained much, so I ended up forking it and using it as the bases of Format.jl, which has diverged somewhat, with the addition of a default formatting (based off a PR to Formatting.jl by Tom Breloff.
I'd be happy to look at adding any capabilities that you'd need for use by Memento, also.

@rofinn
Copy link
Member

rofinn commented Oct 26, 2020

I have not, but looking at the README the primary feature needed doesn't exist yet. Specifically, the README states that:

It hasn't supported named arguments or fields extraction yet

I think if it added support for named arguments then our format strings (e.g., "[{level} | {name}]: {msg}") would just work and we could make that switch easily.

@ScottPJones
Copy link

I've concentrated more on the C format side of the package, as that is what I mostly use.
These days I'm spending more time with Python code (rewriting Numpy code in Julia for better performance and future flexibility) for my day job, so having full Python syntax support would be nice for me as well.
As always, any PRs (or reviews of any PRs I put up for adding those features) are welcome!

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

No branches or pull requests

3 participants