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

Asana Trigger doesn't work #8403

Closed
johanndrews opened this issue Jan 22, 2024 · 20 comments
Closed

Asana Trigger doesn't work #8403

johanndrews opened this issue Jan 22, 2024 · 20 comments
Assignees
Labels

Comments

@johanndrews
Copy link

johanndrews commented Jan 22, 2024

Describe the bug
Since Asana started to rollout their infrastructure (CDN) update, we are unable to use the asana trigger and asana node.

To Reproduce
We noticed first, that the workflows doesn't run, with permissions errors just on GET request on Task ID. But, have opened the task with the same id within the web, the user has access to it.

After some research, I came across this Forum entry in the Asana Forum:
https://forum.asana.com/t/change-infrastructure-cdn-rollout-and-potential-new-400-403-errors/641280
And, they started rollout on 19th, and exactly before, it worked, and now not.

If I want to activate the trigger, it throws me an:

The request could not be satisfied 403 ERROR The request could not be satisfied. Bad request. We can't connect to the server for this app or website at this time. There might be too much traffic or a configuration error. Try again later, or contact the app or website owner.
If you provide content to customers through CloudFront, you can find steps to troubleshoot and help prevent this error by reviewing the CloudFront documentation.
Generated by cloudfront (CloudFront) Request ID: XXXXX

And I can see, that you have made already some changes, but it seems something still is wrong:
#8057

Expected behavior
I activate the workflow, and through the Asana Trigger node, the Webhook is registered at the Asana API.

Environment (please complete the following information):

  • OS: Ubuntu 20.04.6
  • n8n Version 1.24.1
  • Node.js Version v18.18.2
  • Database system SQLite
  • Operation mode main
@ttheuerkauf
Copy link

Same problem here since last friday.

OS: Ubuntu 20.04.5 LTS
n8n Version 1.24.1
Node.js v20.11.0
Database MySQL

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

Hey @johanndrews,

Thanks for the report I have just taken a look at the post you shared and it looks like while some changes were made the url was not changed to the new endpoint which could be causing the issue.

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

Hey @johanndrews & @ttheuerkauf,

I have just put in a fix for this and tested it locally. Once reviewed we can get it merged in and released, If we end up doing a 1.25.1 patch I will make sure we include this but as a temporary solution if needed for a couple of days I can create a docker build you can use based on that PR.

@johanndrews
Copy link
Author

sounds awesome, would be happy to use it.

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

Hey @johanndrews,

You will be able to use n8nio/n8n:PR-8404-gh-8403 as the image, It is only availble for amd64 (pretty much anything that isn't a Pi or an Mx Mac).

As a warning this is built on top of the latest codebase and while there shouldn't be any bugs there is potential for something to be hiding that we are not aware of so think of it as a beta for now until we do a proper release containing the fix.

@ttheuerkauf
Copy link

Hi @Joffcom,

thank you very much for your fast response. :-)

Can you give a hint how long it will take until the new release is ready?

The error occurred here when disabling and enabling a flow, which also happens at restart of n8n. Because of this, I think this should get a high priority.

Unfortunately, we do not use docker and have to wait until released.

Best regards! :-)

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

@ttheuerkauf The fix is in so it all depends on if we need to fix anything else from the weekend, If we do release a 1.25.1 it would likely be later today otherwise it would be a 1.26.0 release which would be Wednesday which would be too late for most people.

As you are using npm you could run from source instead by pulling down the code and cheking out the branch in the PR and running that but generally I would always recommend running n8n in a container.

I have raised the question internally to see what the plans are and I will let you know when I hear back.

@johanndrews
Copy link
Author

johanndrews commented Jan 22, 2024

Maybe I did something wrong.
I tried running:

sudo docker-compose stop
docker pull n8nio/n8n:PR-8404-gh-8403
sudo docker-compose up -d

while I get the confirmation, that it has worked:

PR-8404-gh-8403: Pulling from n8nio/n8n
96526aa774ef: Already exists
e5c6f827c015: Already exists
e2c1ecea9632: Already exists
adf638b6ca51: Already exists
4f4fb700ef54: Already exists
880cafa468cd: Already exists
a52bb9d2d26b: Already exists
316ac24beaf8: Pull complete
997471975c0c: Pull complete
36d045e0ef88: Pull complete
a75c0219296b: Pull complete
Digest: sha256:d6fc591a6d92917ca2794b6abcc0db5941864fa04ea6e0072a48dbd28bc201b3
Status: Downloaded newer image for n8nio/n8n:PR-8404-gh-8403
docker.io/n8nio/n8n:PR-8404-gh-8403

The same error still occurs while trying to activate the workflow.

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

Hey @johanndrews,

That should do it, It is a bit worrying though as when I gave it a test it was working 🤔 is the normal node working for you?

@johanndrews
Copy link
Author

image

