瀏覽代碼

Warning emitted by celery.decorators was accidentally UserWarning (should be deprecationwarning)

Ask Solem 14 年之前
父節點
當前提交
8670d21eb3
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      celery/decorators.py

+ 2 - 2
celery/decorators.py

@@ -17,7 +17,7 @@ import warnings
 from celery import task as _task
 from celery import task as _task
 
 
 
 
-warnings.warn("""
+warnings.warn(PendingDeprecationWarning("""
 The `celery.decorators` module and the magic keyword arguments
 The `celery.decorators` module and the magic keyword arguments
 are pending deprecation and will be deprecated in 2.4, then removed
 are pending deprecation and will be deprecated in 2.4, then removed
 in 3.0.
 in 3.0.
@@ -27,7 +27,7 @@ and `celery.task.task` used instead of `celery.decorators.task`.
 
 
 See the 2.2 Changelog for more information.
 See the 2.2 Changelog for more information.
 
 
-""")
+"""))
 
 
 
 
 def task(*args, **kwargs):  # ✞
 def task(*args, **kwargs):  # ✞