100+ results for 'PendingDeprecationWarning'

Not the results you expected?

subclassing.py (https://github.com/theosp/google_appengine.git) Python · 117 lines

16 warn("A Field class whose %s method hasn't been updated to take a "

17 "`connection` argument." % func.__name__,

18 PendingDeprecationWarning, stacklevel=2)

19

20 def inner(*args, **kwargs):

23 kwargs['connection'] = connection

24 warn("%s has been called without providing a connection argument. " %

25 func.__name__, PendingDeprecationWarning,

26 stacklevel=1)

27 if updated:

41 warn("A Field class whose %s method hasn't been updated to take "

42 "`connection` and `prepared` arguments." % func.__name__,

43 PendingDeprecationWarning, stacklevel=2)

44

45 def inner(*args, **kwargs):

UserDict.py (https://gitlab.com/nachee1325/todoprv) Python · 213 lines

16 import warnings

17 warnings.warn("Passing 'dict' as keyword argument is "

18 "deprecated", PendingDeprecationWarning,

19 stacklevel=2)

20 else:

75 import warnings

76 warnings.warn("Passing 'dict' as keyword argument is deprecated",

77 PendingDeprecationWarning, stacklevel=2)

78 else:

79 dict = None

memcached.py (https://github.com/Tippr/django.git) Python · 177 lines

131 warnings.warn(

132 "memcached.CacheClass has been split into memcached.MemcachedCache and memcached.PyLibMCCache. Please update your cache backend setting.",

133 PendingDeprecationWarning

134 )

135 try:

list_detail.py (https://github.com/crisbar/curso_python_dga_11.git) Python · 152 lines

8 warnings.warn(

9 'Function-based generic views have been deprecated; use class-based views instead.',

10 PendingDeprecationWarning

11 )

12

__init__.py (https://bitbucket.org/ssaltzman/poet.git) Python · 145 lines

56 "aren't supported anymore. Use the "

57 "LOCALE_PATHS setting instead.",

58 PendingDeprecationWarning)

59 else:

60 from django.utils.translation import trans_null as trans

test_archive_util.py (https://gitlab.com/sisfs/G_Music) Python · 269 lines

158 tmpdir, tmpdir2, base_name = self._create_files()

159

160 # using compress and testing the PendingDeprecationWarning

161 old_dir = os.getcwd()

162 os.chdir(tmpdir)

settings.py (https://github.com/Fandekasp/django-massmedia.git) Python · 211 lines

64 warnings.warn(

65 "settings.MMEDIA_IMAGE_EXTS is deprecated; use settings.MASSMEDIA_SETTINGS instead.",

66 PendingDeprecationWarning

67 )

68

71 warnings.warn(

72 "settings.MMEDIA_VIDEO_EXTS is deprecated; use settings.MASSMEDIA_SETTINGS instead.",

73 PendingDeprecationWarning

74 )

75

78 warnings.warn(

79 "settings.MMEDIA_AUDIO_EXTS is deprecated; use settings.MASSMEDIA_SETTINGS instead.",

80 PendingDeprecationWarning

81 )

82

deprecation.py (https://gitlab.com/llndhlov/journly) Python · 147 lines

10

11

12 class RemovedInDjango41Warning(PendingDeprecationWarning):

13 pass

14

UniGene.py (https://github.com/timwintle/biopython.git) Python · 228 lines

23 "release of Biopython. To parse UniGene flat files, "

24 "please use the parser in Bio.UniGene instead",

25 PendingDeprecationWarning)

26

27 import string

__init__.py (https://github.com/eric-brechemier/django.git) Python · 108 lines

14 warnings.warn(

15 'The run_gis_tests() test runner has been deprecated in favor of GeoDjangoTestSuiteRunner.',

16 PendingDeprecationWarning

17 )

18 test_runner = GeoDjangoTestSuiteRunner(verbosity=verbosity, interactive=interactive, failfast=failfast)

__init__.py (https://github.com/theosp/google_appengine.git) Python · 161 lines

24 if mimetype:

25 warnings.warn("The mimetype keyword argument is deprecated, use "

26 "content_type instead", PendingDeprecationWarning, stacklevel=2)

27 httpresponse_kwargs['content_type'] = mimetype

28

auth_backends.py (https://github.com/RefuX/applause.git) Python · 253 lines

161 settings.AUTHENTICATION_BACKENDS = self.curr_auth

162 warnings.resetwarnings()

163 warnings.simplefilter('ignore', PendingDeprecationWarning)

164

165 def test_has_perm(self):

__init__.py (https://bitbucket.org/taxilian/racecontrol5.git) Python · 104 lines

17 warnings.warn(

18 "settings.DATABASE_* is deprecated; use settings.DATABASES instead.",

19 PendingDeprecationWarning

20 )

21

46 "Modify ENGINE in the %s database configuration to select "

47 "a backend from 'django.contrib.gis.db.backends'" % alias,

48 PendingDeprecationWarning

49 )

50 if database['ENGINE'] == 'postgresql_psycopg2':

58 "Short names for ENGINE in database configurations are deprecated. "

59 "Prepend %s.ENGINE with 'django.db.backends.'" % alias,

60 PendingDeprecationWarning

61 )

62 full_engine = "django.db.backends.%s" % database['ENGINE']

__init__.py (https://github.com/abstract-open-solutions/ScrumDo.git) Python · 126 lines

31 import warnings

32 warnings.warn("ChoiceEnum is deprecated, use Choices instead.",

33 PendingDeprecationWarning)

34 self._choices = tuple(enumerate(choices))

35 self._choice_dict = dict(self._choices)

__init__.py (https://github.com/rohanza/django.git) Python · 113 lines

34 if not hasattr(cls, 'supports_inactive_user'):

35 warn("Authentication backends without a `supports_inactive_user` attribute are deprecated. Please define it in %s." % cls,

36 PendingDeprecationWarning)

37 cls.supports_inactive_user = False

38 return cls()

regcheck.py (https://github.com/branaway/play.git) Python · 125 lines

4 import warnings

5 warnings.warn("The regcheck module has been pending deprecation since build 210",

6 category=PendingDeprecationWarning)

7

8 import win32con

hmac.py (https://github.com/akheron/cpython.git) Python · 144 lines

44 if digestmod is None:

45 _warnings.warn("HMAC() without an explicit digestmod argument "

46 "is deprecated.", PendingDeprecationWarning, 2)

47 digestmod = _hashlib.md5

48

__init__.py (https://github.com/chapmanb/biopython.git) Python · 171 lines

22 "is retained (and extended) in Bio.motifs, usage may"

23 "be different.",

24 PendingDeprecationWarning)

25

26

test_tracking.py (https://github.com/arokem/dipy.git) Python · 262 lines

78 warnings.filterwarnings(

79 "ignore", message=descoteaux07_legacy_msg,

80 category=PendingDeprecationWarning)

81 reconst_csd_flow.run(dwi_path, bval_path, bvec_path, mask_path,

82 out_dir=out_dir, extract_pam_values=True)

96 warnings.filterwarnings(

97 "ignore", message=descoteaux07_legacy_msg,

98 category=PendingDeprecationWarning)

99 pf_track_pam.run(pam_path, wm_path, gm_path, csf_path, seeds_path)

100 tractogram_path = \

108 warnings.filterwarnings(

109 "ignore", message=descoteaux07_legacy_msg,

110 category=PendingDeprecationWarning)

111 pf_track_pam.run(pam_path,

112 wm_path,

archive_util.py (https://bitbucket.org/kbengine/kbengine.git) Python · 184 lines

58 # compression using `compress`

59 if compress == 'compress':

60 warn("'compress' will be deprecated.", PendingDeprecationWarning)

61 # the option varies depending on the platform

62 compressed_name = archive_name + compress_ext[compress]

deprecation.py (https://gitlab.com/asmjahid/django) Python · 111 lines

5

6

7 class RemovedInDjango20Warning(PendingDeprecationWarning):

8 pass

9

list_box.py (https://github.com/enthought/pyface.git) Python · 151 lines

52 "in a future Pyface version, use create=False and explicitly "

53 "call create() for future behaviour",

54 PendingDeprecationWarning,

55 )

56

forms.py (https://github.com/blacktear23/django.git) Python · 145 lines

74 warnings.warn(

75 "Support for validating the gender of a CZ Birth number has been deprecated.",

76 PendingDeprecationWarning)

77 if gender == 'f':

78 female_const = 50

utils.py (https://github.com/theosp/google_appengine.git) Python · 170 lines

25 warnings.warn(

26 "Short names for DATABASE_ENGINE are deprecated; prepend with 'django.db.backends.'",

27 PendingDeprecationWarning

28 )

29 return module

__init__.py (https://github.com/alemacgo/pypy.git) Python · 67 lines

32 'OSError' : 'interp_exceptions.W_OSError',

33 'OverflowError' : 'interp_exceptions.W_OverflowError',

34 'PendingDeprecationWarning' : 'interp_exceptions.W_PendingDeprecationWarning',

35 'ReferenceError' : 'interp_exceptions.W_ReferenceError',

36 'RuntimeError' : 'interp_exceptions.W_RuntimeError',

test_recwarn.py (https://github.com/rillian/firefox.git) Python · 227 lines

123 def test_deprecated_call_pending(self):

124 def f():

125 py.std.warnings.warn(PendingDeprecationWarning("hi"))

126 pytest.deprecated_call(f)

127

test_forecast.py (https://github.com/arokem/dipy.git) Python · 300 lines

47 warnings.filterwarnings(

48 "ignore", message=descoteaux07_legacy_msg,

49 category=PendingDeprecationWarning)

50 fm = ForecastModel(data.gtab,

51 sh_order=data.sh_order,

59 warnings.filterwarnings(

60 "ignore", message=descoteaux07_legacy_msg,

61 category=PendingDeprecationWarning)

62 fodf = f_fit.odf(sphere, clip_negative=False)

63 assert_almost_equal(fodf[fodf < 0].sum(), 0, 2)

73 warnings.filterwarnings(

74 "ignore", message=descoteaux07_legacy_msg,

75 category=PendingDeprecationWarning)

76 fm = ForecastModel(data.gtab, dec_alg='CSD',

77 sphere=data.sphere, lambda_csd=data.lambda_csd)

context_processors.py (https://bitbucket.org/ssaltzman/poet.git) Python · 113 lines

98 "deprecated; use `django.contrib.auth.context_processors.PermLookupDict` " \

99 "instead.",

100 PendingDeprecationWarning

101 )

102 super(PermLookupDict, self).__init__(*args, **kwargs)

109 "deprecated; use `django.contrib.auth.context_processors.PermWrapper` " \

110 "instead.",

111 PendingDeprecationWarning

112 )

113 super(PermWrapper, self).__init__(*args, **kwargs)

__init__.py (https://github.com/aruder77/applause.git) Python · 86 lines

25 except ImportError:

26 # Python 2.5, 2.4. Works on Python 2.6 but raises

27 # PendingDeprecationWarning

28 from cgi import parse_qsl

29

deprecation.py (https://gitlab.com/briankiragu/django) Python · 130 lines

9

10

11 class RemovedInDjango21Warning(PendingDeprecationWarning):

12 pass

13

app_directories.py (https://gitlab.com/gregtyka/frankenserver) Python · 74 lines

69 warnings.warn(

70 "'django.template.loaders.app_directories.load_template_source' is deprecated; use 'django.template.loaders.app_directories.Loader' instead.",

71 PendingDeprecationWarning

72 )

73 return _loader.load_template_source(template_name, template_dirs)

memcached.py (https://github.com/lmorchard/home-snippets-server-lib.git) Python · 104 lines

11 warnings.warn(

12 "Support for the 'cmemcache' library has been deprecated. Please use python-memcached instead.",

13 PendingDeprecationWarning

14 )

15 except ImportError:

errwarning.py (https://gitlab.com/betse/betse) Python · 139 lines

83 Single-shot context manager temporarily ignoring all **deprecation

84 warnings** (i.e., instances of the :class:`DeprecationWarning`,

85 :class:`PendingDeprecationWarning`, and :class:`FutureWarning` exception

86 base classes) emitted by the :mod:`warnings` module for the duration of

87 this context.

95 return ignoring_warnings(

96 DeprecationWarning,

97 PendingDeprecationWarning,

98 FutureWarning,

99 )

deprecations.py (https://gitlab.com/abhi1tb/build) Python · 259 lines

35

36 def warn_pending_deprecation(msg, stacklevel=3):

37 warnings.warn(msg, exc.SAPendingDeprecationWarning, stacklevel=stacklevel)

38

39

185 return _decorate_with_warning(

186 fn,

187 exc.SAPendingDeprecationWarning,

188 message % dict(func=fn.__name__),

189 header,

csrf.py (https://github.com/Tippr/django.git) Python · 79 lines

56 warnings.warn("csrf_response_exempt is deprecated. It no longer performs a "

57 "function, and calls to it can be removed.",

58 PendingDeprecationWarning)

59 return view_func

60

64 """

65 warnings.warn("csrf_view_exempt is deprecated. Use csrf_exempt instead.",

66 PendingDeprecationWarning)

67 return csrf_exempt(view_func)

68

fields.py (https://github.com/django-nonrel/mongodb-engine.git) Python · 174 lines

43 "version 0.6. If you consider this option useful "

44 "please add a comment on issue #65 with your use "

45 "case.", PendingDeprecationWarning)

46

47 kwargs['max_length'] = 24

__init__.py (https://github.com/lmorchard/home-snippets-server-lib.git) Python · 103 lines

25 except AttributeError:

26 warn("Authentication backends without a `supports_object_permissions` attribute are deprecated. Please define it in %s." % cls,

27 PendingDeprecationWarning)

28 cls.supports_object_permissions = False

29 try:

31 except AttributeError:

32 warn("Authentication backends without a `supports_anonymous_user` attribute are deprecated. Please define it in %s." % cls,

33 PendingDeprecationWarning)

34 cls.supports_anonymous_user = False

35 return cls()

context_processors.py (https://github.com/theosp/google_appengine.git) Python · 102 lines

23 warnings.warn(

24 "The context processor at `django.core.context_processors.auth` is " "deprecated; use the path `django.contrib.auth.context_processors.auth` " "instead.",

25 PendingDeprecationWarning

26 )

27 from google.appengine._internal.django.contrib.auth.context_processors import auth as auth_context_processor

AbstractPropertyMap.py (https://github.com/timwintle/biopython.git) Python · 134 lines

79 """

80 import warnings

81 warnings.warn("This function is obsolete; use 'id in mapping' instead", PendingDeprecationWarning)

82 return (id in self)

83

__init__.py (https://github.com/asavoy/django-model-utils.git) Python · 135 lines

4 warnings.warn(

5 "Django 1.1 support in django-model-utils is pending deprecation.",

6 PendingDeprecationWarning)

7

8

loaders.py (https://github.com/pokutnik/lettuce.git) Python · 150 lines

70 settings.INSTALLED_APPS = []

71 self._warnings_state = get_warnings_state()

72 warnings.simplefilter("ignore", PendingDeprecationWarning)

73

74 def tearDown(self):

deprecation.py (https://github.com/pombredanne/pip.git) Python · 68 lines

16

17

18 class RemovedInPip8Warning(PipDeprecationWarning, PendingDeprecationWarning):

19 pass

20

48 # Things that are DeprecationWarnings will be removed in the very

49 # next version of pip. We want these to be more obvious so we

50 # use the ERROR logging level while the PendingDeprecationWarnings

51 # are still have at least 2 versions to go until they are removed

52 # so they can just be warnings.

cache.py (https://bitbucket.org/pcelta/python-django.git) Python · 92 lines

45 'cache_page(timeout, [cache=cache name], [key_prefix=key prefix]). '

46 'All other ways are deprecated.',

47 PendingDeprecationWarning,

48 stacklevel=3)

49

test_warnings.py (https://bitbucket.org/x893/sirflive.git) Python · 89 lines

47 # XXX OverflowWarning should go away for Python 2.5.

48 for category in [DeprecationWarning, FutureWarning, OverflowWarning,

49 PendingDeprecationWarning, RuntimeWarning,

50 SyntaxWarning, UserWarning, Warning]:

51 if category.__name__ in self.ignored:

test_warnings.py (https://github.com/jackygrahamez/DrugDiscovery-Home.git) Python · 105 lines

46 text = 'None'

47 for category in [DeprecationWarning, FutureWarning,

48 PendingDeprecationWarning, RuntimeWarning,

49 SyntaxWarning, UserWarning, Warning]:

50 if category.__name__ in self.ignored:

test_pmf.py (https://github.com/arokem/dipy.git) Python · 138 lines

20 warnings.filterwarnings(

21 "ignore", message=descoteaux07_legacy_msg,

22 category=PendingDeprecationWarning)

23 pmfgen = SHCoeffPmfGen(np.random.random([2, 2, 2, 28]), sphere, None)

24 point = np.array([1, 1, 1], dtype='float')

38 warnings.filterwarnings(

39 "ignore", message=descoteaux07_legacy_msg,

40 category=PendingDeprecationWarning)

41 pmfgen = SHCoeffPmfGen(np.ones([2, 2, 2, 28]), sphere, None)

42

95 warnings.filterwarnings(

96 "ignore", message=descoteaux07_legacy_msg,

97 category=PendingDeprecationWarning)

98 boot_pmf_gen = BootPmfGen(

99 data, model=tensor_model, sphere=hsph_updated)

tokens.py (https://github.com/blacktear23/django.git) Python · 82 lines

36 if not constant_time_compare(self._make_token_with_timestamp(user, ts), token):

37 # Fallback to Django 1.2 method for compatibility.

38 # PendingDeprecationWarning <- here to remind us to remove this in

39 # Django 1.5

40 if not constant_time_compare(self._make_token_with_timestamp_old(user, ts), token):

deprecation.py (https://github.com/dpritsos/WEGA.git) Python · 222 lines

83

84 pending : bool, optional

85 If True, uses a PendingDeprecationWarning instead of a

86 DeprecationWarning.

87

144

145 pending : bool, optional

146 If True, uses a PendingDeprecationWarning instead of a

147 DeprecationWarning.

148

__init__.py (https://github.com/lmorchard/home-snippets-server-lib.git) Python · 111 lines

107 warnings.warn(

108 'mail.SMTPConnection is deprecated; use mail.get_connection() instead.',

109 PendingDeprecationWarning

110 )

111 super(SMTPConnection, self).__init__(*args, **kwds)

_warnings_test.py (https://bitbucket.org/mdavid/dlr.git) Python · 112 lines

26 #--GLOBALS---------------------------------------------------------------------

27 EXPECTED = [] # expected output (ignoring filename, lineno, and line)

28 WARN_TYPES = [Warning, UserWarning, PendingDeprecationWarning, SyntaxWarning,

29 RuntimeWarning, FutureWarning, ImportWarning, UnicodeWarning,

30 BytesWarning]

loaders.py (https://github.com/eric-brechemier/django.git) Python · 148 lines

68 self._old_installed_apps = settings.INSTALLED_APPS

69 settings.INSTALLED_APPS = []

70 warnings.simplefilter("ignore", PendingDeprecationWarning)

71

72 def tearDown(self):

storage.py (https://github.com/zodiak/django_ondev.git) Python · 95 lines

58 "The storage backend 'staticfiles.storage.StaticFileStorage' "

59 "was renamed to 'staticfiles.storage.StaticFilesStorage'.",

60 PendingDeprecationWarning)

61 super(StaticFileStorage, self).__init__(*args, **kwargs)

62

forms.py (https://github.com/WoLpH/django-tcc.git) Python · 163 lines

89 if not constant_time_compare(expected_hash, actual_hash):

90 # Fallback to Django 1.2 method for compatibility

91 # PendingDeprecationWarning <- here to remind us to remove this

92 # fallback in Django 1.5

93 expected_hash_old = self._generate_security_hash_old(**security_hash_dict)

__init__.py (https://github.com/gabelula/b-counted.git) Python · 101 lines

16 warnings.warn(

17 "settings.DATABASE_* is deprecated; use settings.DATABASES instead.",

18 PendingDeprecationWarning

19 )

20

43 "Modify ENGINE in the %s database configuration to select "

44 "a backend from 'django.contrib.gis.db.backends'" % alias,

45 PendingDeprecationWarning

46 )

47 if database['ENGINE'] == 'postgresql_psycopg2':

55 "Short names for ENGINE in database configurations are deprecated. "

56 "Prepend %s.ENGINE with 'django.db.backends.'" % alias,

57 PendingDeprecationWarning

58 )

59 full_engine = "django.db.backends.%s" % database['ENGINE']

cache.py (https://github.com/Tippr/django.git) Python · 91 lines

45 'cache_page(timeout, [cache=cache name], [key_prefix=key prefix]). '

46 'All other ways are deprecated.',

47 PendingDeprecationWarning)

48

49 if len(args) > 1:

context_processors.py (https://github.com/lmorchard/home-snippets-server-lib.git) Python · 104 lines

25 "deprecated; use the path `django.contrib.auth.context_processors.auth` " \

26 "instead.",

27 PendingDeprecationWarning

28 )

29 from django.contrib.auth.context_processors import auth as auth_context_processor

testing_support.py (https://github.com/behave/behave.git) Python · 94 lines

80 import warnings

81 warnings.warn("Use 'use_step_matcher()' instead",

82 PendingDeprecationWarning, stacklevel=2)

83 self.use_step_matcher(name)

84

itercompat.py (https://github.com/ptone/django-oldmaster.git) Python · 35 lines

19

20 def product(*args, **kwds):

21 # PendingDeprecationWarning in 1.5, remove this comment when the Deprecations

22 # will have been advanced for 1.5

23 warnings.warn("django.utils.itercompat.product is deprecated; use the native version instead",

24 PendingDeprecationWarning)

25 return itertools.product(*args, **kwds)

26

27 def all(iterable):

28 warnings.warn("django.utils.itercompat.all is deprecated; use the native version instead",

29 PendingDeprecationWarning)

30 return __builtin__.all(iterable)

31

deprecations.py (https://gitlab.com/ztane/sqlalchemy) Python · 143 lines

19

20 def warn_pending_deprecation(msg, stacklevel=3):

21 warnings.warn(msg, exc.SAPendingDeprecationWarning, stacklevel=stacklevel)

22

23

81 def decorate(fn):

82 return _decorate_with_warning(

83 fn, exc.SAPendingDeprecationWarning,

84 message % dict(func=fn.__name__), header)

85 return decorate

test_shore.py (https://github.com/arokem/dipy.git) Python · 105 lines

62 warnings.filterwarnings(

63 "ignore", message=descoteaux07_legacy_msg,

64 category=PendingDeprecationWarning)

65 asmfit = asm.fit(data.S)

66 eap = asmfit.pdf_grid(11, 20e-03)

75 warnings.filterwarnings(

76 "ignore", message=descoteaux07_legacy_msg,

77 category=PendingDeprecationWarning)

78 asmfit = asm.fit(data.S)

79 npt.assert_almost_equal(compute_e0(asmfit), 1)

89 warnings.filterwarnings(

90 "ignore", message=descoteaux07_legacy_msg,

91 category=PendingDeprecationWarning)

92 asmfit = asm.fit(data.S)

93 npt.assert_almost_equal(compute_e0(asmfit), 1)

warnings.py (https://gitlab.com/phongphans61/machine-learning-tictactoe) Python · 139 lines

48 # If user is not explicitly configuring warning filters, show deprecation warnings by default (#2908).

49 warnings.filterwarnings("always", category=DeprecationWarning)

50 warnings.filterwarnings("always", category=PendingDeprecationWarning)

51

52 apply_warning_filters(config_filters, cmdline_filters)

eggs.py (https://github.com/pokutnik/lettuce.git) Python · 39 lines

34 warnings.warn(

35 "'django.template.loaders.eggs.load_template_source' is deprecated; use 'django.template.loaders.eggs.Loader' instead.",

36 PendingDeprecationWarning

37 )

38 return _loader.load_template_source(template_name, template_dirs)

test_shore_metrics.py (https://github.com/arokem/dipy.git) Python · 117 lines

53 warnings.filterwarnings(

54 "ignore", message=descoteaux07_legacy_msg,

55 category=PendingDeprecationWarning)

56 asmfit = asm.fit(S)

57 c_shore = asmfit.shore_coeff

60 warnings.filterwarnings(

61 "ignore", message=descoteaux07_legacy_msg,

62 category=PendingDeprecationWarning)

63 cmat = shore_matrix(radial_order, zeta, gtab)

64 S_reconst = np.dot(cmat, c_shore)

82 warnings.filterwarnings(

83 "ignore", message=descoteaux07_legacy_msg,

84 category=PendingDeprecationWarning)

85 pdf_discrete = asmfit.pdf_grid(17, 40e-3)

86 integral = pdf_discrete.sum()

headerid.py (https://gitlab.com/Haritiana/Python-Markdown) Python · 97 lines

75 warnings.warn(

76 'The HeaderId Extension is pending deprecation. Use the TOC Extension instead.',

77 PendingDeprecationWarning

78 )

79

exceptions.py (https://github.com/catalanojuan/celery.git) Python · 92 lines

16 "TimeoutError", "MaxRetriesExceededError",

17 "RetryTaskError", "TaskRevokedError",

18 "NotConfigured", "CPendingDeprecationWarning",

19 "CDeprecationWarning"]

20

85

86

87 class CPendingDeprecationWarning(PendingDeprecationWarning):

88 pass

89

util.py (https://github.com/HolodeckJizzmopper/bitHopper.git) Python · 110 lines

39 cls = DeprecationWarning

40 elif version == '1.3':

41 cls = PendingDeprecationWarning

42 else:

43 cls = DeprecationWarning

image.py (https://github.com/mozilla/moztrap-vendor-lib.git) Python · 154 lines

146 "Support for the PIL will be removed in Django 1.8. Please " +

147 "uninstall it & install Pillow instead.",

148 PendingDeprecationWarning

149 )

150

utils.py (https://github.com/enlaces/curso_python_dga_11.git) Python · 63 lines

20 import warnings

21 warnings.warn("security_hash is deprecated; use form_hmac instead",

22 PendingDeprecationWarning)

23 data = []

24 for bf in form:

utils.py (https://github.com/zodiak/django_ondev.git) Python · 165 lines

16 "The staticfiles.utils.get_files_for_app utility function is "

17 "deprecated. Use staticfiles.storage.AppStaticStorage.get_files "

18 "instead.", PendingDeprecationWarning)

19 return AppStaticStorage(app).get_files(ignore_patterns)

20

27 "The staticfiles.utils.get_app_prefix utility function is "

28 "deprecated. Use staticfiles.storage.AppStaticStorage.get_prefix "

29 "instead.", PendingDeprecationWarning)

30 return AppStaticStorage(app).get_prefix()

31

tests.py (https://github.com/niran/django-old.git) Python · 123 lines

56 def tearDown(self):

57 warnings.resetwarnings()

58 warnings.simplefilter('ignore', PendingDeprecationWarning)

59

60 def test_session_not_accessed(self):

test.py (https://github.com/theosp/google_appengine.git) Python · 40 lines

30 warnings.warn(

31 'Function-based test runners are deprecated. Test runners should be classes with a run_tests() method.',

32 PendingDeprecationWarning

33 )

34 failures = TestRunner(test_labels, verbosity=verbosity, interactive=interactive)

cz.py (https://github.com/blacktear23/django.git) Python · 105 lines

13 warnings.filterwarnings(

14 "ignore",

15 category=PendingDeprecationWarning,

16 module='django.contrib.localflavor.cz.forms'

17 )

exceptions.py (https://github.com/ayshih/sunpy.git) Python · 105 lines

9 __all__ = ["NoMapsInFileError",

10 "SunpyWarning", "SunpyUserWarning", "SunpyDeprecationWarning",

11 "SunpyPendingDeprecationWarning", "SunpyMetadataWarning",

12 "warn_user", "warn_deprecated", "warn_metadata"]

13

52

53

54 class SunpyPendingDeprecationWarning(PendingDeprecationWarning, SunpyWarning):

55 """

56 A warning class to indicate a soon-to-be deprecated feature.

context_processors.py (https://github.com/aruder77/applause.git) Python · 112 lines

77 "deprecated; use the path `django.contrib.staticfiles.context_processors.staticfiles` " \

78 "instead.",

79 PendingDeprecationWarning

80 )

81 from django.contrib.staticfiles.context_processors import staticfiles as staticfiles_context_processor

zip_loader.py (https://github.com/crass/app-engine-console.git) Python · 69 lines

62 warnings.warn(

63 "'zip_loader.load_template_source' is deprecated; use 'zip_loader.Loader' instead.",

64 PendingDeprecationWarning

65 )

66 return _loader.load_template_source(template_name, template_dirs)

services.py (https://gitlab.com/urbanjunglestudio/whambush-api) Python · 117 lines

83 'To use `allow_empty=False` style behavior, You should override '

84 '`get_queryset()` and explicitly raise a 404 on empty querysets.',

85 PendingDeprecationWarning

86 )

87 class_name = cls.__class__.__name__

edit.py (https://github.com/mozilla/moztrap-vendor-lib.git) Python · 280 lines

114 warnings.warn("Using ModelFormMixin (base class of %s) without "

115 "the 'fields' attribute is deprecated." % self.__class__.__name__,

116 PendingDeprecationWarning)

117

118 return model_forms.modelform_factory(model, fields=self.fields)

runtests.py (https://gitlab.com/asmjahid/opps) Python · 91 lines

44 warnings.simplefilter('default')

45 warnings.filterwarnings('error', category=DeprecationWarning)

46 for category in [PendingDeprecationWarning, UserWarning, ImportWarning]:

47 warnings.filterwarnings('ignore', category=category)

48

deprecations.py (https://bitbucket.org/stavrossk/maraschino.git) Python · 118 lines

17

18 def warn_pending_deprecation(msg, stacklevel=3):

19 warnings.warn(msg, exc.SAPendingDeprecationWarning, stacklevel=stacklevel)

20

21 def deprecated(version, message=None, add_deprecation_to_docstring=True):

77 def decorate(fn):

78 return _decorate_with_warning(

79 fn, exc.SAPendingDeprecationWarning,

80 message % dict(func=fn.__name__), header)

81 return decorate

warnings.py (https://gitlab.com/abhi1tb/build) Python · 61 lines

18

19 warnings.filterwarnings(

20 "ignore", category=sa_exc.SAPendingDeprecationWarning

21 )

22 warnings.filterwarnings("error", category=sa_exc.SADeprecationWarning)

test_reconst_csa_csd.py (https://github.com/arokem/dipy.git) Python · 137 lines

22 warnings.filterwarnings(

23 "ignore", message=descoteaux07_legacy_msg,

24 category=PendingDeprecationWarning)

25 reconst_flow_core(ReconstCSAFlow)

26

30 warnings.filterwarnings(

31 "ignore", message=descoteaux07_legacy_msg,

32 category=PendingDeprecationWarning)

33 reconst_flow_core(ReconstCSDFlow)

34

trans_null.py (https://github.com/lmorchard/home-snippets-server-lib.git) Python · 72 lines

60 '`django.utils.translation.get_date_formats` is deprecated. '

61 'Please update your code to use the new i18n aware formatting.',

62 PendingDeprecationWarning

63 )

64 return settings.DATE_FORMAT, settings.DATETIME_FORMAT, settings.TIME_FORMAT

68 '`django.utils.translation.get_partial_date_formats` is deprecated. '

69 'Please update your code to use the new i18n aware formatting.',

70 PendingDeprecationWarning

71 )

72 return settings.YEAR_MONTH_FORMAT, settings.MONTH_DAY_FORMAT

exceptions.py (https://github.com/mozilla/kuma-lib.git) Python · 100 lines

93

94

95 class CPendingDeprecationWarning(PendingDeprecationWarning):

96 pass

97

expandable_panel.py (https://github.com/enthought/pyface.git) Python · 168 lines

55 "in a future Pyface version, use create=False and explicitly "

56 "call create() for future behaviour",

57 PendingDeprecationWarning,

58 )

59 # ------------------------------------------------------------------------

reset.py (https://github.com/blacktear23/django.git) Python · 63 lines

25 warnings.warn(

26 'This command has been deprecated. The command ``flush`` can be used to delete everything. You can also use ALTER TABLE or DROP TABLE statements manually.',

27 PendingDeprecationWarning

28 )

29 using = options.get('database', DEFAULT_DB_ALIAS)

__init__.py (https://github.com/straup/recipes.git) Python · 93 lines

31 'args will be deprecated in version 2.6 and raise an error in version '

32 '2.7. See the Release Notes for Python-Markdown version 2.5 for more info.',

33 PendingDeprecationWarning)

34 # check for configs kwarg for backward compat.

35 if 'configs' in kwargs.keys():

40 '2.6 and raise an error in version 2.7. See the Release Notes for '

41 'Python-Markdown version 2.5 for more info.',

42 PendingDeprecationWarning)

43 # finally, use kwargs

44 self.setConfigs(kwargs)

exceptions.py (https://github.com/ionelmc/celery.git) Python · 162 lines

19 'TimeoutError', 'MaxRetriesExceededError', 'Retry',

20 'TaskRevokedError', 'NotConfigured', 'AlwaysEagerIgnored',

21 'InvalidTaskError', 'ChordError', 'CPendingDeprecationWarning',

22 'CDeprecationWarning', 'FixupWarning', 'DuplicateNodenameWarning',

23 'SoftTimeLimitExceeded', 'TimeLimitExceeded', 'WorkerLostError',

147

148

149 class CPendingDeprecationWarning(PendingDeprecationWarning):

150 pass

151

test_cross_validation.py (https://github.com/arokem/dipy.git) Python · 132 lines

81 warnings.filterwarnings(

82 "ignore", message=descoteaux07_legacy_msg,

83 category=PendingDeprecationWarning)

84 sm = csd.ConstrainedSphericalDeconvModel(gtab, response)

85 np.random.seed(12345)

88 warnings.filterwarnings(

89 "ignore", message=descoteaux07_legacy_msg,

90 category=PendingDeprecationWarning)

91 kf_xval = xval.kfold_xval(sm, S, 2, response, sh_order=2)

92 # Because of the regularization, COD is not going to be perfect here:

104 warnings.filterwarnings(

105 "ignore", message=descoteaux07_legacy_msg,

106 category=PendingDeprecationWarning)

107 kf_xval = xval.kfold_xval(sm, S, 2, response, sh_order=2,

108 mask=mask)

models.py (https://github.com/asavoy/django-model-utils.git) Python · 133 lines

32 "InheritanceCastModel is pending deprecation. "

33 "Use InheritanceManager instead.",

34 PendingDeprecationWarning,

35 stacklevel=2)

36 super(InheritanceCastModel, self).__init__(*args, **kwargs)

__init__.py (https://github.com/eric-brechemier/django.git) Python · 100 lines

23 if not hasattr(cls, "supports_object_permissions"):

24 warn("Authentication backends without a `supports_object_permissions` attribute are deprecated. Please define it in %s." % cls,

25 PendingDeprecationWarning)

26 cls.supports_object_permissions = False

27

28 if not hasattr(cls, 'supports_anonymous_user'):

29 warn("Authentication backends without a `supports_anonymous_user` attribute are deprecated. Please define it in %s." % cls,

30 PendingDeprecationWarning)

31 cls.supports_anonymous_user = False

32 return cls()

ExceptionHandlers.py (https://gitlab.com/SplatoonModdingHub/PTVS) Python · 176 lines

43 except OSError: pass

44 except OverflowError: pass

45 except PendingDeprecationWarning: pass

46 except ReferenceError: pass

47 except RuntimeError: pass

68

69 try: pass

70 except (ArithmeticError, AssertionError, AttributeError, BaseException, BufferError, BytesWarning, DeprecationWarning, EOFError, EnvironmentError, Exception, FloatingPointError, FutureWarning, GeneratorExit, IOError, ImportError, ImportWarning, IndentationError, IndexError, KeyError, KeyboardInterrupt, LookupError, MemoryError, NameError, NotImplementedError, OSError, OverflowError, PendingDeprecationWarning, ReferenceError, RuntimeError, RuntimeWarning, StandardError, StopIteration, SyntaxError, SyntaxWarning, SystemError, SystemExit, TabError, TypeError, UnboundLocalError, UnicodeDecodeError, UnicodeEncodeError, UnicodeError, UnicodeTranslateError, UnicodeWarning, UserWarning, ValueError, Warning, WindowsError, ZeroDivisionError): pass

71

72 try: pass

97 except OSError: pass

98 except OverflowError: pass

99 except PendingDeprecationWarning: pass

100 except ReferenceError: pass

101 except RuntimeError: pass

static.py (https://github.com/crisbar/curso_python_dga_11.git) Python · 41 lines

38 warnings.warn("The view at `django.views.static.serve` is deprecated; "

39 "use the path `django.contrib.staticfiles.views.serve` "

40 "instead.", PendingDeprecationWarning)

41 return staticfiles_serve(request, path, document_root, show_indexes, insecure)

42

views.py (https://github.com/emperorcezar/django-envelope.git) Python · 127 lines

111 with warnings.catch_warnings(record=True) as warns:

112 warnings.filterwarnings("always",

113 category=PendingDeprecationWarning)

114 self.client.get(self.url)

115 self.assertEqual(len(warns), 1)

test_prob_direction_getter.py (https://github.com/arokem/dipy.git) Python · 102 lines

37 warnings.filterwarnings(

38 "ignore", message=descoteaux07_legacy_msg,

39 category=PendingDeprecationWarning)

40 dg = ProbabilisticDirectionGetter.from_shcoeff(

41 fit.shm_coeff, 90, unit_octahedron)

69 warnings.filterwarnings(

70 "ignore", message=tournier07_legacy_msg,

71 category=PendingDeprecationWarning)

72

73 dg = ProbabilisticDirectionGetter.from_shcoeff(

__init__.py (https://github.com/mozilla/moztrap-vendor-lib.git) Python · 94 lines

7 from django.utils.importlib import import_module

8

9 warnings.warn("django.contrib.comments is deprecated and will be removed before Django 1.8.", PendingDeprecationWarning)

10

11 DEFAULT_COMMENTS_APP = 'django.contrib.comments'

utils.py (https://github.com/fccoelho/mayan.git) Python · 85 lines

47 warnings.warn(

48 "Short names for CONVERTER_BACKEND are deprecated; prepend with 'converter.backends.'",

49 PendingDeprecationWarning

50 )

51 return module

simplejson.py (https://github.com/theosp/google_appengine.git) Python · 31 lines

10 import warnings

11 warnings.warn("django.utils.simplejson is deprecated; use json instead.",

12 PendingDeprecationWarning)

13

14 try:

itercompat.py (https://github.com/theosp/google_appengine.git) Python · 46 lines

33 def product(*args, **kwds):

34 warnings.warn("django.utils.itercompat.product is deprecated; use the native version instead",

35 PendingDeprecationWarning)

36 return itertools.product(*args, **kwds)

37

__init__.py (https://github.com/mozilla/moztrap-vendor-lib.git) Python · 96 lines

50 def _backend(self):

51 warnings.warn("Accessing django.db.backend is deprecated.",

52 PendingDeprecationWarning, stacklevel=2)

53 return load_backend(connections[DEFAULT_DB_ALIAS].settings_dict['ENGINE'])

54

67 warnings.warn(

68 "close_connection is superseded by close_old_connections.",

69 PendingDeprecationWarning, stacklevel=2)

70 # Avoid circular imports

71 from django.db import transaction

test_node2vec.py (https://github.com/VHRanger/graph2vec.git) Python · 234 lines

19 wordsize = 32

20 # Gensim triggers deprecation warnings...

21 warnings.simplefilter("ignore", category=PendingDeprecationWarning)

22 warnings.simplefilter("ignore", category=DeprecationWarning)

23 g2v = nodevectors.Node2Vec(

tests.py (https://github.com/blacktear23/django.git) Python · 78 lines

31 def test_blank(self):

32 """

33 If blank, no PendingDeprecationWarning error will be raised, even though it

34 doesn't end in a slash.

35 """

50 def test_no_end_slash(self):

51 """

52 MEDIA_URL raises an PendingDeprecationWarning error if it doesn't end in a

53 slash.

54 """

55 import warnings

56 warnings.filterwarnings('error', 'If set, MEDIA_URL must end with a slash', PendingDeprecationWarning)

57

58 def setattr_settings(settings_module, attr, value):

builtins.py (https://gitlab.com/pierreEffiScience/TwitterClustering) Python · 125 lines

3 from __future__ import absolute_import

4

5 import imp # deprecated since 3.4; issues PendingDeprecationWarning in 3.5

6 import sys

7 import weakref

defaults.py (https://github.com/mozilla/moztrap-vendor-lib.git) Python · 91 lines

87 "django.views.defaults.shortcut will be removed in Django 1.8. "

88 "Import it from django.contrib.contenttypes.views instead.",

89 PendingDeprecationWarning, stacklevel=2)

90 from django.contrib.contenttypes.views import shortcut as real_shortcut

91 return real_shortcut(request, content_type_id, object_id)