Contributing
XXX: This page is not complete
How to contribute to !OpenRPG
These are some common tasks you can execute to help OpenRPG: Fix a bug marked as new an not assigned to anyone. Verify the validity of the patch submitted in a ticket marked as ready to test. * Submit a new Ticket, if you have found a new bug.
Create a Ticket
Still to write
Fix a Ticket
Here will be explained how to Fix an opened Ticket.
Choose a Ticket
Go to the Tickets Page, and pick up a ticket marked as NEW and not assigned to anyone. Reassign it to you, so other developers will know that someone else is already working on that issue and they won't try to fix it.
Reproduce the Bug
Once you have read the ticket carefully you have to reproduce the bug on a new copy of the !OpenRPG's repo:
$ hg clone http://hg.assembla.com/openrpg ticket-25
$ cd ticket-25
$ python start_noupdate.py
Where ticket-25 is the name of the directory in which the repo will be cloned. You should replace 25 with the number of the ticket you are fixing.
Can't reproduce the Bug
If you can't reproduce the bug on your system you can: mark it as invalid if you are using the same os of the bug reporter. reply to the ticket writing that the bug doesn't exists on your OS if your OS is different from the reporter's one.
In the latter case you should execute system_check.py and include in the reply your system info:
$ python system_check.py
This will create an openrpg_sysinfo.txt in the current directory. Open it and copy the content to your reply. Do not upload it as an attachment!
The Bug is valid
If you have succesfully reproduced the bug on your system, you can proceed and fix it. You can edit the code without fear, if you do something wrong you can just re-clone the repo.
Create the Patch
Once you have finished editing and possibly fixed the bug, you have to create a patch file to attach to the ticket.
First commit your changes to your local copy of the repo:
$ hg commit -m "fixed ticket 25: a short description of what you have done"
Replace 25 with the number of the ticket you have fixed.
And then export the changeset you have just created:
$ hg export -o ticket-25-%h tip
You will find a file named ticket-25-*, where * stands for 12 hexadecimal characters. This is your patch! upload it as an attachment to the ticket and mark it as ready to test. You should also sumbit a reply writing what you have done.
Wait for approvation
Now you have to wait until someone tests your patch and closes the ticket.
Test a Ticket
Here will be explained how to close a ticket marked as ready to test.
Choose a Ticket
Go to the Tickets Page, and pick up a ticket marked as ready to test. If a Ticket is marked as ready to test it has been probably already fixed by someone else, who should have attached a patch to the ticket. All you have to do is download the patch and test it on your system, to ensure that the bug has been really fixed.
Clone the Repo
First we get a new copy of the !OpenRPG's repo:
$ hg clone http://hg.assembla.com/openrpg ticket-33
$ cd ticket-33
Import the Patch
Then we can import the patch in:
$ hg import http://assembla.com/url-to-the-patch/
or, if you dowloaded the patch manually to your hd, write the path:
$ hg import /path/to/the/patch
on windows:
$ hg import C:\path\to\the\patch
Test it
Now run openrpg to test if the patch works:
$ python start_noupdate.py
If you think the patch worked correctly, you can close the ticket as fixed. Note: you have to read the code of the patch before closing the ticket.