Sample code for 30+ languages & platforms
CkPython Requires Chilkat v11.0.0+

Transition from Cert.GetCertChain to Cert.BuildCertChain

Provides instructions for replacing deprecated GetCertChain method calls with BuildCertChain.

Chilkat CkPython Downloads

CkPython
import sys
import chilkat

success = False

cert = chilkat.CkCert()

#  ------------------------------------------------------------------------
#  The GetCertChain method is deprecated:

# certchainObj is a CkCertChain
certchainObj = cert.GetCertChain()
if (cert.get_LastMethodSuccess() == False):
    print(cert.lastErrorText())
    sys.exit()

#  ...
#  ...

#  ------------------------------------------------------------------------
#  Do the equivalent using BuildCertChain.
#  Your application creates a new, empty CertChain object which is passed 
#  in the last argument and filled upon success.

certchainOut = chilkat.CkCertChain()
success = cert.BuildCertChain(certchainOut)
if (success == False):
    print(cert.lastErrorText())
    sys.exit()