Skip to content

Conversation

@aherrera1721
Copy link
Contributor

This PR updates the vector.__repr__ method to follow the Python convention which states, "If at all possible, [the returned value] should look like a valid Python expression that could be used to recreate an object with the same value (given an appropriate environment)."

Now, calling eval(repr(v)) (where v is a vector) returns an equivalent vector.

@mwcraig
Copy link
Contributor

mwcraig commented Jun 8, 2023

Thanks @aherrera1721 for raising this issue and fixing it so quickly!

@mwcraig mwcraig merged commit fc50143 into vpython:master Jun 8, 2023
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