Analyze Datasets and Train ML Models using AutoML week4 assignement giving error

when I am running the below code and getting error: TypeError: Descriptors cannot not be created directly.
If this call came from a _pb2.py file, your generated code is out of date and must be regenerated with protoc >= 3.19.0.
If you cannot immediately regenerate your protos, some other possible workarounds are:

  1. Downgrade the protobuf package to 3.20.x or lower.
  2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).

how to resolve this ?

code:

import boto3
import sagemaker
import pandas as pd
import numpy as np
import botocore

config = botocore.config.Config(user_agent_extra=‘dlai-pds/c1/w4’)

low-level service client of the boto3 session

sm = boto3.client(service_name=‘sagemaker’,
config=config)

sm_runtime = boto3.client(‘sagemaker-runtime’,
config=config)

sess = sagemaker.Session(sagemaker_client=sm,
sagemaker_runtime_client=sm_runtime)

bucket = sess.default_bucket()
role = sagemaker.get_execution_role()
region = sess.boto_region_name

I am getting same error for week 2, and week 3 assigment as well.

https://d-5cajjxdjgx4x.studio.us-east-1.sagemaker.aws/jupyter/default/lab/tree/C1_W2_Assignment.ipynb


I got the same error for Course 1 Week 3 Assignment.

Any luck solving this error?