I have the need of registering many projects with the Asana Trigger Node, and then I forward it to an centralized workflow, that do the same for the different projects. You can see in the screenshot.

If I try to activate this workflow, I get the error.

And, I just tried to test an workflow with using just a simple GET Task on a given ID, the same error.

Maybe, depending where you are located, you are not making your requests against the CDN Route?

You can recheck that by making requests to https://cdn.app.asana.com/api/1.0/ as your API base URL instead of https://app.asana.com/api/1.0/ - as you can see in the Asana Forum Topic. Then you can get sure, that you do the request to the new CDN route.

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

Hey @johanndrews,

I have just done another test using the cdn url and it is ok for me as the first time I didn't and being UK based it would have used the old path. As far as I can tell though this appears to be working with the change so there could be something else.

image

Request

{
  method: 'GET',
  qs: { workspace: '1177253494675264', limit: 100 },
  url: 'https://cdn.app.asana.com/api/1.0/projects',
  json: true
}

Can you share the Cloudflare id you get back and I can see if I can get in touch with someone at Asana to check it.

@ttheuerkauf
Copy link

Hi @Joffcom,

I just want to add something, because of your screenshot. The problem occurs here especially with the Asana-Trigger node when retrieving Workspaces:

grafik

You use another node in your screenshot. I didn't test, but maybe only this operation is wrong, before the trigger node applies the hook to asana?

@johanndrews
Copy link
Author

One example is:
(CloudFront) Request ID: bbRob9T6KTsszdcg8CkJskI4LqfVPo-khRWUPEycGPyLjGuduJ7OMA==

I'm note super familiar with node.js: If I exec the docker container, where I can find the files of the asana node? So, maybe I can quickfix it and change the URL to the deprecated, but the worflows would work.

@ttheuerkauf if you try to use a simple Asana Node, with an GET on a task id, you would also get the same issue. But yes, the Trigger is the base to run the workflows :) As they register the webhooks at Asana.

@ttheuerkauf
Copy link

ttheuerkauf commented Jan 22, 2024

Ah ok, I checked our workflows and we only use the asana trigger node and no other Asana nodes.

For all other calls of the Asana API we use the HTTP Request node and build the queries manually. I think when building the flows some Asana operations were missing. Anyway, these manual calls are working fine.

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

Hey @ttheuerkauf,

I had also checked with the trigger node, Looking at it though maybe your container is not using the new image.Just noticed you are using compose... Did you update your compose file as well to use the new image?

We are in the process of releasing 1.25.1 now as well.

@ttheuerkauf
Copy link

Hi @Joffcom ,

as written, we do not use docker at the moment. @johanndrews does :-).

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

Hey @ttheuerkauf,

My mistake I tagged the wrong user, 1.25.1 is now available on NPM if you wanted to update.

@janober
Copy link
Member

janober commented Jan 22, 2024

Fix got released with n8n@1.25.1

@johanndrews
Copy link
Author

johanndrews commented Jan 22, 2024

I did the npm install n8n@next - but got the 1.25.0 😅
So, for others, that need to do this:
run npm install n8n@1.25.1

For the docker users:
You can run
docker exec -u root -it n8n_n8n_1 sh
to enter the docker container
within the container you run npm install n8n@1.25.1
After this, you can exit the container again by using exit
After this, you need to restart the docker container (or it was my way of solving this 😅)
First stop the container: sudo docker-compose stop
And start again sudo docker-compose up -d - like you would do it to update n8n regularly, just leave out the docker pull.

Now, everything is working 🎉 Thank you for the quick solution and support - awesome team!

@Joffcom
Copy link
Member

Joffcom commented Jan 22, 2024

⚠️ DO NOT FOLLOW THOSE DOCKER STEPS ⚠️
For Docker / Docker Compose all you need to do is change the image you are using to docker.n8n.io/n8nio/n8n:1.25.1 so for Docker run this would be something like...

docker run -it --rm --name n8n -p 5678:5678 -v n8n_data:/home/node/.n8n docker.n8n.io/n8nio/n8n:1.25.1

And for Docker Compose this would be be

version: "3.7"

services:
  n8n:
    image: docker.n8n.io/n8nio/n8n:1.25.1
    restart: always
    ports:
      - "127.0.0.1:5678:5678"
    environment:
      - N8N_HOST=${SUBDOMAIN}.${DOMAIN_NAME}
      - N8N_PORT=5678
      - N8N_PROTOCOL=https
      - NODE_ENV=production
      - WEBHOOK_URL=https://${SUBDOMAIN}.${DOMAIN_NAME}/
      - GENERIC_TIMEZONE=${GENERIC_TIMEZONE}
    volumes:
      - n8n_data:/home/node/.n8n

volumes:
  n8n_data:
    external: true

We also updated the next docker image to use 1.25.1 so you can also replace the version with that instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants