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

Improve string formatting #241

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

chrhansk
Copy link
Contributor

This is an experiment consisting of the following parts:

  • Make solver messages actual strings instead of bytes
  • Same for logging messages
  • Decrease verbosity a bit: There are many objective_cb messages per iterations, which clutter the output a bit, they have been reduced to being debug-only

Let me know what you think. I hope porting from bytes to string does not break compatibility.

@moorepants
Copy link
Collaborator

If anyone uses the bytes strings, for example parse it to know what message they got, then this would break things. For example if you have log_message.decode('utf-8') and then we swap to a regular string, that will break. I'm not sure how much this may happen in the wild, but we do risk breaking downstream code without a deprecation. I do think it would be nice to have these as strings, but maybe we should first issue a warning that these will change and maybe even provide a snippet that will handle either output so people could prepare their code.

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

Successfully merging this pull request may close these issues.

2 participants