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

decode package name for /etc/sysconfig/kernel (RHBZ #1261569) #409

Closed
wants to merge 1 commit into
base: master
from

Conversation

Projects
None yet
3 participants
@AdamWill
Contributor

AdamWill commented Oct 15, 2015

Seems in Python 3 when we get a package name from RPM in this
way it comes out as a bytestring, we need a regular string as
we're going to write it into a text file. Without this fix
/etc/sysconfig/kernel gets a line:

DEFAULTKERNEL=b'kernel-core'

which obviously isn't what we wanted, and means new kernels
sometimes don't get set as the default boot option.

decode package name for /etc/sysconfig/kernel (RHBZ #1261569)
Seems in Python 3 when we get a package name from RPM in this
way it comes out as a bytestring, we need a regular string as
we're going to write it into a text file. Without this fix
/etc/sysconfig/kernel gets a line:

DEFAULTKERNEL=b'kernel-core'

which obviously isn't what we wanted, and means new kernels
sometimes don't get set as the default boot option.
@vpodzime

This comment has been minimized.

Show comment
Hide comment
@vpodzime

vpodzime Oct 15, 2015

Contributor

I wish Python3's str() returned just the string for a bytestring. Like anybody cared about/wanted the b'..' enclosing. This looks good to me.

Contributor

vpodzime commented Oct 15, 2015

I wish Python3's str() returned just the string for a bytestring. Like anybody cared about/wanted the b'..' enclosing. This looks good to me.

@vpodzime vpodzime added the ACK label Oct 15, 2015

@snbueno

This comment has been minimized.

Show comment
Hide comment
@snbueno

snbueno Oct 20, 2015

Contributor

I've pushed this manually to master and f23-branch, so I'm closing this.

Contributor

snbueno commented Oct 20, 2015

I've pushed this manually to master and f23-branch, so I'm closing this.

@snbueno snbueno closed this Oct 20, 2015

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