Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.
 

Trac integration 502 error


#1

Hi,

I’ve been trying to set up TestRail’s Defect Plugin with our Trac.

I’m assured by our sysadmin that XML-RPC is installed (& from the look of this post I’d get a 404 if it wasn’t) but whenever I hover over a defect, or click ‘Push’ within Add Test Result I get the error:

Plugin “Trac” returned an error: Invalid HTTP code (502)

The Defect View, & Add Urls both work, details of each below:

Defect View Url (works)

http://trac.domain.local/project/ticket/%id%

Defect Add Url (works)

http://trac.domain.local/project/newticket

Defect Plugin (doesn’t work)

; Please configure your Trac connection below
[connection]
address=http://trac.domain.local/project/
user=%domain_username%
password=%domain_password%

This is being set up in within the Defects tab of Edit Project, as we have separate Trac instances for each project, & therefore the global integration settings would not be appropriate.

I’m slightly at a loss, & any pointers in the right direction would be appreciated.

As a last point; in the global integration settings I have set up the user, & password User Variables, though these do not appear to be displayed on the Edit Project page.

Thanks,
Paul.


#2

Hi Paul,

Thanks for your posting. I assume you are using a TestRail Cloud/Hosted instance, is this correct?

The problem is that you are trying to connect from a TestRail Cloud account to a Trac installation on your private network. For the full push/lookup integration TestRail needs to be able to connect to your defect tracker. If this is installed on your private server behind a firewall, then such a connection isn’t possible by default. To use the full integration, you would have the following options:

  • Make your defect tracker available for connections over the Internet (I recommend talking to your IT team for this; we can also provide the IP addresses of our servers so you only need to approve our IPs for connections)

  • You can also install TestRail on your own local server and we can provide the necessary details for this

  • If you just want to try the full integration for now, you could maybe also temporarily set up a hosted trial version of your bug tracker (or a different issue tracker such as JIRA) just to try the integration

I hope this helps!

Regards,
Tobias


#3

Hi Tobias,

Yes, that’s correct. I read your first paragraph & went “dammit” as that’s clearly the problem.

The connection the plugin was trying isn’t actually possible to the domain.local at all - however we also have domain.com open which accepts authenticated requests.

I’ve changed this over & it’s now working.

Thanks for your reply though, got me in the right direction.

Thanks,
Paul.


#4

I am having the same issue. Why can’t I add exception on my firewall for your servers?


#5

Hello @zaherrkamal.

You can definitely allow connections from our servers in your firewall. Many of our customers are using this approach. Feel free to email us at contact@gurock.com for a list of IP addresses we use for such outgoing integration connections.

Thanks,
Dennis