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

Wrong syntax in logging statements #435

Closed
eguiraud-pf opened this issue Jul 11, 2024 · 5 comments
Closed

Wrong syntax in logging statements #435

eguiraud-pf opened this issue Jul 11, 2024 · 5 comments

Comments

@eguiraud-pf
Copy link

Hello,

the logging code here:

https://github.com/hiddenSymmetries/simsopt/blame/f6a8412047ad418ba287ee9c32c707802f064970/src/simsopt/mhd/boozer.py#L181-L182

seems wrong, and triggers the following exception when running with log level INFO:

    self.boozer.run()
  File "/home/devuser/.cache/pants/named_caches/pex_root/venvs/s/f700390b/venv/lib/python3.10/site-packages/simsopt/mhd/boozer.py", line 179, in run
    logger.info('mnmax:', wout.mnmax, ' len(xm):', len(wout.xm), ' len(xn):', len(wout.xn))
Message: 'mnmax:'
Arguments: (72, ' len(xm):', 72, ' len(xn):', 72)

You can see the syntax is wrong by running the following at the prompt (with error instead of info so the logging actually happens):

import logging
logging.error('mnmax:', 242, ' len(xm):', 24, ' len(xn):', 24)
@landreman
Copy link
Contributor

@eguiraud-pf do you agree that #436 would resolve this?

@eguiraud-pf
Copy link
Author

thanks for the quick reaction @landreman , it should, yes!

landreman added a commit that referenced this issue Jul 11, 2024
@eguiraud
Copy link

Hello, sorry to bother, would it be possible to release a version with this fix? 🙏

@landreman
Copy link
Contributor

Ok, just created a release v1.6.4.

@eguiraud-pf
Copy link
Author

Thank you very much!

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

No branches or pull requests

3 participants