I'm following-up on this because someone mentioned in an issue ticket against yamlpath that you'd been fixing some date/datetime handling issue(s) in ruamel.yaml. While I can't find any mention of this in your change log, I'd like to try to draw your attention to this issue again, anyway. If you are making any changes to TimeStamp/AnchoredTimeStamp/etc, please remember to add Anchor handling. Unrelated: I'll open a new ticket for the TimeZone handling issue, above. I'm not sure why I tacked it onto...
Thank you! I'll incorporate this and see how it fares in my project. I haven't encountered any users attempting to anchor null values in YAML, yet; so, I'm not worried about that edge-case, just yet. Query: Is it really necessary to perform the UTC conversion against the timestamp values? This conversion has forced me to add code to "undo" it whenever users query timestamp nodes, otherwise they end up with datetime values that are time-zone naive; in other words, they don't get out what they put...
Thank you! I'll incorporate this and see how it fares in my project. I haven't encountered any users attempting to anchor null values in YAML, yet; so, I'm not worried about that edge-case, just yet. Query: Is it really necessary to perform the UTC conversion against the timestamp values? This conversion has forced me to add code to "undo" it whenever users query timestamp nodes, otherwise they end up with datetime values that are time-zone naive; in other words, they don't get out what they put...
Thank you! I'll incorporate this and see how it fares in my project. I haven't encountered any users attempting to anchor null values in YAML, yet; so, I'm not worried about that edge-case, just yet. Query: Is it really necessary to perform the UTC conversion against the timestamp values? This conversion has forced me to add code to "undo" it whenever users query timestamp nodes, otherwise they end up with datetime values that are time-zone naive; in other words, they don't get out what they put...
Anchored date and TimeStamp values lose their anchors
Absolutely true! I fight the same battles from time to time, so I know your pain. I learned very early the same lesson, so you'll find I use types as religiously as I can bear to. You can quiet a lot of the mypy noise regarding returning Any with a mypy.ini entry like: [mypy] warn_return_any = True I do the same for my project because I haven't spent enough time to zero-in on just what ruamel.yaml returns for many of its methods. :)
Most surprisingly, 0.17.6 and 0.17.7 both cause MYPY to become more strict with regard to my uses of CommentedMap and CommentedSeq. I verified by downgrading ruamel.yaml and running the same test suite; the strictness relaxed. Upgrading to 0.17.6+ has forced me to more strictly type my own variables wherever I'm interacting with CommentedMap and CommentedSeq. I'm not saying this is bad; it's just a surprising side-effect. I don't mind the stricter typing. That said, all 1,188 of my unit tests, plus...
Quick follow-up: I'm unable to use 0.17.5 because my tests won't complete with it. It looks like a couple of Type signatures are misaligned with their signatures: mypy errors: ./lib/python3.6/site-packages/ruamel/yaml/comments.py:92: error: Type signature has too few arguments ./lib/python3.6/site-packages/ruamel/yaml/tokens.py:348: error: Type signature has too few arguments I know you were having some issues getting your test suite to run. I hope the above can help in some way.