

def react_context_processor(request):
    """Expose a global list of react components to be processed"""
    print("react_context_processor is no longer required.")

    return {
        'REACT_COMPONENTS': [],
    }


import warnings


def react_context_processor(request):
    """Expose a global list of react components to be processed"""
    warnings.warn(
        "react_context_processor is no longer required.", DeprecationWarning
    )

    return {
        'REACT_COMPONENTS': [],
    }

Replace warning message with deprecation warning
Replace warning message with deprecation warning

+ 
+ import warnings
  
  
  def react_context_processor(request):
      """Expose a global list of react components to be processed"""
+     warnings.warn(
-     print("react_context_processor is no longer required.")
+         "react_context_processor is no longer required.", DeprecationWarning
+     )
  
      return {
          'REACT_COMPONENTS': [],
      }
  
Replace warning message with deprecation warning
## Code Before:


def react_context_processor(request):
    """Expose a global list of react components to be processed"""
    print("react_context_processor is no longer required.")

    return {
        'REACT_COMPONENTS': [],
    }

## Instruction:
Replace warning message with deprecation warning
## Code After:

import warnings


def react_context_processor(request):
    """Expose a global list of react components to be processed"""
    warnings.warn(
        "react_context_processor is no longer required.", DeprecationWarning
    )

    return {
        'REACT_COMPONENTS': [],
    }
