We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8110874 commit 4e73faeCopy full SHA for 4e73fae
1 file changed
docs/resources/news.rst
@@ -68,6 +68,21 @@ new
68
>>> news.save()
69
<redminelib.resources.News #8 "Foo">
70
71
+.. warning::
72
+
73
+ Redmine's News API doesn't return a news object after create operation. Due to the fact that it goes
74
+ against the behaviour of all other API endpoints, Python-Redmine has to do some tricks under the hood
75
+ to return a resource object which involve an additional API request. If that isn't desired one should
76
+ use the following technique:
77
78
+ .. code-block:: python
79
80
+ with redmine.session(return_response=False):
81
+ news = redmine.news.new()
82
+ news.title = 'Foo'
83
+ news.description = 'foobar'
84
+ news.save()
85
86
Read methods
87
------------
88
0 commit comments