Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

1.2K
Views
No se puede conectar al servidor de postgres desde google colab usando psycopg2

sigo recibiendo errores al intentar conectarme a postgres desde google colab, sin embargo, en pycharm, este mismo código se conecta fácilmente al servidor. Aquí está el código:

 import psycopg2 params = { "host" : "localhost", "database" : "somedb", "user" : "postgres", "password" : "mypassword" } def connect(params): """ Connect to the PostgreSQL database server """ conn = None try: # connect to the PostgreSQL server print('Connecting to the PostgreSQL database...') conn = psycopg2.connect(**params) except (Exception, psycopg2.DatabaseError) as error: print(error) return conn connect(params)

errores que estoy recibiendo

 OperationalError: could not connect to server: Connection refused Is the server running on host "localhost" (127.0.0.1) and accepting TCP/IP connections on port 5432? could not connect to server: Cannot assign requested address Is the server running on host "localhost" (::1) and accepting TCP/IP connections on port 5432?
over 4 years ago · Santiago Trujillo
1 answers
Answer question

0

Asegúrese de haber incluido en la lista de direcciones IP permitidas en su servidor PostgreSQL: 34.0.0.0/8 y 35.0.0.0/8, que son las direcciones de Google Colab.

over 4 years ago · Santiago Trujillo Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!