Migrating from protoRPC (Python 2.7 to Python 3) Google App engine

174 Views Asked by At

We have an Google app Engine py2.7 standard. We use cloud endpoint framework to make web apis. We also use protorpc to make serialization and deserialize data.

For example

@cloud_endpointapi.api_class(resource_name="validateteacherpin")    
class ValidateTeacherPin(remote.Service):   

    MULTIPLY_METHOD_RESOURCE = endpoints.ResourceContainer(API_Validate_Teacher_Pin_Request)

    @endpoints.method(MULTIPLY_METHOD_RESOURCE, 
        API_Validate_Teacher_Pin_Response,      
        http_method='POST',
        name='teacher.validateteacherpinentered')



from protorpc import messages
from protorpc import message_types
from protorpc import remote


class API_Validate_Teacher_Pin_Request(messages.Message):
    field_1    = messages.StringField(1)
    field_2    = messages.StringField(2)
    

We are now migrating the application to Python 3.7 in Google App engine standard. protorpc is not supported in Python 3.7. How do we migrate the code?

0

There are 0 best solutions below