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

type casting of None in models.Changes to 'None' is wrong #2586

Closed
ReimarBauer opened this issue Dec 9, 2024 · 2 comments · Fixed by #2588
Closed

type casting of None in models.Changes to 'None' is wrong #2586

ReimarBauer opened this issue Dec 9, 2024 · 2 comments · Fixed by #2588
Milestone

Comments

@ReimarBauer
Copy link
Member

ReimarBauer commented Dec 9, 2024

By fixing #1860 with #2585 I have seen that the https://github.com/Open-MSS/MSS/blob/develop/mslib/mscolab/models.py#L210 version_name default is None. But the comparison to None https://github.com/Open-MSS/MSS/blob/develop/mslib/mscolab/file_manager.py#L466 gives not the expected result. It looks like adding waypoints stores it as "None".

In the PR I do use now .filter(str(Change.version_name) != "None")\

I don't know currently where the Type Cast happens or what's the reason.

@ReimarBauer ReimarBauer added the question Further information is requested label Dec 9, 2024
@ReimarBauer ReimarBauer added this to the 10.0.0 milestone Dec 9, 2024
@ReimarBauer
Copy link
Member Author

ReimarBauer commented Dec 9, 2024

@ReimarBauer ReimarBauer removed the question Further information is requested label Dec 10, 2024
@ReimarBauer
Copy link
Member Author

The None cast needs to be undone

@ReimarBauer ReimarBauer changed the title review defaults / casting of None in models.Changes to str? type casting of None in models.Changes to 'None' is wrong Dec 10, 2024
@ReimarBauer ReimarBauer linked a pull request Dec 10, 2024 that will close this issue
@ReimarBauer ReimarBauer modified the milestones: 10.0.0, 9.3.0 Dec 16, 2024
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 a pull request may close this issue.

1 participant