changelog-3.0.rst 81 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698
  1. .. _changelog-3.0:
  2. ================
  3. Change history
  4. ================
  5. .. contents::
  6. :local:
  7. If you're looking for versions prior to 3.0.x you should go to :ref:`history`.
  8. .. _version-3.0.22:
  9. 3.0.22
  10. ======
  11. :release-date: 2013-08-16 16:30 P.M BST
  12. - Now depends on :ref:`Kombu 2.5.13 <kombu:version-2.5.13>`.
  13. - Now depends on :mod:`billiard` 2.7.3.32
  14. - Fixed bug with monthly and yearly crontabs (Issue #1465).
  15. Fix contributed by Guillaume Gauvrit.
  16. - Fixed memory leak caused by time limits (Issue #1129, Issue #1427)
  17. - Worker will now sleep if being restarted more than 5 times
  18. in one second to avoid spamming with ``worker-online`` events.
  19. - Includes documentation fixes
  20. Contributed by: Ken Fromm, Andreas Savvides, Alex Kiriukha,
  21. Michael Fladischer.
  22. .. _version-3.0.21:
  23. 3.0.21
  24. ======
  25. :release-date: 2013-07-05 16:30 P.M BST
  26. - Now depends on :mod:`billiard` 2.7.3.31.
  27. This version fixed a bug when running without the billiard C extension.
  28. - 3.0.20 broke eventlet/gevent support (worker not starting).
  29. - Fixed memory leak problem when MongoDB result backend was used with the
  30. gevent pool.
  31. Fix contributed by Ross Lawley.
  32. .. _version-3.0.20:
  33. 3.0.20
  34. ======
  35. :release-date: 2013-06-26 16:00 P.M BST
  36. - Now depends on :ref:`Kombu 2.5.11 <kombu:version-2.5.11>`.
  37. - ``--loader`` argument no longer supported importing loaders from the
  38. current directory.
  39. - [Worker] Fixed memory leak when restarting after connection lost
  40. (Issue #1325).
  41. - [Worker] Fixed unicode decode error at startup (Issue #1373).
  42. Fix contributed by Jessica Tallon.
  43. - [Worker] Now properly rewrites unpickleable exceptions again.
  44. - Fixed possible race condition when evicting items from the revoked task set.
  45. - [generic-init.d] Fixed compatibility with Ubuntu's minimal Dash
  46. shell (Issue #1387).
  47. Fix contributed by monkut.
  48. - ``Task.apply``/``ALWAYS_EAGER`` now also executes callbacks and errbacks
  49. (Issue #1336).
  50. - [Worker] The :signal:`worker-shutdown` signal was no longer being dispatched
  51. (Issue #1339).
  52. - [Python 3] Fixed problem with threading.Event.
  53. Fix contributed by Xavier Ordoquy.
  54. - [Python 3] Now handles ``io.UnsupportedOperation`` that may be raised
  55. by ``file.fileno()`` in Python 3.
  56. - [MongoDB backend] No longer uses deprecated ``safe`` parameter.
  57. Fix contributed by rfkrocktk
  58. - [Canvas] Fixed regression where immutable chord members may receive
  59. arguments (Issue #1340).
  60. Fix contributed by Peter Brook.
  61. - [Canvas] chain now accepts generator argument again (Issue #1319).
  62. - ``celery.migrate`` command now consumes from all queues if no queues
  63. specified.
  64. Fix contributed by John Watson.
  65. .. _version-3.0.19:
  66. 3.0.19
  67. ======
  68. :release-date: 2013-04-17 04:30:00 P.M BST
  69. - Now depends on :mod:`billiard` 2.7.3.28
  70. - A Python 3 related fix managed to disable the deadlock fix
  71. announced in 3.0.18.
  72. Tests have been added to make sure this does not happen again.
  73. - Task retry policy: Default max_retries is now 3.
  74. This ensures clients will not be hanging while the broker is down.
  75. .. note::
  76. You can set a longer retry for the worker by
  77. using the :signal:`celeryd_after_setup` signal:
  78. .. code-block:: python
  79. from celery.signals import celeryd_after_setup
  80. @celeryd_after_setup.connect
  81. def configure_worker(instance, conf, **kwargs):
  82. conf.CELERY_TASK_PUBLISH_RETRY_POLICY = {
  83. 'max_retries': 100,
  84. 'interval_start': 0,
  85. 'interval_max': 1,
  86. 'interval_step': 0.2,
  87. }
  88. - Worker: Will now properly display message body in error messages
  89. even if the body is a buffer instance.
  90. - 3.0.18 broke the MongoDB result backend (Issue #1303).
  91. .. _version-3.0.18:
  92. 3.0.18
  93. ======
  94. :release-date: 2013-04-12 05:00:00 P.M BST
  95. - Now depends on :mod:`kombu` 2.5.10.
  96. See the :ref:`kombu changelog <kombu:version-2.5.10>`.
  97. - Now depends on :mod:`billiard` 2.7.3.26.
  98. - Can now specify a whitelist of accepted serializers using
  99. the new :setting:`CELERY_ACCEPT_CONTENT` setting.
  100. This means that you can force the worker to discard messages
  101. serialized with pickle and other untrusted serializers.
  102. For example to only allow JSON serialized messages use::
  103. CELERY_ACCEPT_CONTENT = ['json']
  104. you can also specify MIME types in the whitelist::
  105. CELERY_ACCEPT_CONTENT = ['application/json']
  106. - Fixed deadlock in multiprocessing's pool caused by the
  107. semaphore not being released when terminated by signal.
  108. - Processes Pool: It's now possible to debug pool processes using GDB.
  109. - ``celery report`` now censors possibly secret settings, like passwords
  110. and secret tokens.
  111. You should still check the output before pasting anything
  112. on the internet.
  113. - Connection URLs now ignore multiple '+' tokens.
  114. - Worker/statedb: Now uses pickle protocol 2 (Py2.5+)
  115. - Fixed Python 3 compatibility issues.
  116. - Worker: A warning is now given if a worker is started with the
  117. same node name as an existing worker.
  118. - Worker: Fixed a deadlock that could occur while revoking tasks (Issue #1297).
  119. - Worker: The :sig:`HUP` handler now closes all open file descriptors
  120. before restarting to ensure file descriptors does not leak (Issue #1270).
  121. - Worker: Optimized storing/loading the revoked tasks list (Issue #1289).
  122. After this change the ``--statedb`` file will take up more disk space,
  123. but loading from and storing the revoked tasks will be considerably
  124. faster (what before took 5 minutes will now take less than a second).
  125. - Celery will now suggest alternatives if there's a typo in the
  126. broker transport name (e.g. ``ampq`` -> ``amqp``).
  127. - Worker: The auto-reloader would cause a crash if a monitored file
  128. was unlinked.
  129. Fix contributed by Agris Ameriks.
  130. - Fixed AsyncResult pickling error.
  131. Fix contributed by Thomas Minor.
  132. - Fixed handling of Unicode in logging output when using log colors
  133. (Issue #427).
  134. - :class:`~celery.app.utils.ConfigurationView` is now a ``MutableMapping``.
  135. Contributed by Aaron Harnly.
  136. - Fixed memory leak in LRU cache implementation.
  137. Fix contributed by Romuald Brunet.
  138. - ``celery.contrib.rdb``: Now works when sockets are in non-blocking mode.
  139. Fix contributed by Theo Spears.
  140. - The `inspect reserved` remote control command included active (started) tasks
  141. with the reserved tasks (Issue #1030).
  142. - The :signal:`task_failure` signal received a modified traceback object
  143. meant for pickling purposes, this has been fixed so that it now
  144. receives the real traceback instead.
  145. - The ``@task`` decorator silently ignored positional arguments,
  146. it now raises the expected :exc:`TypeError` instead (Issue #1125).
  147. - The worker will now properly handle messages with invalid
  148. eta/expires fields (Issue #1232).
  149. - The ``pool_restart`` remote control command now reports
  150. an error if the :setting:`CELERYD_POOL_RESTARTS` setting is not set.
  151. - ``celery.conf.add_defaults`` can now be used with non-dict objects.
  152. - Fixed compatibility problems in the Proxy class (Issue #1087).
  153. The class attributes ``__module__``, ``__name__`` and ``__doc__``
  154. are now meaningful string objects.
  155. Thanks to Marius Gedminas.
  156. - MongoDB Backend: The :setting:`MONGODB_BACKEND_SETTINGS` setting
  157. now accepts a ``option`` key that lets you forward arbitrary kwargs
  158. to the underlying ``pymongo.Connection`` object (Issue #1015).
  159. - Beat: The daily backend cleanup task is no longer enabled
  160. for result backends that support automatic result expiration (Issue #1031).
  161. - Canvas list operations now takes application instance from the first
  162. task in the list, instead of depending on the ``current_app`` (Issue #1249).
  163. - Worker: Message decoding error log message now includes traceback
  164. information.
  165. - Worker: The startup banner now includes system platform.
  166. - ``celery inspect|status|control`` now gives an error if used
  167. with an SQL based broker transport.
  168. .. _version-3.0.17:
  169. 3.0.17
  170. ======
  171. :release-date: 2013-03-22 04:00:00 P.M UTC
  172. - Now depends on kombu 2.5.8
  173. - Now depends on billiard 2.7.3.23
  174. - RabbitMQ/Redis: thread-less and lock-free rate-limit implementation.
  175. This means that rate limits pose minimal overhead when used with
  176. RabbitMQ/Redis or future transports using the eventloop,
  177. and that the rate-limit implementation is now thread-less and lock-free.
  178. The thread-based transports will still use the old implementation for
  179. now, but the plan is to use the timer also for other
  180. broker transports in Celery 3.1.
  181. - Rate limits now works with eventlet/gevent if using RabbitMQ/Redis as the
  182. broker.
  183. - A regression caused ``task.retry`` to ignore additional keyword arguments.
  184. Extra keyword arguments are now used as execution options again.
  185. Fix contributed by Simon Engledew.
  186. - Windows: Fixed problem with the worker trying to pickle the Django settings
  187. module at worker startup.
  188. - generic-init.d: No longer double quotes ``$CELERYD_CHDIR`` (Issue #1235).
  189. - generic-init.d: Removes bash-specific syntax.
  190. Fix contributed by Pär Wieslander.
  191. - Cassandra Result Backend: Now handles the
  192. :exc:`~pycassa.AllServersUnavailable` error (Issue #1010).
  193. Fix contributed by Jared Biel.
  194. - Result: Now properly forwards apps to GroupResults when deserializing
  195. (Issue #1249).
  196. Fix contributed by Charles-Axel Dein.
  197. - ``GroupResult.revoke`` now supports the ``terminate`` and ``signal``
  198. keyword arguments.
  199. - Worker: Multiprocessing pool workers now import task modules/configuration
  200. before setting up the logging system so that logging signals can be
  201. connected before they're dispatched.
  202. - chord: The ``AsyncResult`` instance returned now has its ``parent``
  203. attribute set to the header ``GroupResult``.
  204. This is consistent with how ``chain`` works.
  205. .. _version-3.0.16:
  206. 3.0.16
  207. ======
  208. :release-date: 2013-03-07 04:00:00 P.M UTC
  209. - Happy International Women's Day!
  210. We have a long way to go, so this is a chance for you to get involved in one
  211. of the organizations working for making our communities more
  212. diverse.
  213. - PyLadies — http://pyladies.com
  214. - Girls Who Code — http://www.girlswhocode.com
  215. - Women Who Code — http://www.meetup.com/Women-Who-Code-SF/
  216. - Now depends on :mod:`kombu` version 2.5.7
  217. - Now depends on :mod:`billiard` version 2.7.3.22
  218. - AMQP heartbeats are now disabled by default.
  219. Some users experiences issues with heartbeats enabled,
  220. and it's not strictly necessary to use them.
  221. If you're experiencing problems detecting connection failures,
  222. you can re-enable heartbeats by configuring the :setting:`BROKER_HEARTBEAT`
  223. setting.
  224. - Worker: Now propagates connection errors occurring in multiprocessing
  225. callbacks, so that the connection can be reset (Issue #1226).
  226. - Worker: Now propagates connection errors occurring in timer callbacks,
  227. so that the connection can be reset.
  228. - The modules in :setting:`CELERY_IMPORTS` and :setting:`CELERY_INCLUDE`
  229. are now imported in the original order (Issue #1161).
  230. The modules in :setting:`CELERY_IMPORTS` will be imported first,
  231. then continued by :setting:`CELERY_INCLUDE`.
  232. Thanks to Joey Wilhelm.
  233. - New bash completion for ``celery`` available in the git repository:
  234. https://github.com/celery/celery/tree/3.0/extra/bash-completion
  235. You can source this file or put it in ``bash_completion.d`` to
  236. get auto-completion for the ``celery`` command-line utility.
  237. - The node name of a worker can now include unicode characters (Issue #1186).
  238. - The repr of a ``crontab`` object now displays correctly (Issue #972).
  239. - ``events.State`` no longer modifies the original event dictionary.
  240. - No longer uses ``Logger.warn`` deprecated in Python 3.
  241. - Cache Backend: Now works with chords again (Issue #1094).
  242. - Chord unlock now handles errors occurring while calling the callback.
  243. - Generic worker init.d script: Status check is now performed by
  244. querying the pid of the instance instead of sending messages.
  245. Contributed by Milen Pavlov.
  246. - Improved init scripts for CentOS.
  247. - Updated to support celery 3.x conventions.
  248. - Now uses CentOS built-in ``status`` and ``killproc``
  249. - Support for multi-node / multi-pid worker services.
  250. - Standard color-coded CentOS service-init output.
  251. - A test suite.
  252. Contributed by Milen Pavlov.
  253. - ``ResultSet.join`` now always works with empty result set (Issue #1219).
  254. - A ``group`` consisting of a single task is now supported (Issue #1219).
  255. - Now supports the ``pycallgraph`` program (Issue #1051).
  256. - Fixed Jython compatibility problems.
  257. - Django tutorial: Now mentions that the example app must be added to
  258. ``INSTALLED_APPS`` (Issue #1192).
  259. .. _version-3.0.15:
  260. 3.0.15
  261. ======
  262. :release-date: 2013-02-11 04:30:00 P.M UTC
  263. - Now depends on billiard 2.7.3.21 which fixed a syntax error crash.
  264. - Fixed bug with :setting:`CELERY_SEND_TASK_SENT_EVENT`.
  265. .. _version-3.0.14:
  266. 3.0.14
  267. ======
  268. :release-date: 2013-02-08 05:00:00 P.M UTC
  269. - Now depends on Kombu 2.5.6
  270. - Now depends on billiard 2.7.3.20
  271. - ``execv`` is now disabled by default.
  272. It was causing too many problems for users, you can still enable
  273. it using the :setting:`CELERYD_FORCE_EXECV` setting.
  274. execv was only enabled when transports other than amqp/redis was used,
  275. and it's there to prevent deadlocks caused by mutexes not being released
  276. before the process forks. Sadly it also changes the environment
  277. introducing many corner case bugs that is hard to fix without adding
  278. horrible hacks. Deadlock issues are reported far less often than the
  279. bugs that execv are causing, so we now disable it by default.
  280. Work is in motion to create non-blocking versions of these transports
  281. so that execv is not necessary (which is the situation with the amqp
  282. and redis broker transports)
  283. - Chord exception behavior defined (Issue #1172).
  284. From Celery 3.1 the chord callback will change state to FAILURE
  285. when a task part of a chord raises an exception.
  286. It was never documented what happens in this case,
  287. and the actual behavior was very unsatisfactory, indeed
  288. it will just forward the exception value to the chord callback.
  289. For backward compatibility reasons we do not change to the new
  290. behavior in a bugfix release, even if the current behavior was
  291. never documented. Instead you can enable the
  292. :setting:`CELERY_CHORD_PROPAGATES` setting to get the new behavior
  293. that will be default from Celery 3.1.
  294. See more at :ref:`chord-errors`.
  295. - worker: Fixes bug with ignored and retried tasks.
  296. The ``on_chord_part_return`` and ``Task.after_return`` callbacks,
  297. nor the ``task_postrun`` signal should be called when the task was
  298. retried/ignored.
  299. Fix contributed by Vlad.
  300. - ``GroupResult.join_native`` now respects the ``propagate`` argument.
  301. - ``subtask.id`` added as an alias to ``subtask['options'].id``
  302. .. code-block:: python
  303. >>> s = add.s(2, 2)
  304. >>> s.id = 'my-id'
  305. >>> s['options']
  306. {'task_id': 'my-id'}
  307. >>> s.id
  308. 'my-id'
  309. - worker: Fixed error `Could not start worker processes` occurring
  310. when restarting after connection failure (Issue #1118).
  311. - Adds new signal :signal:`task-retried` (Issue #1169).
  312. - `celery events --dumper` now handles connection loss.
  313. - Will now retry sending the task-sent event in case of connection failure.
  314. - amqp backend: Now uses ``Message.requeue`` instead of republishing
  315. the message after poll.
  316. - New :setting:`BROKER_HEARTBEAT_CHECKRATE` setting introduced to modify the
  317. rate at which broker connection heartbeats are monitored.
  318. The default value was also changed from 3.0 to 2.0.
  319. - :class:`celery.events.state.State` is now pickleable.
  320. Fix contributed by Mher Movsisyan.
  321. - :class:`celery.datastructures.LRUCache` is now pickleable.
  322. Fix contributed by Mher Movsisyan.
  323. - The stats broadcast command now includes the workers pid.
  324. Contributed by Mher Movsisyan.
  325. - New ``conf`` remote control command to get a workers current configuration.
  326. Contributed by Mher Movsisyan.
  327. - Adds the ability to modify the chord unlock task's countdown
  328. argument (Issue #1146).
  329. Contributed by Jun Sakai
  330. - beat: The scheduler now uses the `now()`` method of the schedule,
  331. so that schedules can provide a custom way to get the current date and time.
  332. Contributed by Raphaël Slinckx
  333. - Fixed pickling of configuration modules on Windows or when execv is used
  334. (Issue #1126).
  335. - Multiprocessing logger is now configured with loglevel ``ERROR``
  336. by default.
  337. Since 3.0 the multiprocessing loggers were disabled by default
  338. (only configured when the :envvar:`MP_LOG` environment variable was set).
  339. .. _version-3.0.13:
  340. 3.0.13
  341. ======
  342. :release-date: 2013-01-07 04:00:00 P.M UTC
  343. - Now depends on Kombu 2.5
  344. - py-amqp has replaced amqplib as the default transport,
  345. gaining support for AMQP 0.9, and the RabbitMQ extensions
  346. including Consumer Cancel Notifications and heartbeats.
  347. - support for multiple connection URLs for failover.
  348. - Read more in the `Kombu 2.5 changelog`_.
  349. .. _`Kombu 2.5 changelog`:
  350. http://kombu.readthedocs.org/en/latest/changelog.html#version-2-5-0
  351. - Now depends on billiard 2.7.3.19
  352. - Fixed a deadlock issue that could occur when the producer pool
  353. inherited the connection pool instance of the parent process.
  354. - The :option:`--loader` option now works again (Issue #1066).
  355. - :program:`celery` umbrella command: All subcommands now supports
  356. the :option:`--workdir` option (Issue #1063).
  357. - Groups included in chains now give GroupResults (Issue #1057)
  358. Previously it would incorrectly add a regular result instead of a group
  359. result, but now this works:
  360. .. code-block:: python
  361. # [4 + 4, 4 + 8, 16 + 8]
  362. >>> res = (add.s(2, 2) | group(add.s(4), add.s(8), add.s(16)))()
  363. >>> res
  364. <GroupResult: a0acf905-c704-499e-b03a-8d445e6398f7 [
  365. 4346501c-cb99-4ad8-8577-12256c7a22b1,
  366. b12ead10-a622-4d44-86e9-3193a778f345,
  367. 26c7a420-11f3-4b33-8fac-66cd3b62abfd]>
  368. - Chains can now chain other chains and use partial arguments (Issue #1057).
  369. Example:
  370. .. code-block:: python
  371. >>> c1 = (add.s(2) | add.s(4))
  372. >>> c2 = (add.s(8) | add.s(16))
  373. >>> c3 = (c1 | c2)
  374. # 8 + 2 + 4 + 8 + 16
  375. >>> assert c3(8).get() == 38
  376. - Subtasks can now be used with unregistered tasks.
  377. You can specify subtasks even if you just have the name::
  378. >>> s = subtask(task_name, args=(), kwargs=())
  379. >>> s.delay()
  380. - The :program:`celery shell` command now always adds the current
  381. directory to the module path.
  382. - The worker will now properly handle the :exc:`pytz.AmbiguousTimeError`
  383. exception raised when an ETA/countdown is prepared while being in DST
  384. transition (Issue #1061).
  385. - force_execv: Now makes sure that task symbols in the original
  386. task modules will always use the correct app instance (Issue #1072).
  387. - AMQP Backend: Now republishes result messages that have been polled
  388. (using ``result.ready()`` and friends, ``result.get()`` will not do this
  389. in this version).
  390. - Crontab schedule values can now "wrap around"
  391. This means that values like ``11-1`` translates to ``[11, 12, 1]``.
  392. Contributed by Loren Abrams.
  393. - multi stopwait command now shows the pid of processes.
  394. Contributed by Loren Abrams.
  395. - Handling of ETA/countdown fixed when the :setting:`CELERY_ENABLE_UTC`
  396. setting is disabled (Issue #1065).
  397. - A number of uneeded properties were included in messages,
  398. caused by accidentally passing ``Queue.as_dict`` as message properties.
  399. - Rate limit values can now be float
  400. This also extends the string format so that values like ``"0.5/s"`` works.
  401. Contributed by Christoph Krybus
  402. - Fixed a typo in the broadcast routing documentation (Issue #1026).
  403. - Rewrote confusing section about idempotence in the task user guide.
  404. - Fixed typo in the daemonization tutorial (Issue #1055).
  405. - Fixed several typos in the documentation.
  406. Contributed by Marius Gedminas.
  407. - Batches: Now works when using the eventlet pool.
  408. Fix contributed by Thomas Grainger.
  409. - Batches: Added example sending results to :mod:`celery.contrib.batches`.
  410. Contributed by Thomas Grainger.
  411. - Mongodb backend: Connection ``max_pool_size`` can now be set in
  412. :setting:`CELERY_MONGODB_BACKEND_SETTINGS`.
  413. Contributed by Craig Younkins.
  414. - Fixed problem when using earlier versions of :mod:`pytz`.
  415. Fix contributed by Vlad.
  416. - Docs updated to include the default value for the
  417. :setting:`CELERY_TASK_RESULT_EXPIRES` setting.
  418. - Improvements to the django-celery tutorial.
  419. Contributed by Locker537.
  420. - The ``add_consumer`` control command did not properly persist
  421. the addition of new queues so that they survived connection failure
  422. (Issue #1079).
  423. 3.0.12
  424. ======
  425. :release-date: 2012-11-06 02:00 P.M UTC
  426. - Now depends on kombu 2.4.8
  427. - [Redis] New and improved fair queue cycle algorithm (Kevin McCarthy).
  428. - [Redis] Now uses a Redis-based mutex when restoring messages.
  429. - [Redis] Number of messages that can be restored in one interval is no
  430. longer limited (but can be set using the
  431. ``unacked_restore_limit``
  432. :setting:`transport option <BROKER_TRANSPORT_OPTIONS>`.)
  433. - Heartbeat value can be specified in broker URLs (Mher Movsisyan).
  434. - Fixed problem with msgpack on Python 3 (Jasper Bryant-Greene).
  435. - Now depends on billiard 2.7.3.18
  436. - Celery can now be used with static analysis tools like PyDev/PyCharm/pylint
  437. etc.
  438. - Development documentation has moved to Read The Docs.
  439. The new URL is: http://docs.celeryproject.org/en/master
  440. - New :setting:`CELERY_QUEUE_HA_POLICY` setting used to set the default
  441. HA policy for queues when using RabbitMQ.
  442. - New method ``Task.subtask_from_request`` returns a subtask using the current
  443. request.
  444. - Results get_many method did not respect timeout argument.
  445. Fix contributed by Remigiusz Modrzejewski
  446. - generic_init.d scripts now support setting :envvar:`CELERY_CREATE_DIRS` to
  447. always create log and pid directories (Issue #1045).
  448. This can be set in your :file:`/etc/default/celeryd`.
  449. - Fixed strange kombu import problem on Python 3.2 (Issue #1034).
  450. - Worker: ETA scheduler now uses millisecond precision (Issue #1040).
  451. - The ``--config`` argument to programs is now supported by all loaders.
  452. - The :setting:`CASSANDRA_OPTIONS` setting has now been documented.
  453. Contributed by Jared Biel.
  454. - Task methods (:mod:`celery.contrib.methods`) cannot be used with the old
  455. task base class, the task decorator in that module now inherits from the new.
  456. - An optimization was too eager and caused some logging messages to never emit.
  457. - :mod:`celery.contrib.batches` now works again.
  458. - Fixed missing whitespace in ``bdist_rpm`` requirements (Issue #1046).
  459. - Event state's ``tasks_by_name`` applied limit before filtering by name.
  460. Fix contributed by Alexander A. Sosnovskiy.
  461. .. _version-3.0.11:
  462. 3.0.11
  463. ======
  464. :release-date: 2012-09-26 04:00 P.M UTC
  465. - [security:low] generic-init.d scripts changed permissions of /var/log & /var/run
  466. In the daemonization tutorial the recommended directories were as follows:
  467. .. code-block:: bash
  468. CELERYD_LOG_FILE="/var/log/celery/%n.log"
  469. CELERYD_PID_FILE="/var/run/celery/%n.pid"
  470. But in the scripts themselves the default files were ``/var/log/celery%n.log``
  471. and ``/var/run/celery%n.pid``, so if the user did not change the location
  472. by configuration, the directories ``/var/log`` and ``/var/run`` would be
  473. created - and worse have their permissions and owners changed.
  474. This change means that:
  475. - Default pid file is ``/var/run/celery/%n.pid``
  476. - Default log file is ``/var/log/celery/%n.log``
  477. - The directories are only created and have their permissions
  478. changed if *no custom locations are set*.
  479. Users can force paths to be created by calling the ``create-paths``
  480. subcommand:
  481. .. code-block:: bash
  482. $ sudo /etc/init.d/celeryd create-paths
  483. .. admonition:: Upgrading Celery will not update init scripts
  484. To update the init scripts you have to re-download
  485. the files from source control and update them manually.
  486. You can find the init scripts for version 3.0.x at:
  487. http://github.com/celery/celery/tree/3.0/extra/generic-init.d
  488. - Now depends on billiard 2.7.3.17
  489. - Fixes request stack protection when app is initialized more than
  490. once (Issue #1003).
  491. - ETA tasks now properly works when system timezone is not the same
  492. as the configured timezone (Issue #1004).
  493. - Terminating a task now works if the task has been sent to the
  494. pool but not yet acknowledged by a pool process (Issue #1007).
  495. Fix contributed by Alexey Zatelepin
  496. - Terminating a task now properly updates the state of the task to revoked,
  497. and sends a ``task-revoked`` event.
  498. - Generic worker init script now waits for workers to shutdown by default.
  499. - Multi: No longer parses --app option (Issue #1008).
  500. - Multi: stop_verify command renamed to stopwait.
  501. - Daemonization: Now delays trying to create pidfile/logfile until after
  502. the working directory has been changed into.
  503. - :program:`celery worker` and :program:`celery beat` commands now respects
  504. the :option:`--no-color` option (Issue #999).
  505. - Fixed typos in eventlet examples (Issue #1000)
  506. Fix contributed by Bryan Bishop.
  507. Congratulations on opening bug #1000!
  508. - Tasks that raise :exc:`~celery.exceptions.Ignore` are now acknowledged.
  509. - Beat: Now shows the name of the entry in ``sending due task`` logs.
  510. .. _version-3.0.10:
  511. 3.0.10
  512. ======
  513. :release-date: 2012-09-20 05:30 P.M BST
  514. - Now depends on kombu 2.4.7
  515. - Now depends on billiard 2.7.3.14
  516. - Fixes crash at startup when using Django and pre-1.4 projects
  517. (setup_environ).
  518. - Hard time limits now sends the KILL signal shortly after TERM,
  519. to terminate processes that have signal handlers blocked by C extensions.
  520. - Billiard now installs even if the C extension cannot be built.
  521. It's still recommended to build the C extension if you are using
  522. a transport other than rabbitmq/redis (or use forced execv for some
  523. other reason).
  524. - Pool now sets a ``current_process().index`` attribute that can be used to create
  525. as many log files as there are processes in the pool.
  526. - Canvas: chord/group/chain no longer modifies the state when called
  527. Previously calling a chord/group/chain would modify the ids of subtasks
  528. so that:
  529. .. code-block:: python
  530. >>> c = chord([add.s(2, 2), add.s(4, 4)], xsum.s())
  531. >>> c()
  532. >>> c() <-- call again
  533. at the second time the ids for the tasks would be the same as in the
  534. previous invocation. This is now fixed, so that calling a subtask
  535. won't mutate any options.
  536. - Canvas: Chaining a chord to another task now works (Issue #965).
  537. - Worker: Fixed a bug where the request stack could be corrupted if
  538. relative imports are used.
  539. Problem usually manifested itself as an exception while trying to
  540. send a failed task result (``NoneType does not have id attribute``).
  541. Fix contributed by Sam Cooke.
  542. - Tasks can now raise :exc:`~celery.exceptions.Ignore` to skip updating states
  543. or events after return.
  544. Example:
  545. .. code-block:: python
  546. from celery.exceptions import Ignore
  547. @task
  548. def custom_revokes():
  549. if redis.sismember('tasks.revoked', custom_revokes.request.id):
  550. raise Ignore()
  551. - The worker now makes sure the request/task stacks are not modified
  552. by the initial ``Task.__call__``.
  553. This would previously be a problem if a custom task class defined
  554. ``__call__`` and also called ``super()``.
  555. - Because of problems the fast local optimization has been disabled,
  556. and can only be enabled by setting the :envvar:`USE_FAST_LOCALS` attribute.
  557. - Worker: Now sets a default socket timeout of 5 seconds at shutdown
  558. so that broken socket reads do not hinder proper shutdown (Issue #975).
  559. - More fixes related to late eventlet/gevent patching.
  560. - Documentation for settings out of sync with reality:
  561. - :setting:`CELERY_TASK_PUBLISH_RETRY`
  562. Documented as disabled by default, but it was enabled by default
  563. since 2.5 as stated by the 2.5 changelog.
  564. - :setting:`CELERY_TASK_PUBLISH_RETRY_POLICY`
  565. The default max_retries had been set to 100, but documented as being
  566. 3, and the interval_max was set to 1 but documented as 0.2.
  567. The default setting are now set to 3 and 0.2 as it was originally
  568. documented.
  569. Fix contributed by Matt Long.
  570. - Worker: Log messages when connection established and lost have been improved.
  571. - The repr of a crontab schedule value of '0' should be '*' (Issue #972).
  572. - Revoked tasks are now removed from reserved/active state in the worker
  573. (Issue #969)
  574. Fix contributed by Alexey Zatelepin.
  575. - gevent: Now supports hard time limits using ``gevent.Timeout``.
  576. - Documentation: Links to init scripts now point to the 3.0 branch instead
  577. of the development branch (master).
  578. - Documentation: Fixed typo in signals user guide (Issue #986).
  579. ``instance.app.queues`` -> ``instance.app.amqp.queues``.
  580. - Eventlet/gevent: The worker did not properly set the custom app
  581. for new greenlets.
  582. - Eventlet/gevent: Fixed a bug where the worker could not recover
  583. from connection loss (Issue #959).
  584. Also, because of a suspected bug in gevent the
  585. :setting:`BROKER_CONNECTION_TIMEOUT` setting has been disabled
  586. when using gevent
  587. 3.0.9
  588. =====
  589. :release-date: 2012-08-31 06:00 P.M BST
  590. - Important note for users of Django and the database scheduler!
  591. Recently a timezone issue has been fixed for periodic tasks,
  592. but erroneous timezones could have already been stored in the
  593. database, so for the fix to work you need to reset
  594. the ``last_run_at`` fields.
  595. You can do this by executing the following command:
  596. .. code-block:: bash
  597. $ python manage.py shell
  598. >>> from djcelery.models import PeriodicTask
  599. >>> PeriodicTask.objects.update(last_run_at=None)
  600. You also have to do this if you change the timezone or
  601. :setting:`CELERY_ENABLE_UTC` setting.
  602. - Note about the :setting:`CELERY_ENABLE_UTC` setting.
  603. If you previously disabled this just to force periodic tasks to work with
  604. your timezone, then you are now *encouraged to re-enable it*.
  605. - Now depends on Kombu 2.4.5 which fixes PyPy + Jython installation.
  606. - Fixed bug with timezones when :setting:`CELERY_ENABLE_UTC` is disabled
  607. (Issue #952).
  608. - Fixed a typo in the celerybeat upgrade mechanism (Issue #951).
  609. - Make sure the `exc_info` argument to logging is resolved (Issue #899).
  610. - Fixed problem with Python 3.2 and thread join timeout overflow (Issue #796).
  611. - A test case was occasionally broken for Python 2.5.
  612. - Unit test suite now passes for PyPy 1.9.
  613. - App instances now supports the with statement.
  614. This calls the new :meth:`~celery.Celery.close` method at exit, which
  615. cleans up after the app like closing pool connections.
  616. Note that this is only necessary when dynamically creating apps,
  617. e.g. for "temporary" apps.
  618. - Support for piping a subtask to a chain.
  619. For example:
  620. .. code-block:: python
  621. pipe = sometask.s() | othertask.s()
  622. new_pipe = mytask.s() | pipe
  623. Contributed by Steve Morin.
  624. - Fixed problem with group results on non-pickle serializers.
  625. Fix contributed by Steeve Morin.
  626. .. _version-3.0.8:
  627. 3.0.8
  628. =====
  629. :release-date: 2012-08-29 05:00 P.M BST
  630. - Now depends on Kombu 2.4.4
  631. - Fixed problem with amqplib and receiving larger message payloads
  632. (Issue #922).
  633. The problem would manifest itself as either the worker hanging,
  634. or occasionally a ``Framing error`` exception appearing.
  635. Users of the new ``pyamqp://`` transport must upgrade to
  636. :mod:`amqp` 0.9.3.
  637. - Beat: Fixed another timezone bug with interval and crontab schedules
  638. (Issue #943).
  639. - Beat: The schedule file is now automatically cleared if the timezone
  640. is changed.
  641. The schedule is also cleared when you upgrade to 3.0.8 from an earlier
  642. version, this to register the initial timezone info.
  643. - Events: The :event:`worker-heartbeat` event now include processed and active
  644. count fields.
  645. Contributed by Mher Movsisyan.
  646. - Fixed error with error email and new task classes (Issue #931).
  647. - ``BaseTask.__call__`` is no longer optimized away if it has been monkey
  648. patched.
  649. - Fixed shutdown issue when using gevent (Issue #911 & Issue #936).
  650. Fix contributed by Thomas Meson.
  651. .. _version-3.0.7:
  652. 3.0.7
  653. =====
  654. :release-date: 2012-08-24 05:00 P.M BST
  655. - Fixes several problems with periodic tasks and timezones (Issue #937).
  656. - Now depends on kombu 2.4.2
  657. - Redis: Fixes a race condition crash
  658. - Fixes an infinite loop that could happen when retrying establishing
  659. the broker connection.
  660. - Daemons now redirect standard file descriptors to :file:`/dev/null`
  661. Though by default the standard outs are also redirected
  662. to the logger instead, but you can disable this by changing
  663. the :setting:`CELERY_REDIRECT_STDOUTS` setting.
  664. - Fixes possible problems when eventlet/gevent is patched too late.
  665. - ``LoggingProxy`` no longer defines ``fileno()`` (Issue #928).
  666. - Results are now ignored for the chord unlock task.
  667. Fix contributed by Steeve Morin.
  668. - Cassandra backend now works if result expiry is disabled.
  669. Fix contributed by Steeve Morin.
  670. - The traceback object is now passed to signal handlers instead
  671. of the string representation.
  672. Fix contributed by Adam DePue.
  673. - Celery command: Extensions are now sorted by name.
  674. - A regression caused the :event:`task-failed` event to be sent
  675. with the exception object instead of its string representation.
  676. - The worker daemon would try to create the pid file before daemonizing
  677. to catch errors, but this file was not immediately released (Issue #923).
  678. - Fixes Jython compatibility.
  679. - ``billiard.forking_enable`` was called by all pools not just the
  680. processes pool, which would result in a useless warning if the billiard
  681. C extensions were not installed.
  682. .. _version-3.0.6:
  683. 3.0.6
  684. =====
  685. :release-date: 2012-08-17 11:00 P.M BST
  686. - Now depends on kombu 2.4.0
  687. - Now depends on billiard 2.7.3.12
  688. - Redis: Celery now tries to restore messages whenever there are no messages
  689. in the queue.
  690. - Crontab schedules now properly respects :setting:`CELERY_TIMEZONE` setting.
  691. It's important to note that crontab schedules uses UTC time by default
  692. unless this setting is set.
  693. Issue #904 and django-celery #150.
  694. - ``billiard.enable_forking`` is now only set by the processes pool.
  695. - The transport is now properly shown by :program:`celery report`
  696. (Issue #913).
  697. - The `--app` argument now works if the last part is a module name
  698. (Issue #921).
  699. - Fixed problem with unpickleable exceptions (billiard #12).
  700. - Adds ``task_name`` attribute to ``EagerResult`` which is always
  701. :const:`None` (Issue #907).
  702. - Old Task class in :mod:`celery.task` no longer accepts magic kwargs by
  703. default (Issue #918).
  704. A regression long ago disabled magic kwargs for these, and since
  705. no one has complained about it we don't have any incentive to fix it now.
  706. - The ``inspect reserved`` control command did not work properly.
  707. - Should now play better with static analyzation tools by explicitly
  708. specifying dynamically created attributes in the :mod:`celery` and
  709. :mod:`celery.task` modules.
  710. - Terminating a task now results in
  711. :exc:`~celery.exceptions.RevokedTaskError` instead of a ``WorkerLostError``.
  712. - ``AsyncResult.revoke`` now accepts ``terminate`` and ``signal`` arguments.
  713. - The :event:`task-revoked` event now includes new fields: ``terminated``,
  714. ``signum``, and ``expired``.
  715. - The argument to :class:`~celery.exceptions.TaskRevokedError` is now one
  716. of the reasons ``revoked``, ``expired`` or ``terminated``.
  717. - Old Task class does no longer use classmethods for push_request and
  718. pop_request (Issue #912).
  719. - ``GroupResult`` now supports the ``children`` attribute (Issue #916).
  720. - ``AsyncResult.collect`` now respects the ``intermediate`` argument
  721. (Issue #917).
  722. - Fixes example task in documentation (Issue #902).
  723. - Eventlet fixed so that the environment is patched as soon as possible.
  724. - eventlet: Now warns if celery related modules that depends on threads
  725. are imported before eventlet is patched.
  726. - Improved event and camera examples in the monitoring guide.
  727. - Disables celery command setuptools entrypoints if the command can't be
  728. loaded.
  729. - Fixed broken ``dump_request`` example in the tasks guide.
  730. .. _version-3.0.5:
  731. 3.0.5
  732. =====
  733. :release-date: 2012-08-01 04:00 P.M BST
  734. - Now depends on kombu 2.3.1 + billiard 2.7.3.11
  735. - Fixed a bug with the -B option (``cannot pickle thread.lock objects``)
  736. (Issue #894 + Issue #892, + django-celery #154).
  737. - The :control:`restart_pool` control command now requires the
  738. :setting:`CELERYD_POOL_RESTARTS` setting to be enabled
  739. This change was necessary as the multiprocessing event that the restart
  740. command depends on is responsible for creating many semaphores/file
  741. descriptors, resulting in problems in some environments.
  742. - ``chain.apply`` now passes args to the first task (Issue #889).
  743. - Documented previously secret options to the Django-Celery monitor
  744. in the monitoring userguide (Issue #396).
  745. - Old changelog are now organized in separate documents for each series,
  746. see :ref:`history`.
  747. .. _version-3.0.4:
  748. 3.0.4
  749. =====
  750. :release-date: 2012-07-26 07:00 P.M BST
  751. - Now depends on Kombu 2.3
  752. - New experimental standalone Celery monitor: Flower
  753. See :ref:`monitoring-flower` to read more about it!
  754. Contributed by Mher Movsisyan.
  755. - Now supports AMQP heartbeats if using the new ``pyamqp://`` transport.
  756. - The py-amqp transport requires the :mod:`amqp` library to be installed::
  757. $ pip install amqp
  758. - Then you need to set the transport URL prefix to ``pyamqp://``.
  759. - The default heartbeat value is 10 seconds, but this can be changed using
  760. the :setting:`BROKER_HEARTBEAT` setting::
  761. BROKER_HEARTBEAT = 5.0
  762. - If the broker heartbeat is set to 10 seconds, the heartbeats will be
  763. monitored every 5 seconds (double the hertbeat rate).
  764. See the `Kombu 2.3 changelog`_ for more information.
  765. .. _`Kombu 2.3 changelog`:
  766. http://kombu.readthedocs.org/en/latest/changelog.html#version-2-3-0
  767. - Now supports RabbitMQ Consumer Cancel Notifications, using the ``pyamqp://``
  768. transport.
  769. This is essential when running RabbitMQ in a cluster.
  770. See the `Kombu 2.3 changelog`_ for more information.
  771. - Delivery info is no longer passed directly through.
  772. It was discovered that the SQS transport adds objects that can't
  773. be pickled to the delivery info mapping, so we had to go back
  774. to using the whitelist again.
  775. Fixing this bug also means that the SQS transport is now working again.
  776. - The semaphore was not properly released when a task was revoked (Issue #877).
  777. This could lead to tasks being swallowed and not released until a worker
  778. restart.
  779. Thanks to Hynek Schlawack for debugging the issue.
  780. - Retrying a task now also forwards any linked tasks.
  781. This means that if a task is part of a chain (or linked in some other
  782. way) and that even if the task is retried, then the next task in the chain
  783. will be executed when the retry succeeds.
  784. - Chords: Now supports setting the interval and other keyword arguments
  785. to the chord unlock task.
  786. - The interval can now be set as part of the chord subtasks kwargs::
  787. chord(header)(body, interval=10.0)
  788. - In addition the chord unlock task now honors the Task.default_retry_delay
  789. option, used when none is specified, which also means that the default
  790. interval can also be changed using annotations:
  791. .. code-block:: python
  792. CELERY_ANNOTATIONS = {
  793. 'celery.chord_unlock': {
  794. 'default_retry_delay': 10.0,
  795. }
  796. }
  797. - New :meth:`@Celery.add_defaults` method can add new default configuration
  798. dicts to the applications configuration.
  799. For example::
  800. config = {'FOO': 10}
  801. celery.add_defaults(config)
  802. is the same as ``celery.conf.update(config)`` except that data will not be
  803. copied, and that it will not be pickled when the worker spawns child
  804. processes.
  805. In addition the method accepts a callable::
  806. def initialize_config():
  807. # insert heavy stuff that can't be done at import time here.
  808. celery.add_defaults(initialize_config)
  809. which means the same as the above except that it will not happen
  810. until the celery configuration is actually used.
  811. As an example, Celery can lazily use the configuration of a Flask app::
  812. flask_app = Flask()
  813. celery = Celery()
  814. celery.add_defaults(lambda: flask_app.config)
  815. - Revoked tasks were not marked as revoked in the result backend (Issue #871).
  816. Fix contributed by Hynek Schlawack.
  817. - Eventloop now properly handles the case when the epoll poller object
  818. has been closed (Issue #882).
  819. - Fixed syntax error in ``funtests/test_leak.py``
  820. Fix contributed by Catalin Iacob.
  821. - group/chunks: Now accepts empty task list (Issue #873).
  822. - New method names:
  823. - ``Celery.default_connection()`` ➠ :meth:`~@Celery.connection_or_acquire`.
  824. - ``Celery.default_producer()`` ➠ :meth:`~@Celery.producer_or_acquire`.
  825. The old names still work for backward compatibility.
  826. .. _version-3.0.3:
  827. 3.0.3
  828. =====
  829. :release-date: 2012-07-20 09:17 P.M BST
  830. :by: Ask Solem
  831. - amqplib passes the channel object as part of the delivery_info
  832. and it's not pickleable, so we now remove it.
  833. .. _version-3.0.2:
  834. 3.0.2
  835. =====
  836. :release-date: 2012-07-20 04:00 P.M BST
  837. :by: Ask Solem
  838. - A bug caused the following task options to not take defaults from the
  839. configuration (Issue #867 + Issue #858)
  840. The following settings were affected:
  841. - :setting:`CELERY_IGNORE_RESULT`
  842. - :setting:`CELERYD_SEND_TASK_ERROR_EMAILS`
  843. - :setting:`CELERY_TRACK_STARTED`
  844. - :setting:`CElERY_STORE_ERRORS_EVEN_IF_IGNORED`
  845. Fix contributed by John Watson.
  846. - Task Request: ``delivery_info`` is now passed through as-is (Issue #807).
  847. - The eta argument now supports datetime's with a timezone set (Issue #855).
  848. - The worker's banner displayed the autoscale settings in the wrong order
  849. (Issue #859).
  850. - Extension commands are now loaded after concurrency is set up
  851. so that they don't interfere with e.g. eventlet patching.
  852. - Fixed bug in the threaded pool (Issue #863)
  853. - The task failure handler mixed up the fields in :func:`sys.exc_info`.
  854. Fix contributed by Rinat Shigapov.
  855. - Fixed typos and wording in the docs.
  856. Fix contributed by Paul McMillan
  857. - New setting: :setting:`CELERY_WORKER_DIRECT`
  858. If enabled each worker will consume from their own dedicated queue
  859. which can be used to route tasks to specific workers.
  860. - Fixed several edge case bugs in the add consumer remote control command.
  861. - :mod:`~celery.contrib.migrate`: Can now filter and move tasks to specific
  862. workers if :setting:`CELERY_WORKER_DIRECT` is enabled.
  863. Among other improvements, the following functions have been added:
  864. * ``move_direct(filterfun, **opts)``
  865. * ``move_direct_by_id(task_id, worker_hostname, **opts)``
  866. * ``move_direct_by_idmap({task_id: worker_hostname, ...}, **opts)``
  867. * ``move_direct_by_taskmap({task_name: worker_hostname, ...}, **opts)``
  868. - :meth:`~celery.Celery.default_connection` now accepts a pool argument that
  869. if set to false causes a new connection to be created instead of acquiring
  870. one from the pool.
  871. - New signal: :signal:`celeryd_after_setup`.
  872. - Default loader now keeps lowercase attributes from the configuration module.
  873. .. _version-3.0.1:
  874. 3.0.1
  875. =====
  876. :release-date: 2012-07-10 06:00 P.M BST
  877. :by: Ask Solem
  878. - Now depends on kombu 2.2.5
  879. - inspect now supports limit argument::
  880. myapp.control.inspect(limit=1).ping()
  881. - Beat: now works with timezone aware datetime's.
  882. - Task classes inheriting ``from celery import Task``
  883. mistakingly enabled ``accept_magic_kwargs``.
  884. - Fixed bug in ``inspect scheduled`` (Issue #829).
  885. - Beat: Now resets the schedule to upgrade to UTC.
  886. - The :program:`celery worker` command now works with eventlet/gevent.
  887. Previously it would not patch the environment early enough.
  888. - The :program:`celery` command now supports extension commands
  889. using setuptools entry-points.
  890. Libraries can add additional commands to the :program:`celery`
  891. command by adding an entry-point like::
  892. setup(
  893. entry_points=[
  894. 'celery.commands': [
  895. 'foo = my.module:Command',
  896. ],
  897. ],
  898. ...)
  899. The command must then support the interface of
  900. :class:`celery.bin.base.Command`.
  901. - contrib.migrate: New utilities to move tasks from one queue to another.
  902. - :func:`~celery.contrib.migrate.move_tasks`
  903. - :func:`~celery.contrib.migrate.move_task_by_id`
  904. - The :event:`task-sent` event now contains ``exchange`` and ``routing_key``
  905. fields.
  906. - Fixes bug with installing on Python 3.
  907. Fix contributed by Jed Smith.
  908. .. _version-3.0.0:
  909. 3.0.0 (Chiastic Slide)
  910. ======================
  911. :release-date: 2012-07-07 01:30 P.M BST
  912. :by: Ask Solem
  913. See :ref:`whatsnew-3.0`.
  914. >>>>>>> 3.0
  915. .. _version-3.0.17:
  916. 3.0.17
  917. ======
  918. :release-date: 2013-03-22 04:00:00 P.M UTC
  919. - Now depends on kombu 2.5.8
  920. - Now depends on billiard 2.7.3.23
  921. - RabbitMQ/Redis: thread-less and lock-free rate-limit implementation.
  922. This means that rate limits pose minimal overhead when used with
  923. RabbitMQ/Redis or future transports using the eventloop,
  924. and that the rate-limit implementation is now thread-less and lock-free.
  925. The thread-based transports will still use the old implementation for
  926. now, but the plan is to use the timer also for other
  927. broker transports in Celery 3.1.
  928. - Rate limits now works with eventlet/gevent if using RabbitMQ/Redis as the
  929. broker.
  930. - A regression caused ``task.retry`` to ignore additional keyword arguments.
  931. Extra keyword arguments are now used as execution options again.
  932. Fix contributed by Simon Engledew.
  933. - Windows: Fixed problem with the worker trying to pickle the Django settings
  934. module at worker startup.
  935. - generic-init.d: No longer double quotes ``$CELERYD_CHDIR`` (Issue #1235).
  936. - generic-init.d: Removes bash-specific syntax.
  937. Fix contributed by Pär Wieslander.
  938. - Cassandra Result Backend: Now handles the
  939. :exc:`~pycassa.AllServersUnavailable` error (Issue #1010).
  940. Fix contributed by Jared Biel.
  941. - Result: Now properly forwards apps to GroupResults when deserializing
  942. (Issue #1249).
  943. Fix contributed by Charles-Axel Dein.
  944. - ``GroupResult.revoke`` now supports the ``terminate`` and ``signal``
  945. keyword arguments.
  946. - Worker: Multiprocessing pool workers now import task modules/configuration
  947. before setting up the logging system so that logging signals can be
  948. connected before they're dispatched.
  949. - chord: The ``AsyncResult`` instance returned now has its ``parent``
  950. attribute set to the header ``GroupResult``.
  951. This is consistent with how ``chain`` works.
  952. .. _version-3.0.16:
  953. 3.0.16
  954. ======
  955. :release-date: 2013-03-07 04:00:00 P.M UTC
  956. - Happy International Women's Day!
  957. We have a long way to go, so this is a chance for you to get involved in one
  958. of the organizations working for making our communities more
  959. diverse.
  960. - PyLadies — http://pyladies.com
  961. - Girls Who Code — http://www.girlswhocode.com
  962. - Women Who Code — http://www.meetup.com/Women-Who-Code-SF/
  963. - Now depends on :mod:`kombu` version 2.5.7
  964. - Now depends on :mod:`billiard` version 2.7.3.22
  965. - AMQP heartbeats are now disabled by default.
  966. Some users experiences issues with heartbeats enabled,
  967. and it's not strictly necessary to use them.
  968. If you're experiencing problems detecting connection failures,
  969. you can re-enable heartbeats by configuring the :setting:`BROKER_HEARTBEAT`
  970. setting.
  971. - Worker: Now propagates connection errors occurring in multiprocessing
  972. callbacks, so that the connection can be reset (Issue #1226).
  973. - Worker: Now propagates connection errors occurring in timer callbacks,
  974. so that the connection can be reset.
  975. - The modules in :setting:`CELERY_IMPORTS` and :setting:`CELERY_INCLUDE`
  976. are now imported in the original order (Issue #1161).
  977. The modules in :setting:`CELERY_IMPORTS` will be imported first,
  978. then continued by :setting:`CELERY_INCLUDE`.
  979. Thanks to Joey Wilhelm.
  980. - New bash completion for ``celery`` available in the git repository:
  981. https://github.com/celery/celery/tree/3.0/extra/bash-completion
  982. You can source this file or put it in ``bash_completion.d`` to
  983. get auto-completion for the ``celery`` command-line utility.
  984. - The node name of a worker can now include unicode characters (Issue #1186).
  985. - The repr of a ``crontab`` object now displays correctly (Issue #972).
  986. - ``events.State`` no longer modifies the original event dictionary.
  987. - No longer uses ``Logger.warn`` deprecated in Python 3.
  988. - Cache Backend: Now works with chords again (Issue #1094).
  989. - Chord unlock now handles errors occurring while calling the callback.
  990. - Generic worker init.d script: Status check is now performed by
  991. querying the pid of the instance instead of sending messages.
  992. Contributed by Milen Pavlov.
  993. - Improved init scripts for CentOS.
  994. - Updated to support celery 3.x conventions.
  995. - Now uses CentOS built-in ``status`` and ``killproc``
  996. - Support for multi-node / multi-pid worker services.
  997. - Standard color-coded CentOS service-init output.
  998. - A test suite.
  999. Contributed by Milen Pavlov.
  1000. - ``ResultSet.join`` now always works with empty result set (Issue #1219).
  1001. - A ``group`` consisting of a single task is now supported (Issue #1219).
  1002. - Now supports the ``pycallgraph`` program (Issue #1051).
  1003. - Fixed Jython compatibility problems.
  1004. - Django tutorial: Now mentions that the example app must be added to
  1005. ``INSTALLED_APPS`` (Issue #1192).
  1006. .. _version-3.0.15:
  1007. 3.0.15
  1008. ======
  1009. :release-date: 2013-02-11 04:30:00 P.M UTC
  1010. - Now depends on billiard 2.7.3.21 which fixed a syntax error crash.
  1011. - Fixed bug with :setting:`CELERY_SEND_TASK_SENT_EVENT`.
  1012. .. _version-3.0.14:
  1013. 3.0.14
  1014. ======
  1015. :release-date: 2013-02-08 05:00:00 P.M UTC
  1016. - Now depends on Kombu 2.5.6
  1017. - Now depends on billiard 2.7.3.20
  1018. - ``execv`` is now disabled by default.
  1019. It was causing too many problems for users, you can still enable
  1020. it using the :setting:`CELERYD_FORCE_EXECV` setting.
  1021. execv was only enabled when transports other than amqp/redis was used,
  1022. and it's there to prevent deadlocks caused by mutexes not being released
  1023. before the process forks. Sadly it also changes the environment
  1024. introducing many corner case bugs that is hard to fix without adding
  1025. horrible hacks. Deadlock issues are reported far less often than the
  1026. bugs that execv are causing, so we now disable it by default.
  1027. Work is in motion to create non-blocking versions of these transports
  1028. so that execv is not necessary (which is the situation with the amqp
  1029. and redis broker transports)
  1030. - Chord exception behavior defined (Issue #1172).
  1031. From Celery 3.1 the chord callback will change state to FAILURE
  1032. when a task part of a chord raises an exception.
  1033. It was never documented what happens in this case,
  1034. and the actual behavior was very unsatisfactory, indeed
  1035. it will just forward the exception value to the chord callback.
  1036. For backward compatibility reasons we do not change to the new
  1037. behavior in a bugfix release, even if the current behavior was
  1038. never documented. Instead you can enable the
  1039. :setting:`CELERY_CHORD_PROPAGATES` setting to get the new behavior
  1040. that will be default from Celery 3.1.
  1041. See more at :ref:`chord-errors`.
  1042. - worker: Fixes bug with ignored and retried tasks.
  1043. The ``on_chord_part_return`` and ``Task.after_return`` callbacks,
  1044. nor the ``task_postrun`` signal should be called when the task was
  1045. retried/ignored.
  1046. Fix contributed by Vlad.
  1047. - ``GroupResult.join_native`` now respects the ``propagate`` argument.
  1048. - ``subtask.id`` added as an alias to ``subtask['options'].id``
  1049. .. code-block:: python
  1050. >>> s = add.s(2, 2)
  1051. >>> s.id = 'my-id'
  1052. >>> s['options']
  1053. {'task_id': 'my-id'}
  1054. >>> s.id
  1055. 'my-id'
  1056. - worker: Fixed error `Could not start worker processes` occurring
  1057. when restarting after connection failure (Issue #1118).
  1058. - Adds new signal :signal:`task-retried` (Issue #1169).
  1059. - `celery events --dumper` now handles connection loss.
  1060. - Will now retry sending the task-sent event in case of connection failure.
  1061. - amqp backend: Now uses ``Message.requeue`` instead of republishing
  1062. the message after poll.
  1063. - New :setting:`BROKER_HEARTBEAT_CHECKRATE` setting introduced to modify the
  1064. rate at which broker connection heartbeats are monitored.
  1065. The default value was also changed from 3.0 to 2.0.
  1066. - :class:`celery.events.state.State` is now pickleable.
  1067. Fix contributed by Mher Movsisyan.
  1068. - :class:`celery.datastructures.LRUCache` is now pickleable.
  1069. Fix contributed by Mher Movsisyan.
  1070. - The stats broadcast command now includes the workers pid.
  1071. Contributed by Mher Movsisyan.
  1072. - New ``conf`` remote control command to get a workers current configuration.
  1073. Contributed by Mher Movsisyan.
  1074. - Adds the ability to modify the chord unlock task's countdown
  1075. argument (Issue #1146).
  1076. Contributed by Jun Sakai
  1077. - beat: The scheduler now uses the `now()`` method of the schedule,
  1078. so that schedules can provide a custom way to get the current date and time.
  1079. Contributed by Raphaël Slinckx
  1080. - Fixed pickling of configuration modules on Windows or when execv is used
  1081. (Issue #1126).
  1082. - Multiprocessing logger is now configured with loglevel ``ERROR``
  1083. by default.
  1084. Since 3.0 the multiprocessing loggers were disabled by default
  1085. (only configured when the :envvar:`MP_LOG` environment variable was set).
  1086. .. _version-3.0.13:
  1087. 3.0.13
  1088. ======
  1089. :release-date: 2013-01-07 04:00:00 P.M UTC
  1090. - Now depends on Kombu 2.5
  1091. - py-amqp has replaced amqplib as the default transport,
  1092. gaining support for AMQP 0.9, and the RabbitMQ extensions
  1093. including Consumer Cancel Notifications and heartbeats.
  1094. - support for multiple connection URLs for failover.
  1095. - Read more in the `Kombu 2.5 changelog`_.
  1096. .. _`Kombu 2.5 changelog`:
  1097. http://kombu.readthedocs.org/en/latest/changelog.html#version-2-5-0
  1098. - Now depends on billiard 2.7.3.19
  1099. - Fixed a deadlock issue that could occur when the producer pool
  1100. inherited the connection pool instance of the parent process.
  1101. - The :option:`--loader` option now works again (Issue #1066).
  1102. - :program:`celery` umbrella command: All subcommands now supports
  1103. the :option:`--workdir` option (Issue #1063).
  1104. - Groups included in chains now give GroupResults (Issue #1057)
  1105. Previously it would incorrectly add a regular result instead of a group
  1106. result, but now this works:
  1107. .. code-block:: python
  1108. # [4 + 4, 4 + 8, 16 + 8]
  1109. >>> res = (add.s(2, 2) | group(add.s(4), add.s(8), add.s(16)))()
  1110. >>> res
  1111. <GroupResult: a0acf905-c704-499e-b03a-8d445e6398f7 [
  1112. 4346501c-cb99-4ad8-8577-12256c7a22b1,
  1113. b12ead10-a622-4d44-86e9-3193a778f345,
  1114. 26c7a420-11f3-4b33-8fac-66cd3b62abfd]>
  1115. - Chains can now chain other chains and use partial arguments (Issue #1057).
  1116. Example:
  1117. .. code-block:: python
  1118. >>> c1 = (add.s(2) | add.s(4))
  1119. >>> c2 = (add.s(8) | add.s(16))
  1120. >>> c3 = (c1 | c2)
  1121. # 8 + 2 + 4 + 8 + 16
  1122. >>> assert c3(8).get() == 38
  1123. - Subtasks can now be used with unregistered tasks.
  1124. You can specify subtasks even if you just have the name::
  1125. >>> s = subtask(task_name, args=(), kwargs=())
  1126. >>> s.delay()
  1127. - The :program:`celery shell` command now always adds the current
  1128. directory to the module path.
  1129. - The worker will now properly handle the :exc:`pytz.AmbiguousTimeError`
  1130. exception raised when an ETA/countdown is prepared while being in DST
  1131. transition (Issue #1061).
  1132. - force_execv: Now makes sure that task symbols in the original
  1133. task modules will always use the correct app instance (Issue #1072).
  1134. - AMQP Backend: Now republishes result messages that have been polled
  1135. (using ``result.ready()`` and friends, ``result.get()`` will not do this
  1136. in this version).
  1137. - Crontab schedule values can now "wrap around"
  1138. This means that values like ``11-1`` translates to ``[11, 12, 1]``.
  1139. Contributed by Loren Abrams.
  1140. - multi stopwait command now shows the pid of processes.
  1141. Contributed by Loren Abrams.
  1142. - Handling of ETA/countdown fixed when the :setting:`CELERY_ENABLE_UTC`
  1143. setting is disabled (Issue #1065).
  1144. - A number of uneeded properties were included in messages,
  1145. caused by accidentally passing ``Queue.as_dict`` as message properties.
  1146. - Rate limit values can now be float
  1147. This also extends the string format so that values like ``"0.5/s"`` works.
  1148. Contributed by Christoph Krybus
  1149. - Fixed a typo in the broadcast routing documentation (Issue #1026).
  1150. - Rewrote confusing section about idempotence in the task user guide.
  1151. - Fixed typo in the daemonization tutorial (Issue #1055).
  1152. - Fixed several typos in the documentation.
  1153. Contributed by Marius Gedminas.
  1154. - Batches: Now works when using the eventlet pool.
  1155. Fix contributed by Thomas Grainger.
  1156. - Batches: Added example sending results to :mod:`celery.contrib.batches`.
  1157. Contributed by Thomas Grainger.
  1158. - Mongodb backend: Connection ``max_pool_size`` can now be set in
  1159. :setting:`CELERY_MONGODB_BACKEND_SETTINGS`.
  1160. Contributed by Craig Younkins.
  1161. - Fixed problem when using earlier versions of :mod:`pytz`.
  1162. Fix contributed by Vlad.
  1163. - Docs updated to include the default value for the
  1164. :setting:`CELERY_TASK_RESULT_EXPIRES` setting.
  1165. - Improvements to the django-celery tutorial.
  1166. Contributed by Locker537.
  1167. - The ``add_consumer`` control command did not properly persist
  1168. the addition of new queues so that they survived connection failure
  1169. (Issue #1079).
  1170. 3.0.12
  1171. ======
  1172. :release-date: 2012-11-06 02:00 P.M UTC
  1173. - Now depends on kombu 2.4.8
  1174. - [Redis] New and improved fair queue cycle algorithm (Kevin McCarthy).
  1175. - [Redis] Now uses a Redis-based mutex when restoring messages.
  1176. - [Redis] Number of messages that can be restored in one interval is no
  1177. longer limited (but can be set using the
  1178. ``unacked_restore_limit``
  1179. :setting:`transport option <BROKER_TRANSPORT_OPTIONS>`.)
  1180. - Heartbeat value can be specified in broker URLs (Mher Movsisyan).
  1181. - Fixed problem with msgpack on Python 3 (Jasper Bryant-Greene).
  1182. - Now depends on billiard 2.7.3.18
  1183. - Celery can now be used with static analysis tools like PyDev/PyCharm/pylint
  1184. etc.
  1185. - Development documentation has moved to Read The Docs.
  1186. The new URL is: http://docs.celeryproject.org/en/master
  1187. - New :setting:`CELERY_QUEUE_HA_POLICY` setting used to set the default
  1188. HA policy for queues when using RabbitMQ.
  1189. - New method ``Task.subtask_from_request`` returns a subtask using the current
  1190. request.
  1191. - Results get_many method did not respect timeout argument.
  1192. Fix contributed by Remigiusz Modrzejewski
  1193. - generic_init.d scripts now support setting :envvar:`CELERY_CREATE_DIRS` to
  1194. always create log and pid directories (Issue #1045).
  1195. This can be set in your :file:`/etc/default/celeryd`.
  1196. - Fixed strange kombu import problem on Python 3.2 (Issue #1034).
  1197. - Worker: ETA scheduler now uses millisecond precision (Issue #1040).
  1198. - The ``--config`` argument to programs is now supported by all loaders.
  1199. - The :setting:`CASSANDRA_OPTIONS` setting has now been documented.
  1200. Contributed by Jared Biel.
  1201. - Task methods (:mod:`celery.contrib.methods`) cannot be used with the old
  1202. task base class, the task decorator in that module now inherits from the new.
  1203. - An optimization was too eager and caused some logging messages to never emit.
  1204. - :mod:`celery.contrib.batches` now works again.
  1205. - Fixed missing whitespace in ``bdist_rpm`` requirements (Issue #1046).
  1206. - Event state's ``tasks_by_name`` applied limit before filtering by name.
  1207. Fix contributed by Alexander A. Sosnovskiy.
  1208. .. _version-3.0.11:
  1209. 3.0.11
  1210. ======
  1211. :release-date: 2012-09-26 04:00 P.M UTC
  1212. - [security:low] generic-init.d scripts changed permissions of /var/log & /var/run
  1213. In the daemonization tutorial the recommended directories were as follows:
  1214. .. code-block:: bash
  1215. CELERYD_LOG_FILE="/var/log/celery/%n.log"
  1216. CELERYD_PID_FILE="/var/run/celery/%n.pid"
  1217. But in the scripts themselves the default files were ``/var/log/celery%n.log``
  1218. and ``/var/run/celery%n.pid``, so if the user did not change the location
  1219. by configuration, the directories ``/var/log`` and ``/var/run`` would be
  1220. created - and worse have their permissions and owners changed.
  1221. This change means that:
  1222. - Default pid file is ``/var/run/celery/%n.pid``
  1223. - Default log file is ``/var/log/celery/%n.log``
  1224. - The directories are only created and have their permissions
  1225. changed if *no custom locations are set*.
  1226. Users can force paths to be created by calling the ``create-paths``
  1227. subcommand:
  1228. .. code-block:: bash
  1229. $ sudo /etc/init.d/celeryd create-paths
  1230. .. admonition:: Upgrading Celery will not update init scripts
  1231. To update the init scripts you have to re-download
  1232. the files from source control and update them manually.
  1233. You can find the init scripts for version 3.0.x at:
  1234. http://github.com/celery/celery/tree/3.0/extra/generic-init.d
  1235. - Now depends on billiard 2.7.3.17
  1236. - Fixes request stack protection when app is initialized more than
  1237. once (Issue #1003).
  1238. - ETA tasks now properly works when system timezone is not the same
  1239. as the configured timezone (Issue #1004).
  1240. - Terminating a task now works if the task has been sent to the
  1241. pool but not yet acknowledged by a pool process (Issue #1007).
  1242. Fix contributed by Alexey Zatelepin
  1243. - Terminating a task now properly updates the state of the task to revoked,
  1244. and sends a ``task-revoked`` event.
  1245. - Generic worker init script now waits for workers to shutdown by default.
  1246. - Multi: No longer parses --app option (Issue #1008).
  1247. - Multi: stop_verify command renamed to stopwait.
  1248. - Daemonization: Now delays trying to create pidfile/logfile until after
  1249. the working directory has been changed into.
  1250. - :program:`celery worker` and :program:`celery beat` commands now respects
  1251. the :option:`--no-color` option (Issue #999).
  1252. - Fixed typos in eventlet examples (Issue #1000)
  1253. Fix contributed by Bryan Bishop.
  1254. Congratulations on opening bug #1000!
  1255. - Tasks that raise :exc:`~celery.exceptions.Ignore` are now acknowledged.
  1256. - Beat: Now shows the name of the entry in ``sending due task`` logs.
  1257. .. _version-3.0.10:
  1258. 3.0.10
  1259. ======
  1260. :release-date: 2012-09-20 05:30 P.M BST
  1261. - Now depends on kombu 2.4.7
  1262. - Now depends on billiard 2.7.3.14
  1263. - Fixes crash at startup when using Django and pre-1.4 projects
  1264. (setup_environ).
  1265. - Hard time limits now sends the KILL signal shortly after TERM,
  1266. to terminate processes that have signal handlers blocked by C extensions.
  1267. - Billiard now installs even if the C extension cannot be built.
  1268. It's still recommended to build the C extension if you are using
  1269. a transport other than rabbitmq/redis (or use forced execv for some
  1270. other reason).
  1271. - Pool now sets a ``current_process().index`` attribute that can be used to create
  1272. as many log files as there are processes in the pool.
  1273. - Canvas: chord/group/chain no longer modifies the state when called
  1274. Previously calling a chord/group/chain would modify the ids of subtasks
  1275. so that:
  1276. .. code-block:: python
  1277. >>> c = chord([add.s(2, 2), add.s(4, 4)], xsum.s())
  1278. >>> c()
  1279. >>> c() <-- call again
  1280. at the second time the ids for the tasks would be the same as in the
  1281. previous invocation. This is now fixed, so that calling a subtask
  1282. won't mutate any options.
  1283. - Canvas: Chaining a chord to another task now works (Issue #965).
  1284. - Worker: Fixed a bug where the request stack could be corrupted if
  1285. relative imports are used.
  1286. Problem usually manifested itself as an exception while trying to
  1287. send a failed task result (``NoneType does not have id attribute``).
  1288. Fix contributed by Sam Cooke.
  1289. - Tasks can now raise :exc:`~celery.exceptions.Ignore` to skip updating states
  1290. or events after return.
  1291. Example:
  1292. .. code-block:: python
  1293. from celery.exceptions import Ignore
  1294. @task
  1295. def custom_revokes():
  1296. if redis.sismember('tasks.revoked', custom_revokes.request.id):
  1297. raise Ignore()
  1298. - The worker now makes sure the request/task stacks are not modified
  1299. by the initial ``Task.__call__``.
  1300. This would previously be a problem if a custom task class defined
  1301. ``__call__`` and also called ``super()``.
  1302. - Because of problems the fast local optimization has been disabled,
  1303. and can only be enabled by setting the :envvar:`USE_FAST_LOCALS` attribute.
  1304. - Worker: Now sets a default socket timeout of 5 seconds at shutdown
  1305. so that broken socket reads do not hinder proper shutdown (Issue #975).
  1306. - More fixes related to late eventlet/gevent patching.
  1307. - Documentation for settings out of sync with reality:
  1308. - :setting:`CELERY_TASK_PUBLISH_RETRY`
  1309. Documented as disabled by default, but it was enabled by default
  1310. since 2.5 as stated by the 2.5 changelog.
  1311. - :setting:`CELERY_TASK_PUBLISH_RETRY_POLICY`
  1312. The default max_retries had been set to 100, but documented as being
  1313. 3, and the interval_max was set to 1 but documented as 0.2.
  1314. The default setting are now set to 3 and 0.2 as it was originally
  1315. documented.
  1316. Fix contributed by Matt Long.
  1317. - Worker: Log messages when connection established and lost have been improved.
  1318. - The repr of a crontab schedule value of '0' should be '*' (Issue #972).
  1319. - Revoked tasks are now removed from reserved/active state in the worker
  1320. (Issue #969)
  1321. Fix contributed by Alexey Zatelepin.
  1322. - gevent: Now supports hard time limits using ``gevent.Timeout``.
  1323. - Documentation: Links to init scripts now point to the 3.0 branch instead
  1324. of the development branch (master).
  1325. - Documentation: Fixed typo in signals user guide (Issue #986).
  1326. ``instance.app.queues`` -> ``instance.app.amqp.queues``.
  1327. - Eventlet/gevent: The worker did not properly set the custom app
  1328. for new greenlets.
  1329. - Eventlet/gevent: Fixed a bug where the worker could not recover
  1330. from connection loss (Issue #959).
  1331. Also, because of a suspected bug in gevent the
  1332. :setting:`BROKER_CONNECTION_TIMEOUT` setting has been disabled
  1333. when using gevent
  1334. 3.0.9
  1335. =====
  1336. :release-date: 2012-08-31 06:00 P.M BST
  1337. - Important note for users of Django and the database scheduler!
  1338. Recently a timezone issue has been fixed for periodic tasks,
  1339. but erroneous timezones could have already been stored in the
  1340. database, so for the fix to work you need to reset
  1341. the ``last_run_at`` fields.
  1342. You can do this by executing the following command:
  1343. .. code-block:: bash
  1344. $ python manage.py shell
  1345. >>> from djcelery.models import PeriodicTask
  1346. >>> PeriodicTask.objects.update(last_run_at=None)
  1347. You also have to do this if you change the timezone or
  1348. :setting:`CELERY_ENABLE_UTC` setting.
  1349. - Note about the :setting:`CELERY_ENABLE_UTC` setting.
  1350. If you previously disabled this just to force periodic tasks to work with
  1351. your timezone, then you are now *encouraged to re-enable it*.
  1352. - Now depends on Kombu 2.4.5 which fixes PyPy + Jython installation.
  1353. - Fixed bug with timezones when :setting:`CELERY_ENABLE_UTC` is disabled
  1354. (Issue #952).
  1355. - Fixed a typo in the celerybeat upgrade mechanism (Issue #951).
  1356. - Make sure the `exc_info` argument to logging is resolved (Issue #899).
  1357. - Fixed problem with Python 3.2 and thread join timeout overflow (Issue #796).
  1358. - A test case was occasionally broken for Python 2.5.
  1359. - Unit test suite now passes for PyPy 1.9.
  1360. - App instances now supports the with statement.
  1361. This calls the new :meth:`~celery.Celery.close` method at exit, which
  1362. cleans up after the app like closing pool connections.
  1363. Note that this is only necessary when dynamically creating apps,
  1364. e.g. for "temporary" apps.
  1365. - Support for piping a subtask to a chain.
  1366. For example:
  1367. .. code-block:: python
  1368. pipe = sometask.s() | othertask.s()
  1369. new_pipe = mytask.s() | pipe
  1370. Contributed by Steve Morin.
  1371. - Fixed problem with group results on non-pickle serializers.
  1372. Fix contributed by Steeve Morin.
  1373. .. _version-3.0.8:
  1374. 3.0.8
  1375. =====
  1376. :release-date: 2012-08-29 05:00 P.M BST
  1377. - Now depends on Kombu 2.4.4
  1378. - Fixed problem with amqplib and receiving larger message payloads
  1379. (Issue #922).
  1380. The problem would manifest itself as either the worker hanging,
  1381. or occasionally a ``Framing error`` exception appearing.
  1382. Users of the new ``pyamqp://`` transport must upgrade to
  1383. :mod:`amqp` 0.9.3.
  1384. - Beat: Fixed another timezone bug with interval and crontab schedules
  1385. (Issue #943).
  1386. - Beat: The schedule file is now automatically cleared if the timezone
  1387. is changed.
  1388. The schedule is also cleared when you upgrade to 3.0.8 from an earlier
  1389. version, this to register the initial timezone info.
  1390. - Events: The :event:`worker-heartbeat` event now include processed and active
  1391. count fields.
  1392. Contributed by Mher Movsisyan.
  1393. - Fixed error with error email and new task classes (Issue #931).
  1394. - ``BaseTask.__call__`` is no longer optimized away if it has been monkey
  1395. patched.
  1396. - Fixed shutdown issue when using gevent (Issue #911 & Issue #936).
  1397. Fix contributed by Thomas Meson.
  1398. .. _version-3.0.7:
  1399. 3.0.7
  1400. =====
  1401. :release-date: 2012-08-24 05:00 P.M BST
  1402. - Fixes several problems with periodic tasks and timezones (Issue #937).
  1403. - Now depends on kombu 2.4.2
  1404. - Redis: Fixes a race condition crash
  1405. - Fixes an infinite loop that could happen when retrying establishing
  1406. the broker connection.
  1407. - Daemons now redirect standard file descriptors to :file:`/dev/null`
  1408. Though by default the standard outs are also redirected
  1409. to the logger instead, but you can disable this by changing
  1410. the :setting:`CELERY_REDIRECT_STDOUTS` setting.
  1411. - Fixes possible problems when eventlet/gevent is patched too late.
  1412. - ``LoggingProxy`` no longer defines ``fileno()`` (Issue #928).
  1413. - Results are now ignored for the chord unlock task.
  1414. Fix contributed by Steeve Morin.
  1415. - Cassandra backend now works if result expiry is disabled.
  1416. Fix contributed by Steeve Morin.
  1417. - The traceback object is now passed to signal handlers instead
  1418. of the string representation.
  1419. Fix contributed by Adam DePue.
  1420. - Celery command: Extensions are now sorted by name.
  1421. - A regression caused the :event:`task-failed` event to be sent
  1422. with the exception object instead of its string representation.
  1423. - The worker daemon would try to create the pid file before daemonizing
  1424. to catch errors, but this file was not immediately released (Issue #923).
  1425. - Fixes Jython compatibility.
  1426. - ``billiard.forking_enable`` was called by all pools not just the
  1427. processes pool, which would result in a useless warning if the billiard
  1428. C extensions were not installed.
  1429. .. _version-3.0.6:
  1430. 3.0.6
  1431. =====
  1432. :release-date: 2012-08-17 11:00 P.M BST
  1433. - Now depends on kombu 2.4.0
  1434. - Now depends on billiard 2.7.3.12
  1435. - Redis: Celery now tries to restore messages whenever there are no messages
  1436. in the queue.
  1437. - Crontab schedules now properly respects :setting:`CELERY_TIMEZONE` setting.
  1438. It's important to note that crontab schedules uses UTC time by default
  1439. unless this setting is set.
  1440. Issue #904 and django-celery #150.
  1441. - ``billiard.enable_forking`` is now only set by the processes pool.
  1442. - The transport is now properly shown by :program:`celery report`
  1443. (Issue #913).
  1444. - The `--app` argument now works if the last part is a module name
  1445. (Issue #921).
  1446. - Fixed problem with unpickleable exceptions (billiard #12).
  1447. - Adds ``task_name`` attribute to ``EagerResult`` which is always
  1448. :const:`None` (Issue #907).
  1449. - Old Task class in :mod:`celery.task` no longer accepts magic kwargs by
  1450. default (Issue #918).
  1451. A regression long ago disabled magic kwargs for these, and since
  1452. no one has complained about it we don't have any incentive to fix it now.
  1453. - The ``inspect reserved`` control command did not work properly.
  1454. - Should now play better with static analyzation tools by explicitly
  1455. specifying dynamically created attributes in the :mod:`celery` and
  1456. :mod:`celery.task` modules.
  1457. - Terminating a task now results in
  1458. :exc:`~celery.exceptions.RevokedTaskError` instead of a ``WorkerLostError``.
  1459. - ``AsyncResult.revoke`` now accepts ``terminate`` and ``signal`` arguments.
  1460. - The :event:`task-revoked` event now includes new fields: ``terminated``,
  1461. ``signum``, and ``expired``.
  1462. - The argument to :class:`~celery.exceptions.TaskRevokedError` is now one
  1463. of the reasons ``revoked``, ``expired`` or ``terminated``.
  1464. - Old Task class does no longer use classmethods for push_request and
  1465. pop_request (Issue #912).
  1466. - ``GroupResult`` now supports the ``children`` attribute (Issue #916).
  1467. - ``AsyncResult.collect`` now respects the ``intermediate`` argument
  1468. (Issue #917).
  1469. - Fixes example task in documentation (Issue #902).
  1470. - Eventlet fixed so that the environment is patched as soon as possible.
  1471. - eventlet: Now warns if celery related modules that depends on threads
  1472. are imported before eventlet is patched.
  1473. - Improved event and camera examples in the monitoring guide.
  1474. - Disables celery command setuptools entrypoints if the command can't be
  1475. loaded.
  1476. - Fixed broken ``dump_request`` example in the tasks guide.
  1477. .. _version-3.0.5:
  1478. 3.0.5
  1479. =====
  1480. :release-date: 2012-08-01 04:00 P.M BST
  1481. - Now depends on kombu 2.3.1 + billiard 2.7.3.11
  1482. - Fixed a bug with the -B option (``cannot pickle thread.lock objects``)
  1483. (Issue #894 + Issue #892, + django-celery #154).
  1484. - The :control:`restart_pool` control command now requires the
  1485. :setting:`CELERYD_POOL_RESTARTS` setting to be enabled
  1486. This change was necessary as the multiprocessing event that the restart
  1487. command depends on is responsible for creating many semaphores/file
  1488. descriptors, resulting in problems in some environments.
  1489. - ``chain.apply`` now passes args to the first task (Issue #889).
  1490. - Documented previously secret options to the Django-Celery monitor
  1491. in the monitoring userguide (Issue #396).
  1492. - Old changelog are now organized in separate documents for each series,
  1493. see :ref:`history`.
  1494. .. _version-3.0.4:
  1495. 3.0.4
  1496. =====
  1497. :release-date: 2012-07-26 07:00 P.M BST
  1498. - Now depends on Kombu 2.3
  1499. - New experimental standalone Celery monitor: Flower
  1500. See :ref:`monitoring-flower` to read more about it!
  1501. Contributed by Mher Movsisyan.
  1502. - Now supports AMQP heartbeats if using the new ``pyamqp://`` transport.
  1503. - The py-amqp transport requires the :mod:`amqp` library to be installed::
  1504. $ pip install amqp
  1505. - Then you need to set the transport URL prefix to ``pyamqp://``.
  1506. - The default heartbeat value is 10 seconds, but this can be changed using
  1507. the :setting:`BROKER_HEARTBEAT` setting::
  1508. BROKER_HEARTBEAT = 5.0
  1509. - If the broker heartbeat is set to 10 seconds, the heartbeats will be
  1510. monitored every 5 seconds (double the hertbeat rate).
  1511. See the `Kombu 2.3 changelog`_ for more information.
  1512. .. _`Kombu 2.3 changelog`:
  1513. http://kombu.readthedocs.org/en/latest/changelog.html#version-2-3-0
  1514. - Now supports RabbitMQ Consumer Cancel Notifications, using the ``pyamqp://``
  1515. transport.
  1516. This is essential when running RabbitMQ in a cluster.
  1517. See the `Kombu 2.3 changelog`_ for more information.
  1518. - Delivery info is no longer passed directly through.
  1519. It was discovered that the SQS transport adds objects that can't
  1520. be pickled to the delivery info mapping, so we had to go back
  1521. to using the whitelist again.
  1522. Fixing this bug also means that the SQS transport is now working again.
  1523. - The semaphore was not properly released when a task was revoked (Issue #877).
  1524. This could lead to tasks being swallowed and not released until a worker
  1525. restart.
  1526. Thanks to Hynek Schlawack for debugging the issue.
  1527. - Retrying a task now also forwards any linked tasks.
  1528. This means that if a task is part of a chain (or linked in some other
  1529. way) and that even if the task is retried, then the next task in the chain
  1530. will be executed when the retry succeeds.
  1531. - Chords: Now supports setting the interval and other keyword arguments
  1532. to the chord unlock task.
  1533. - The interval can now be set as part of the chord subtasks kwargs::
  1534. chord(header)(body, interval=10.0)
  1535. - In addition the chord unlock task now honors the Task.default_retry_delay
  1536. option, used when none is specified, which also means that the default
  1537. interval can also be changed using annotations:
  1538. .. code-block:: python
  1539. CELERY_ANNOTATIONS = {
  1540. 'celery.chord_unlock': {
  1541. 'default_retry_delay': 10.0,
  1542. }
  1543. }
  1544. - New :meth:`@Celery.add_defaults` method can add new default configuration
  1545. dicts to the applications configuration.
  1546. For example::
  1547. config = {'FOO': 10}
  1548. celery.add_defaults(config)
  1549. is the same as ``celery.conf.update(config)`` except that data will not be
  1550. copied, and that it will not be pickled when the worker spawns child
  1551. processes.
  1552. In addition the method accepts a callable::
  1553. def initialize_config():
  1554. # insert heavy stuff that can't be done at import time here.
  1555. celery.add_defaults(initialize_config)
  1556. which means the same as the above except that it will not happen
  1557. until the celery configuration is actually used.
  1558. As an example, Celery can lazily use the configuration of a Flask app::
  1559. flask_app = Flask()
  1560. celery = Celery()
  1561. celery.add_defaults(lambda: flask_app.config)
  1562. - Revoked tasks were not marked as revoked in the result backend (Issue #871).
  1563. Fix contributed by Hynek Schlawack.
  1564. - Eventloop now properly handles the case when the epoll poller object
  1565. has been closed (Issue #882).
  1566. - Fixed syntax error in ``funtests/test_leak.py``
  1567. Fix contributed by Catalin Iacob.
  1568. - group/chunks: Now accepts empty task list (Issue #873).
  1569. - New method names:
  1570. - ``Celery.default_connection()`` ➠ :meth:`~@Celery.connection_or_acquire`.
  1571. - ``Celery.default_producer()`` ➠ :meth:`~@Celery.producer_or_acquire`.
  1572. The old names still work for backward compatibility.
  1573. .. _version-3.0.3:
  1574. 3.0.3
  1575. =====
  1576. :release-date: 2012-07-20 09:17 P.M BST
  1577. :by: Ask Solem
  1578. - amqplib passes the channel object as part of the delivery_info
  1579. and it's not pickleable, so we now remove it.
  1580. .. _version-3.0.2:
  1581. 3.0.2
  1582. =====
  1583. :release-date: 2012-07-20 04:00 P.M BST
  1584. :by: Ask Solem
  1585. - A bug caused the following task options to not take defaults from the
  1586. configuration (Issue #867 + Issue #858)
  1587. The following settings were affected:
  1588. - :setting:`CELERY_IGNORE_RESULT`
  1589. - :setting:`CELERYD_SEND_TASK_ERROR_EMAILS`
  1590. - :setting:`CELERY_TRACK_STARTED`
  1591. - :setting:`CElERY_STORE_ERRORS_EVEN_IF_IGNORED`
  1592. Fix contributed by John Watson.
  1593. - Task Request: ``delivery_info`` is now passed through as-is (Issue #807).
  1594. - The eta argument now supports datetime's with a timezone set (Issue #855).
  1595. - The worker's banner displayed the autoscale settings in the wrong order
  1596. (Issue #859).
  1597. - Extension commands are now loaded after concurrency is set up
  1598. so that they don't interfere with e.g. eventlet patching.
  1599. - Fixed bug in the threaded pool (Issue #863)
  1600. - The task failure handler mixed up the fields in :func:`sys.exc_info`.
  1601. Fix contributed by Rinat Shigapov.
  1602. - Fixed typos and wording in the docs.
  1603. Fix contributed by Paul McMillan
  1604. - New setting: :setting:`CELERY_WORKER_DIRECT`
  1605. If enabled each worker will consume from their own dedicated queue
  1606. which can be used to route tasks to specific workers.
  1607. - Fixed several edge case bugs in the add consumer remote control command.
  1608. - :mod:`~celery.contrib.migrate`: Can now filter and move tasks to specific
  1609. workers if :setting:`CELERY_WORKER_DIRECT` is enabled.
  1610. Among other improvements, the following functions have been added:
  1611. * ``move_direct(filterfun, **opts)``
  1612. * ``move_direct_by_id(task_id, worker_hostname, **opts)``
  1613. * ``move_direct_by_idmap({task_id: worker_hostname, ...}, **opts)``
  1614. * ``move_direct_by_taskmap({task_name: worker_hostname, ...}, **opts)``
  1615. - :meth:`~celery.Celery.default_connection` now accepts a pool argument that
  1616. if set to false causes a new connection to be created instead of acquiring
  1617. one from the pool.
  1618. - New signal: :signal:`celeryd_after_setup`.
  1619. - Default loader now keeps lowercase attributes from the configuration module.
  1620. .. _version-3.0.1:
  1621. 3.0.1
  1622. =====
  1623. :release-date: 2012-07-10 06:00 P.M BST
  1624. :by: Ask Solem
  1625. - Now depends on kombu 2.2.5
  1626. - inspect now supports limit argument::
  1627. myapp.control.inspect(limit=1).ping()
  1628. - Beat: now works with timezone aware datetime's.
  1629. - Task classes inheriting ``from celery import Task``
  1630. mistakingly enabled ``accept_magic_kwargs``.
  1631. - Fixed bug in ``inspect scheduled`` (Issue #829).
  1632. - Beat: Now resets the schedule to upgrade to UTC.
  1633. - The :program:`celery worker` command now works with eventlet/gevent.
  1634. Previously it would not patch the environment early enough.
  1635. - The :program:`celery` command now supports extension commands
  1636. using setuptools entry-points.
  1637. Libraries can add additional commands to the :program:`celery`
  1638. command by adding an entry-point like::
  1639. setup(
  1640. entry_points=[
  1641. 'celery.commands': [
  1642. 'foo = my.module:Command',
  1643. ],
  1644. ],
  1645. ...)
  1646. The command must then support the interface of
  1647. :class:`celery.bin.base.Command`.
  1648. - contrib.migrate: New utilities to move tasks from one queue to another.
  1649. - :func:`~celery.contrib.migrate.move_tasks`
  1650. - :func:`~celery.contrib.migrate.move_task_by_id`
  1651. - The :event:`task-sent` event now contains ``exchange`` and ``routing_key``
  1652. fields.
  1653. - Fixes bug with installing on Python 3.
  1654. Fix contributed by Jed Smith.
  1655. .. _version-3.0.0:
  1656. 3.0.0 (Chiastic Slide)
  1657. ======================
  1658. :release-date: 2012-07-07 01:30 P.M BST
  1659. :by: Ask Solem
  1660. See :ref:`whatsnew-3.0`.