[issue36181] Add mode parameter to PurePath.write_text to allow for 'a' mode

2019-03-04 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> rejected stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Pytho

[issue36181] Add mode parameter to PurePath.write_text to allow for 'a' mode

2019-03-04 Thread Vinay Rao
Vinay Rao added the comment: Oh, and write_bytes would have to go thorough the same modification to make them consistent. -- ___ Python tracker ___ __

[issue36181] Add mode parameter to PurePath.write_text to allow for 'a' mode

2019-03-04 Thread Vinay Rao
Vinay Rao added the comment: Upon reading the issue threads linked by @xtreak, I have changed my mind and think this is a bad idea. 1) It adds more to maintain without offering much benefit (the use case of the shortcut is probably quite rare) 2) The argument 'mode' only accepting two options

[issue36181] Add mode parameter to PurePath.write_text to allow for 'a' mode

2019-03-04 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Not that it makes a big difference, but write_text is a method of the Path class, not PurePath. -- nosy: +lys.nikolaou ___ Python tracker __

[issue36181] Add mode parameter to PurePath.write_text to allow for 'a' mode

2019-03-04 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: append_text helper was proposed as part of issue35095 and adding a parameter append was also discussed as part of the original API issue20218 . Adding @pitrou to decide upon the API. -- nosy: +pitrou, xtreak ___

[issue36181] Add mode parameter to PurePath.write_text to allow for 'a' mode

2019-03-04 Thread Vinay Rao
New submission from Vinay Rao : - Default should be 'w' for compatibility. - There should be a check that makes sure mode is either 'w' or 'a', or else raise ValueError. -- components: Library (Lib) messages: 337097 nosy: vinayluzrao priority: normal severity: normal status: open titl