Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UnhandledPromiseRejectionWarning error #30

Open
Kainar01 opened this issue Nov 6, 2020 · 2 comments
Open

UnhandledPromiseRejectionWarning error #30

Kainar01 opened this issue Nov 6, 2020 · 2 comments
Labels
bug Something isn't working

Comments

@Kainar01
Copy link

Kainar01 commented Nov 6, 2020

Description

  • What is the current behavior?
    After creating client and task, when task.applyAsync called, the UnhandledPromiseRejectionWarning error raises. It says "Error: connect ECONNREFUSED 127.0.0.1:5672", but my broker URL is pointing to cloudamqp instance.

  • What is the expected behavior?

In documentation, it is said that it should connect to broker_url, but it tries to connect to localhost on port 5672

  • Please tell us about your environment:

    • Version: Ubuntu 18.04
    • OS: linux
    • Language: Javascript
  • Other information (e.g. detailed explanation, stacktraces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow, gitter, etc)

@Kainar01 Kainar01 added the bug Something isn't working label Nov 6, 2020
@actumn
Copy link
Owner

actumn commented Nov 7, 2020

Hi!
Thank you for reporting the bug so clear.

But unfortunately, I couldn't reproduce the issue you described.
Can you share your codes that produce the problem?

@Juanpam
Copy link

Juanpam commented Aug 11, 2021

@actumn I'm also getting this same issue (MacOS). I did not specify a backend url. Maybe if it is not specified it is defaulting to localhost? (127.0.0.1).

Here is a bit of the code I'm using:

const celery = require('celery-node');
const config = require('../config');
const debug = require('debug')('project:celery');


debug(config);
const client = celery.createClient(
    config.celeryBroker,
);

client.isReady().then(() => {
    debug('Connected to Celery successfully');
}).catch(error => console.log('Got an error', error))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants