DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Mercurial (cf424d6d4bb6)

VCS Links

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176
This file contains a list of bugs/possible improvements.

ToDo
----

* Time stamp input canonicalization 
  https://bugzilla.mozilla.org/show_bug.cgi?id=555442
  (See bottom of this file for useful supporting research info)
* Standardize submit format for time periods (idle, assignee_idle)
  Recall this note from the docs: "(Note: deadline implementation is 
  actually 'on or before' and 'on or after'; this may change, so be warned)."
* Better behaviour when Bugzilla times out
* Tests for bad logins
* From docs: "is_on_bug_entry: Boolean XXX currently custom fields only"
* Error codes; better error reporting
* POD? Look at Bugzilla for examples

Possible Additional Tests: 

* Custom field support on bug creation (test 26)
* Renumber test files to something more sensible
* Change creation test to create and check bug with UTF8 summary and fields
   Do a search for that bug and check summary is correct
* Check id returns from create calls
* UTF-8 in and out - bug data, e.g. summaries

Bugzilla Bugs:

* Review requests should be available as a feed
* (Shown by test 23) Boolean charts field names are not checked for validity

Bugzilla XML Changes:

* creation_ts in XML does not have accurate seconds (always 00) and therefore 
  you can't search using "=".
* Real names for attachment attachers, and other users
* number of votes

Bug to use for API testing on b.m.o. is bug 533750

Moving Database To Landfill
---------------------------

~/bin/dumpbzapi
(dumps the database and copies it to landfill)
On landfill:
mysqldrop bugs_bzapi
mysql -u bugs -p    
  create database bugs_bzapi;
mysql -u bugs -p bugs_bzapi < ~/bugs_3_4_bzapi-`date +%Y-%m-%d`.db

Release Process
---------------

New Installs:
cd /var/www
hg clone http://hg.mozilla.org/webtools/bzapi 0.3
cp -rp 0.3 landfill
cp -rp 0.3 test
# do conffiles, including changing logging location
# do webserver config

Release:
Update version number in UA string in lib/Bugzilla/API/Request.pm, line 289
Check docs
hg ci
hg push
Update api-dev machine's "latest" landfill install
Update other "latest" installs
Do webserver config 
  (duplicate stanzas in 'bzapi' and 'bzapi-ssl' and modify for new version no.)
Restart webserver
Run tests on landfill
  (watch out for timezone skew if you've moved database)
  Need to set STRIP_TIMES to 1 in t/lib/TestUtils.pm
Do some ad-hoc testing
hg tag BZAPI_X.Y_RELEASE
hg push
# in each install
hg pull
hg update -r BZAPI_X.Y_RELEASE
Update docs to point to frozen doc revisions
apache2ctl graceful
Announce release, including deprecations

Notes
-----

Translation hash documentation (Model/Utils.pm):

OLD2NEW - from Bugzilla's to ours
- Used to change field names in fixup_bug() - i.e. coming from XML _and_ CSV (which is the database)
  ** XML names -> API names
  ** CSV names (database names) -> API names
- Used to change attachment field names in fixup_xml_bug() too 
  (er... we have a separate hash!)
- Upgrading field names in Bug.pm history() - i.e. coming from the database

NEW2OLD - from ours to Bugzilla's
- Reversal of OLD2NEW
- Needs five hacks because mapping is not 1:1
- used in new2old() - returns conversion or what was passed in
  - used 3 times in Bug.pm update() 
    ** API names -> process_bug.cgi URL names
- used to downgrade field names in downgrade_search_url() 
    ** API names -> buglist.cgi URL names
- Used to downgrade field names in boolean charts in downgrade_search_url() 
    ** API names -> database field names

NEWTYPES2OLD
- Used to downgrade types in boolean charts in downgrade_search_url()
    ** API names -> query.cgi type names
    
OLDATTACH2NEW
- used to populate OLD2NEW with attachment-related stuff

NEWATTACH2OLD
- Reversal of OLDATTACH2NEW
- Needs two hacks because mapping is not 1:1
- Downgrading field names in Attachment.pm attachment2url()
    ** API names -> attachment.cgi URL names


Timestamps
----------

A history of timestamps in Bugzilla.

We store time values in MySQL DATETIMEs, which do not carry timezone information. They are therefore stored in the server timezone.

That means that if you change the timezone of a server, you change the actual values of its timestamps. This is why we need to disable date tests when running the built-in test suite against a copy of the database stored on a server whose timezone is not GMT. Or we need to account for it by getting the tests to adjust the times before comparison. The tests would need to know the timezone of the server.

Affected by time zone change on server, i.e. in server local time?
Time zone given?
Seconds accurate?

User acquired ability to change timezone in 3.4 (i.e. every supported version). Which fields does this affect, and when?

show_bug.cgi?ctype=xml
  bug creation_time
  bug last_change_time
  bug date/time custom field
  attachment creation_time
  attachment last_change_time since 3.6 (do we reflect this? not docced...)
  
  Acquired local_time in Bugzilla XXX

buglist.cgi?ctype=csv
  bug creation_time
  bug last_change_time
  bug date/time custom field

XML-RPC interface
  history change_time - in UTC instead of server since 3.6
  comment creation_time - in UTC instead of server since 3.6




Output:




Bug
  creation_time (source: XML)
  last_change_time (source: XML)
  
Comment
  creation_time (source: XML or XML-RPC)
  
ChangeSet
  change_time (source: XML-RPC)

Attachment
  creation_time (source: XML)