Add alias .to_file() for .to() method of structures and molecules#3356
Add alias .to_file() for .to() method of structures and molecules#3356janosh merged 9 commits intomaterialsproject:masterfrom
.to_file() for .to() method of structures and molecules#3356Conversation
|
You don't actually need to write it this way. All that needs to be done is to add |
I know, that's how I started, but when I tried to call the alias in pycharm, it wouldn't give me the input hints and at least for me they are really important. If you think that's not necessary, then I can change it to the simple alias. Also when I only added |
janosh
left a comment
There was a problem hiding this comment.
We definitely need a test for the new alias.
Aye aye! 🫡 |
|
hi @janosh I hope the tests are ok like that? |
.to_file() for .to() method of structures and molecules.to_file() for .to() method of structures and molecules
Summary
I have noticed that many beginners (including myself a while ago) find it very unintuitive to write e.g. structures to a file by using .to(), especially with the .from_file() method counterpart. That's why I added aliases
to_filefor structures and molecules.PS: This is the second attempt of #3354 as something went wrong there...