This repository was archived by the owner on Mar 9, 2026. It is now read-only.
Description Environment details
OS type and version: MacOS 10.15.7
pipenv version: pipenv, version 2020.11.15
google-cloud-pubsub version: 2.3.0
docker Docker version 20.10.2, build 2291f61
Pubsub emulator image: google/cloud-sdk:327.0.0-emulators
# ./Pipfile
[[source]]
url = "https://pypi.org/simple"
verify_ssl = true
name = "pypi"
[packages]
google-cloud-pubsub = "*"
[dev-packages]
watchgod = "*"
autopep8 = "*"
pytest = "*"
[requires]
python_version = "3.8"
# ./.env
PUBSUB_EMULATOR_HOST="localhost:8087"
PUBSUB_PROJECT_ID="myproject"
Steps to reproduce
start local emulator with docker
❯ docker run --rm --name local-pubsub-emulator -p 8087:8087 google/cloud-sdk:327.0.0-emulators gcloud beta emulators pubsub start --project=myproject --host-port=0.0.0.0:8087
run create topic script
❯ pipenv run python ./create.py
Code example
# ./create.py
def create_topic (project_id , topic_id ):
"""Create a new Pub/Sub topic."""
from google .cloud import pubsub_v1
import os
publisher = pubsub_v1 .PublisherClient ()
topic_path = publisher .topic_path (project_id , topic_id )
topic = publisher .create_topic (request = {"name" : topic_path })
print ("Created topic: {}" .format (topic .name ))
if __name__ == '__main__' :
print ('try to create a topic...' )
create_topic ('myproject' , 'mytopic' )
Stack trace
❯ pipenv run python ./create.py
Loading .env environment variables...
try to create a topic...
E0210 15:39:00.548809000 4527218112 ssl_transport_security.cc:1458] Handshake failed with fatal error SSL_ERROR_SSL: error:100000f7:SSL routines:OPENSSL_internal:WRONG_VERSION_NUMBER.
E0210 15:39:00.556706000 4527218112 ssl_transport_security.cc:1458] Handshake failed with fatal error SSL_ERROR_SSL: error:100000f7:SSL routines:OPENSSL_internal:WRONG_VERSION_NUMBER.
E0210 15:39:01.966730000 4527218112 ssl_transport_security.cc:1458] Handshake failed with fatal error SSL_ERROR_SSL: error:100000f7:SSL routines:OPENSSL_internal:WRONG_VERSION_NUMBER.
...
Workaround
Downgrade to google-cloud-pubsub~=2.2.0 and everything works fine.
❯ pipenv run python ./create.py
Loading .env environment variables...
try to create a topic...
Created topic: projects/myproject/topics/mytopic
Reactions are currently unavailable
Environment details
google-cloud-pubsubversion: 2.3.0Steps to reproduce
Code example
Stack trace
Workaround
Downgrade to
google-cloud-pubsub~=2.2.0and everything works fine.