Skip to content

Conversation

@orenmn
Copy link
Contributor

@orenmnorenmn commented Oct 13, 2017

In addition, add tests to test_struct to make sure the assertion failures and the crash are no more.

https://bugs.python.org/issue31779

s2=struct.Struct(s.format.encode())
self.assertEqual(s2.format, s.format)

@support.cpython_only

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is this test cpython only?

@github-actions
Copy link

This PR is stale because it has been open for 30 days with no activity.

@github-actionsgithub-actionsbot added the stale Stale PR or inactive for long period of time. label Feb 28, 2022
Copy link
Contributor

@MaxwellDupreMaxwellDupre left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good:

struct_obj.iter_unpack(b'foo')
Traceback (most recent call last):
File "", line 1, in
ValueError: Struct.init() wasn't called

Can you respond to:
pppery on 16 Sep 2018
Why is this test cpython only?

@kumaraditya303
Copy link
Contributor

Superseded by #94532

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants

@orenmn@kumaraditya303@MaxwellDupre@pppery@the-knights-who-say-ni@ezio-melotti@bedevere-bot