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

Return appropriate tuple for string-set:none #975

Merged
merged 1 commit into from
Nov 7, 2019

Conversation

Tontyna
Copy link
Contributor

@Tontyna Tontyna commented Oct 22, 2019

This snippet used to crash WeasyPrint with UnboundLocalError: local variable 'computed_value' referenced before assignment:

<style>
div {
  string-set: none;
}
</style>
<div>OMG</div>

Reason being the tuple-constructor in computed_values.string_set() splitting 'none' instead of a tuple consiting of a string-name and its string-value.

BTW: WeasyPrint's unconventional way of handling string-set enables declarations like string-set: none, stringname "value";.

@liZe liZe merged commit 4677318 into Kozea:master Nov 7, 2019
@liZe
Copy link
Member

liZe commented Nov 7, 2019

Of course, thank you

@liZe liZe added this to the 51 milestone Nov 7, 2019
@liZe liZe added the crash Problems preventing documents from being rendered label Nov 7, 2019
@Tontyna Tontyna deleted the string-set-crash branch November 7, 2019 15:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
crash Problems preventing documents from being rendered
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants