Ticket #625 (assigned enhancement)

Opened 2 years ago

Last modified 1 year ago

Integrate Trac tickets with Perforce jobs

Reported by: lewisbaker Assigned to: ttressieres (accepted)
Priority: normal Component: PerforcePlugin
Severity: normal Keywords:
Cc: Trac Release: 0.10

Description

It would be quite useful to be able to replicate ticket information from Trac in Perforce's builtin jobs so that developers can use the standard p4 command line tools to:

  • update ticket information (p4 jobs)
  • associate changes with tickets (p4 fix)
  • query whether the fix for a ticket is present on a specified branch (p4 fixes)

Perforce already supports altering the status of a job when an associated change is submitted. Hooking into this would reduce the need for developers to remember to enter information in two different systems (Trac and Perforce).

Attachments

__init__.py (1.5 kB) - added by ttressieres on 12/08/06 08:55:47.
init file of PyPerforce? patch
objects.py (30.5 kB) - added by ttressieres on 12/08/06 08:56:11.
objects.py file of PyPerforce? patch

Change History

10/28/06 04:26:18 changed by ttressieres

  • owner changed from lewisbaker to anonymous.
  • release changed from 0.9 to 0.10.
  • status changed from new to assigned.

i'm near from a solution

10/28/06 04:26:38 changed by ttressieres

  • owner changed from anonymous to ttressieres.
  • status changed from assigned to new.

10/28/06 16:09:55 changed by ttressieres

see first version here

(follow-up: ↓ 5 ) 11/02/06 02:56:14 changed by ttressieres

  • status changed from new to assigned.

(in reply to: ↑ 4 ) 12/08/06 07:02:05 changed by ybrygas@softservecom.com

Replying to ttressieres:
Hi.
I've tried to use this scripts and I've been expiriencing some problem. I've got this error while running this script:

Traceback (most recent call last):
  File "p4_trac_jobs.py", line 415, in ?
    ticket.mainLoop()
  File "p4_trac_jobs.py", line 380, in mainLoop
    self.tktperforce.updateTicket(p, self.mergedTickets[p])
  File "p4_trac_jobs.py", line 183, in updateTicket
    job = perforce.Job(self.p4, jobname)
AttributeError: 'module' object has no attribute 'Job'

It seems to me this error is related to this words:

Requirements

You can find this requirements here: http://trac-hacks.org/wiki/PerforceJobScript

I dont know where I should get this patch for jobs. Maybe I'm not right with this idea about PyPerforce? patch, so tell me please what wrong with this script.

P.S.

My configuration:

12/08/06 08:55:00 changed by ttressieres

Hi, I've sent a mail to lewis baker to update the PyPerforce? library. But by now it is not available, so i will attach the two files necessary for this script.

12/08/06 08:55:47 changed by ttressieres

  • attachment __init__.py added.

init file of PyPerforce? patch

12/08/06 08:56:11 changed by ttressieres

  • attachment objects.py added.

objects.py file of PyPerforce? patch

07/19/07 04:49:28 changed by lewisbaker

The trunk of PyPerforce now has these changes integrated.

There is also a fix for the "'p4 jobs' outputs 2nd and subsequent jobs to 'records' instead of 'forms'" issue in there.

07/19/07 07:14:39 changed by lewisbaker

I would like to have a look at the new P4 Defect Tracking Gateway to see how easy it is to implement using that framework. It seems that a lot of the hard work might already be done by Perforce.


Add/Change #625 (Integrate Trac tickets with Perforce jobs)




Change Properties
Action