Skip to content

Commit

Permalink
Replace deprecated .warn method with .warning (#807)
Browse files Browse the repository at this point in the history
- `logging.Logger.warn()` has been deprecated since Python 3.3 and
will not be available in Python 3.13 as per this pull request
(python/cpython#105377).

Co-authored-by: Lewis M. Kabui <lewisemm@users.noreply.github.com>
  • Loading branch information
lewisemm and lewisemm authored Jan 15, 2024
1 parent 14b6d2c commit 2018c11
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pipeline/templatetags/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def render(self, context):
package = self.package_for(package_name, "css")
except PackageNotFound:
w = "Package %r is unknown. Check PIPELINE['STYLESHEETS'] in your settings."
logger.warn(w, package_name)
logger.warning(w, package_name)
# fail silently, do not return anything if an invalid group is specified
return ""
return self.render_compressed(package, package_name, "css")
Expand Down Expand Up @@ -168,7 +168,7 @@ def render(self, context):
package = self.package_for(package_name, "js")
except PackageNotFound:
w = "Package %r is unknown. Check PIPELINE['JAVASCRIPT'] in your settings."
logger.warn(w, package_name)
logger.warning(w, package_name)
# fail silently, do not return anything if an invalid group is specified
return ""
return self.render_compressed(package, package_name, "js")
Expand Down

0 comments on commit 2018c11

Please sign in to comment.