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

Line Metadata not copied with line.copy() #512

Open
JPTS2 opened this issue May 30, 2024 · 0 comments
Open

Line Metadata not copied with line.copy() #512

JPTS2 opened this issue May 30, 2024 · 0 comments
Assignees

Comments

@JPTS2
Copy link

JPTS2 commented May 30, 2024

Tried to pass initial conditions via line metadata
When copying the line, metadata is lost

@giadarol- this is what caused the initial conditions not to be passed on the JSON I sent.
I copy the line, then remove extra markers used in matching before producing the output

test_line = xt.Line()
metadata = {
    "test": "test"
}
test_line.metadata = metadata
print(test_line.metadata)
test_line_copy = test_line.copy()
print(test_line_copy.metadata)

Outputs

{'test': 'test'}
{}
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

No branches or pull requests

2 participants