<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[14520] CalendarServer/branches/users/cdaboo/pod2pod-migration</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.calendarserver.org//changeset/14520">14520</a></dd>
<dt>Author</dt> <dd>cdaboo@apple.com</dd>
<dt>Date</dt> <dd>2015-03-06 13:20:35 -0800 (Fri, 06 Mar 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>Merge from trunk.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#CalendarServerbranchesuserscdaboopod2podmigrationtxdavbasedatastoresubpostgrespy">CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/base/datastore/subpostgres.py</a></li>
<li><a href="#CalendarServerbranchesuserscdaboopod2podmigrationtxdavcommondatastorepoddingsharing_invitespy">CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/podding/sharing_invites.py</a></li>
<li><a href="#CalendarServerbranchesuserscdaboopod2podmigrationtxdavcommondatastoretesttest_sqlpy">CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/test/test_sql.py</a></li>
<li><a href="#CalendarServerbranchesuserscdaboopod2podmigrationtxdavcommondatastoretestutilpy">CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/test/util.py</a></li>
</ul>

<h3>Property Changed</h3>
<ul>
<li><a href="#CalendarServerbranchesuserscdaboopod2podmigration">CalendarServer/branches/users/cdaboo/pod2pod-migration/</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="CalendarServerbranchesuserscdaboopod2podmigration"></a>
<div class="propset"><h4>Property changes: CalendarServer/branches/users/cdaboo/pod2pod-migration</h4>
<pre class="diff"><span>
</span></pre></div>
<a id="svnmergeinfo"></a>
<div class="modfile"><h4>Modified: svn:mergeinfo</h4></div>
<span class="cx">/CalendarServer/branches/config-separation:4379-4443
</span><span class="cx">/CalendarServer/branches/egg-info-351:4589-4625
</span><span class="cx">/CalendarServer/branches/generic-sqlstore:6167-6191
</span><span class="cx">/CalendarServer/branches/new-store:5594-5934
</span><span class="cx">/CalendarServer/branches/new-store-no-caldavfile:5911-5935
</span><span class="cx">/CalendarServer/branches/new-store-no-caldavfile-2:5936-5981
</span><span class="cx">/CalendarServer/branches/release/CalendarServer-4.3-dev:10180-10190,10192
</span><span class="cx">/CalendarServer/branches/release/CalendarServer-5.1-dev:11846
</span><span class="cx">/CalendarServer/branches/release/CalendarServer-5.2-dev:11972,12357-12358,12794,12814
</span><span class="cx">/CalendarServer/branches/users/cdaboo/batchupload-6699:6700-7198
</span><span class="cx">/CalendarServer/branches/users/cdaboo/cached-subscription-calendars-5692:5693-5702
</span><span class="cx">/CalendarServer/branches/users/cdaboo/component-set-fixes:8130-8346
</span><span class="cx">/CalendarServer/branches/users/cdaboo/cross-pod-sharing:12038-12191
</span><span class="cx">/CalendarServer/branches/users/cdaboo/directory-cache-on-demand-3627:3628-3644
</span><span class="cx">/CalendarServer/branches/users/cdaboo/fix-no-ischedule:11607-11871
</span><span class="cx">/CalendarServer/branches/users/cdaboo/implicituidrace:8137-8141
</span><span class="cx">/CalendarServer/branches/users/cdaboo/ischedule-dkim:9747-9979
</span><span class="cx">/CalendarServer/branches/users/cdaboo/json:11622-11912
</span><span class="cx">/CalendarServer/branches/users/cdaboo/managed-attachments:9985-10145
</span><span class="cx">/CalendarServer/branches/users/cdaboo/more-sharing-5591:5592-5601
</span><span class="cx">/CalendarServer/branches/users/cdaboo/partition-4464:4465-4957
</span><span class="cx">/CalendarServer/branches/users/cdaboo/performance-tweaks:11824-11836
</span><span class="cx">/CalendarServer/branches/users/cdaboo/pods:7297-7377
</span><span class="cx">/CalendarServer/branches/users/cdaboo/pycalendar:7085-7206
</span><span class="cx">/CalendarServer/branches/users/cdaboo/pycard:7227-7237
</span><span class="cx">/CalendarServer/branches/users/cdaboo/queued-attendee-refreshes:7740-8287
</span><span class="cx">/CalendarServer/branches/users/cdaboo/relative-config-paths-5070:5071-5105
</span><span class="cx">/CalendarServer/branches/users/cdaboo/reverse-proxy-pods:11875-11900
</span><span class="cx">/CalendarServer/branches/users/cdaboo/scheduling-queue-refresh:11783-12557
</span><span class="cx">/CalendarServer/branches/users/cdaboo/shared-calendars-5187:5188-5440
</span><span class="cx">/CalendarServer/branches/users/cdaboo/sharing-in-the-store:11935-12016
</span><span class="cx">/CalendarServer/branches/users/cdaboo/store-scheduling:10876-11129
</span><span class="cx">/CalendarServer/branches/users/cdaboo/timezones:7443-7699
</span><span class="cx">/CalendarServer/branches/users/cdaboo/txn-debugging:8730-8743
</span><span class="cx">/CalendarServer/branches/users/gaya/cleanrevisions:12152-12334
</span><span class="cx">/CalendarServer/branches/users/gaya/groupsharee2:13669-13773
</span><span class="cx">/CalendarServer/branches/users/gaya/sharedgroupfixes:12120-12142
</span><span class="cx">/CalendarServer/branches/users/gaya/sharedgroups-3:11088-11204
</span><span class="cx">/CalendarServer/branches/users/glyph/always-abort-txn-on-error:9958-9969
</span><span class="cx">/CalendarServer/branches/users/glyph/case-insensitive-uid:8772-8805
</span><span class="cx">/CalendarServer/branches/users/glyph/conn-limit:6574-6577
</span><span class="cx">/CalendarServer/branches/users/glyph/contacts-server-merge:4971-5080
</span><span class="cx">/CalendarServer/branches/users/glyph/dalify:6932-7023
</span><span class="cx">/CalendarServer/branches/users/glyph/db-reconnect:6824-6876
</span><span class="cx">/CalendarServer/branches/users/glyph/deploybuild:7563-7572
</span><span class="cx">/CalendarServer/branches/users/glyph/digest-auth-redux:10624-10635
</span><span class="cx">/CalendarServer/branches/users/glyph/disable-quota:7718-7727
</span><span class="cx">/CalendarServer/branches/users/glyph/dont-start-postgres:6592-6614
</span><span class="cx">/CalendarServer/branches/users/glyph/enforce-max-requests:11640-11643
</span><span class="cx">/CalendarServer/branches/users/glyph/hang-fix:11465-11491
</span><span class="cx">/CalendarServer/branches/users/glyph/imip-and-admin-html:7866-7984
</span><span class="cx">/CalendarServer/branches/users/glyph/ipv6-client:9054-9105
</span><span class="cx">/CalendarServer/branches/users/glyph/launchd-wrapper-bis:11413-11436
</span><span class="cx">/CalendarServer/branches/users/glyph/linux-tests:6893-6900
</span><span class="cx">/CalendarServer/branches/users/glyph/log-cleanups:11691-11731
</span><span class="cx">/CalendarServer/branches/users/glyph/migrate-merge:8690-8713
</span><span class="cx">/CalendarServer/branches/users/glyph/misc-portability-fixes:7365-7374
</span><span class="cx">/CalendarServer/branches/users/glyph/more-deferreds-6:6322-6368
</span><span class="cx">/CalendarServer/branches/users/glyph/more-deferreds-7:6369-6445
</span><span class="cx">/CalendarServer/branches/users/glyph/multiget-delete:8321-8330
</span><span class="cx">/CalendarServer/branches/users/glyph/new-export:7444-7485
</span><span class="cx">/CalendarServer/branches/users/glyph/one-home-list-api:10048-10073
</span><span class="cx">/CalendarServer/branches/users/glyph/oracle:7106-7155
</span><span class="cx">/CalendarServer/branches/users/glyph/oracle-nulls:7340-7351
</span><span class="cx">/CalendarServer/branches/users/glyph/other-html:8062-8091
</span><span class="cx">/CalendarServer/branches/users/glyph/parallel-sim:8240-8251
</span><span class="cx">/CalendarServer/branches/users/glyph/parallel-upgrade:8376-8400
</span><span class="cx">/CalendarServer/branches/users/glyph/parallel-upgrade_to_1:8571-8583
</span><span class="cx">/CalendarServer/branches/users/glyph/q:9560-9688
</span><span class="cx">/CalendarServer/branches/users/glyph/queue-locking-and-timing:10204-10289
</span><span class="cx">/CalendarServer/branches/users/glyph/quota:7604-7637
</span><span class="cx">/CalendarServer/branches/users/glyph/sendfdport:5388-5424
</span><span class="cx">/CalendarServer/branches/users/glyph/shared-pool-fixes:8436-8443
</span><span class="cx">/CalendarServer/branches/users/glyph/shared-pool-take2:8155-8174
</span><span class="cx">/CalendarServer/branches/users/glyph/sharedpool:6490-6550
</span><span class="cx">/CalendarServer/branches/users/glyph/sharing-api:9192-9205
</span><span class="cx">/CalendarServer/branches/users/glyph/skip-lonely-vtimezones:8524-8535
</span><span class="cx">/CalendarServer/branches/users/glyph/sql-store:5929-6073
</span><span class="cx">/CalendarServer/branches/users/glyph/start-service-start-loop:11060-11065
</span><span class="cx">/CalendarServer/branches/users/glyph/subtransactions:7248-7258
</span><span class="cx">/CalendarServer/branches/users/glyph/table-alias:8651-8664
</span><span class="cx">/CalendarServer/branches/users/glyph/uidexport:7673-7676
</span><span class="cx">/CalendarServer/branches/users/glyph/unshare-when-access-revoked:10562-10595
</span><span class="cx">/CalendarServer/branches/users/glyph/use-system-twisted:5084-5149
</span><span class="cx">/CalendarServer/branches/users/glyph/uuid-normalize:9268-9296
</span><span class="cx">/CalendarServer/branches/users/glyph/warning-cleanups:11347-11357
</span><span class="cx">/CalendarServer/branches/users/glyph/whenNotProposed:11881-11897
</span><span class="cx">/CalendarServer/branches/users/glyph/xattrs-from-files:7757-7769
</span><span class="cx">/CalendarServer/branches/users/sagen/applepush:8126-8184
</span><span class="cx">/CalendarServer/branches/users/sagen/inboxitems:7380-7381
</span><span class="cx">/CalendarServer/branches/users/sagen/locations-resources:5032-5051
</span><span class="cx">/CalendarServer/branches/users/sagen/locations-resources-2:5052-5061
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who:12819-12860
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who-2:12861-12898
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who-3:12899-12913
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who-4:12914-13157
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who-5:13158-13163
</span><span class="cx">/CalendarServer/branches/users/sagen/newcua:13309-13327
</span><span class="cx">/CalendarServer/branches/users/sagen/newcua-1:13328-13330
</span><span class="cx">/CalendarServer/branches/users/sagen/purge_old_events:6735-6746
</span><span class="cx">/CalendarServer/branches/users/sagen/recordtypes:13648-13656
</span><span class="cx">/CalendarServer/branches/users/sagen/recordtypes-2:13657
</span><span class="cx">/CalendarServer/branches/users/sagen/resource-delegates-4038:4040-4067
</span><span class="cx">/CalendarServer/branches/users/sagen/resource-delegates-4066:4068-4075
</span><span class="cx">/CalendarServer/branches/users/sagen/resources-2:5084-5093
</span><span class="cx">/CalendarServer/branches/users/sagen/testing:10827-10851,10853-10855
</span><span class="cx">/CalendarServer/branches/users/wsanchez/psycopg2cffi:14427-14439
</span><span class="cx">/CalendarServer/branches/users/wsanchez/transations:5515-5593
</span><span class="cx">/CalendarServer/trunk:14338-14507
</span><span class="cx">   + /CalDAVTester/trunk:11193-11198
</span><span class="cx">/CalendarServer/branches/config-separation:4379-4443
</span><span class="cx">/CalendarServer/branches/egg-info-351:4589-4625
</span><span class="cx">/CalendarServer/branches/generic-sqlstore:6167-6191
</span><span class="cx">/CalendarServer/branches/new-store:5594-5934
</span><span class="cx">/CalendarServer/branches/new-store-no-caldavfile:5911-5935
</span><span class="cx">/CalendarServer/branches/new-store-no-caldavfile-2:5936-5981
</span><span class="cx">/CalendarServer/branches/release/CalendarServer-4.3-dev:10180-10190,10192
</span><span class="cx">/CalendarServer/branches/release/CalendarServer-5.1-dev:11846
</span><span class="cx">/CalendarServer/branches/release/CalendarServer-5.2-dev:11972,12357-12358,12794,12814
</span><span class="cx">/CalendarServer/branches/users/cdaboo/batchupload-6699:6700-7198
</span><span class="cx">/CalendarServer/branches/users/cdaboo/cached-subscription-calendars-5692:5693-5702
</span><span class="cx">/CalendarServer/branches/users/cdaboo/component-set-fixes:8130-8346
</span><span class="cx">/CalendarServer/branches/users/cdaboo/cross-pod-sharing:12038-12191
</span><span class="cx">/CalendarServer/branches/users/cdaboo/directory-cache-on-demand-3627:3628-3644
</span><span class="cx">/CalendarServer/branches/users/cdaboo/fix-no-ischedule:11607-11871
</span><span class="cx">/CalendarServer/branches/users/cdaboo/implicituidrace:8137-8141
</span><span class="cx">/CalendarServer/branches/users/cdaboo/ischedule-dkim:9747-9979
</span><span class="cx">/CalendarServer/branches/users/cdaboo/json:11622-11912
</span><span class="cx">/CalendarServer/branches/users/cdaboo/managed-attachments:9985-10145
</span><span class="cx">/CalendarServer/branches/users/cdaboo/more-sharing-5591:5592-5601
</span><span class="cx">/CalendarServer/branches/users/cdaboo/partition-4464:4465-4957
</span><span class="cx">/CalendarServer/branches/users/cdaboo/performance-tweaks:11824-11836
</span><span class="cx">/CalendarServer/branches/users/cdaboo/pods:7297-7377
</span><span class="cx">/CalendarServer/branches/users/cdaboo/pycalendar:7085-7206
</span><span class="cx">/CalendarServer/branches/users/cdaboo/pycard:7227-7237
</span><span class="cx">/CalendarServer/branches/users/cdaboo/queued-attendee-refreshes:7740-8287
</span><span class="cx">/CalendarServer/branches/users/cdaboo/relative-config-paths-5070:5071-5105
</span><span class="cx">/CalendarServer/branches/users/cdaboo/reverse-proxy-pods:11875-11900
</span><span class="cx">/CalendarServer/branches/users/cdaboo/scheduling-queue-refresh:11783-12557
</span><span class="cx">/CalendarServer/branches/users/cdaboo/shared-calendars-5187:5188-5440
</span><span class="cx">/CalendarServer/branches/users/cdaboo/sharing-in-the-store:11935-12016
</span><span class="cx">/CalendarServer/branches/users/cdaboo/store-scheduling:10876-11129
</span><span class="cx">/CalendarServer/branches/users/cdaboo/timezones:7443-7699
</span><span class="cx">/CalendarServer/branches/users/cdaboo/txn-debugging:8730-8743
</span><span class="cx">/CalendarServer/branches/users/gaya/cleanrevisions:12152-12334
</span><span class="cx">/CalendarServer/branches/users/gaya/groupsharee2:13669-13773
</span><span class="cx">/CalendarServer/branches/users/gaya/sharedgroupfixes:12120-12142
</span><span class="cx">/CalendarServer/branches/users/gaya/sharedgroups-3:11088-11204
</span><span class="cx">/CalendarServer/branches/users/glyph/always-abort-txn-on-error:9958-9969
</span><span class="cx">/CalendarServer/branches/users/glyph/case-insensitive-uid:8772-8805
</span><span class="cx">/CalendarServer/branches/users/glyph/conn-limit:6574-6577
</span><span class="cx">/CalendarServer/branches/users/glyph/contacts-server-merge:4971-5080
</span><span class="cx">/CalendarServer/branches/users/glyph/dalify:6932-7023
</span><span class="cx">/CalendarServer/branches/users/glyph/db-reconnect:6824-6876
</span><span class="cx">/CalendarServer/branches/users/glyph/deploybuild:7563-7572
</span><span class="cx">/CalendarServer/branches/users/glyph/digest-auth-redux:10624-10635
</span><span class="cx">/CalendarServer/branches/users/glyph/disable-quota:7718-7727
</span><span class="cx">/CalendarServer/branches/users/glyph/dont-start-postgres:6592-6614
</span><span class="cx">/CalendarServer/branches/users/glyph/enforce-max-requests:11640-11643
</span><span class="cx">/CalendarServer/branches/users/glyph/hang-fix:11465-11491
</span><span class="cx">/CalendarServer/branches/users/glyph/imip-and-admin-html:7866-7984
</span><span class="cx">/CalendarServer/branches/users/glyph/ipv6-client:9054-9105
</span><span class="cx">/CalendarServer/branches/users/glyph/launchd-wrapper-bis:11413-11436
</span><span class="cx">/CalendarServer/branches/users/glyph/linux-tests:6893-6900
</span><span class="cx">/CalendarServer/branches/users/glyph/log-cleanups:11691-11731
</span><span class="cx">/CalendarServer/branches/users/glyph/migrate-merge:8690-8713
</span><span class="cx">/CalendarServer/branches/users/glyph/misc-portability-fixes:7365-7374
</span><span class="cx">/CalendarServer/branches/users/glyph/more-deferreds-6:6322-6368
</span><span class="cx">/CalendarServer/branches/users/glyph/more-deferreds-7:6369-6445
</span><span class="cx">/CalendarServer/branches/users/glyph/multiget-delete:8321-8330
</span><span class="cx">/CalendarServer/branches/users/glyph/new-export:7444-7485
</span><span class="cx">/CalendarServer/branches/users/glyph/one-home-list-api:10048-10073
</span><span class="cx">/CalendarServer/branches/users/glyph/oracle:7106-7155
</span><span class="cx">/CalendarServer/branches/users/glyph/oracle-nulls:7340-7351
</span><span class="cx">/CalendarServer/branches/users/glyph/other-html:8062-8091
</span><span class="cx">/CalendarServer/branches/users/glyph/parallel-sim:8240-8251
</span><span class="cx">/CalendarServer/branches/users/glyph/parallel-upgrade:8376-8400
</span><span class="cx">/CalendarServer/branches/users/glyph/parallel-upgrade_to_1:8571-8583
</span><span class="cx">/CalendarServer/branches/users/glyph/q:9560-9688
</span><span class="cx">/CalendarServer/branches/users/glyph/queue-locking-and-timing:10204-10289
</span><span class="cx">/CalendarServer/branches/users/glyph/quota:7604-7637
</span><span class="cx">/CalendarServer/branches/users/glyph/sendfdport:5388-5424
</span><span class="cx">/CalendarServer/branches/users/glyph/shared-pool-fixes:8436-8443
</span><span class="cx">/CalendarServer/branches/users/glyph/shared-pool-take2:8155-8174
</span><span class="cx">/CalendarServer/branches/users/glyph/sharedpool:6490-6550
</span><span class="cx">/CalendarServer/branches/users/glyph/sharing-api:9192-9205
</span><span class="cx">/CalendarServer/branches/users/glyph/skip-lonely-vtimezones:8524-8535
</span><span class="cx">/CalendarServer/branches/users/glyph/sql-store:5929-6073
</span><span class="cx">/CalendarServer/branches/users/glyph/start-service-start-loop:11060-11065
</span><span class="cx">/CalendarServer/branches/users/glyph/subtransactions:7248-7258
</span><span class="cx">/CalendarServer/branches/users/glyph/table-alias:8651-8664
</span><span class="cx">/CalendarServer/branches/users/glyph/uidexport:7673-7676
</span><span class="cx">/CalendarServer/branches/users/glyph/unshare-when-access-revoked:10562-10595
</span><span class="cx">/CalendarServer/branches/users/glyph/use-system-twisted:5084-5149
</span><span class="cx">/CalendarServer/branches/users/glyph/uuid-normalize:9268-9296
</span><span class="cx">/CalendarServer/branches/users/glyph/warning-cleanups:11347-11357
</span><span class="cx">/CalendarServer/branches/users/glyph/whenNotProposed:11881-11897
</span><span class="cx">/CalendarServer/branches/users/glyph/xattrs-from-files:7757-7769
</span><span class="cx">/CalendarServer/branches/users/sagen/applepush:8126-8184
</span><span class="cx">/CalendarServer/branches/users/sagen/inboxitems:7380-7381
</span><span class="cx">/CalendarServer/branches/users/sagen/locations-resources:5032-5051
</span><span class="cx">/CalendarServer/branches/users/sagen/locations-resources-2:5052-5061
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who:12819-12860
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who-2:12861-12898
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who-3:12899-12913
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who-4:12914-13157
</span><span class="cx">/CalendarServer/branches/users/sagen/move2who-5:13158-13163
</span><span class="cx">/CalendarServer/branches/users/sagen/newcua:13309-13327
</span><span class="cx">/CalendarServer/branches/users/sagen/newcua-1:13328-13330
</span><span class="cx">/CalendarServer/branches/users/sagen/purge_old_events:6735-6746
</span><span class="cx">/CalendarServer/branches/users/sagen/recordtypes:13648-13656
</span><span class="cx">/CalendarServer/branches/users/sagen/recordtypes-2:13657
</span><span class="cx">/CalendarServer/branches/users/sagen/resource-delegates-4038:4040-4067
</span><span class="cx">/CalendarServer/branches/users/sagen/resource-delegates-4066:4068-4075
</span><span class="cx">/CalendarServer/branches/users/sagen/resources-2:5084-5093
</span><span class="cx">/CalendarServer/branches/users/sagen/testing:10827-10851,10853-10855
</span><span class="cx">/CalendarServer/branches/users/wsanchez/psycopg2cffi:14427-14439
</span><span class="cx">/CalendarServer/branches/users/wsanchez/transations:5515-5593
</span><span class="cx">/CalendarServer/trunk:14338-14519
</span><a id="CalendarServerbranchesuserscdaboopod2podmigrationtxdavbasedatastoresubpostgrespy"></a>
<div class="modfile"><h4>Modified: CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/base/datastore/subpostgres.py (14519 => 14520)</h4>
<pre class="diff"><span>
<span class="info">--- CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/base/datastore/subpostgres.py        2015-03-06 20:13:58 UTC (rev 14519)
+++ CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/base/datastore/subpostgres.py        2015-03-06 21:20:35 UTC (rev 14520)
</span><span class="lines">@@ -38,6 +38,7 @@
</span><span class="cx"> from twisted.internet.defer import Deferred
</span><span class="cx"> from txdav.base.datastore.dbapiclient import DBAPIConnector
</span><span class="cx"> from txdav.base.datastore.dbapiclient import postgresPreflight
</span><ins>+from txdav.common.datastore.sql_tables import splitSQLString
</ins><span class="cx"> from txdav.common.icommondatastore import InternalDataStoreError
</span><span class="cx"> 
</span><span class="cx"> from twisted.application.service import MultiService
</span><span class="lines">@@ -411,20 +412,20 @@
</span><span class="cx">             )
</span><span class="cx">         except:
</span><span class="cx">             # database already exists
</span><del>-            executeSQL = False
</del><ins>+            sqlToExecute = None
</ins><span class="cx">         else:
</span><span class="cx">             # database does not yet exist; if dump file exists, execute it,
</span><span class="cx">             # otherwise execute schema
</span><del>-            executeSQL = True
</del><span class="cx">             sqlToExecute = self.schema
</span><span class="cx"> 
</span><span class="cx">         createDatabaseCursor.close()
</span><span class="cx">         createDatabaseConn.close()
</span><span class="cx"> 
</span><del>-        if executeSQL:
</del><ins>+        if sqlToExecute is not None:
</ins><span class="cx">             connection = self.produceConnection()
</span><span class="cx">             cursor = connection.cursor()
</span><del>-            cursor.execute(sqlToExecute)
</del><ins>+            for statement in splitSQLString(sqlToExecute):
+                cursor.execute(statement)
</ins><span class="cx">             connection.commit()
</span><span class="cx">             connection.close()
</span><span class="cx"> 
</span></span></pre></div>
<a id="CalendarServerbranchesuserscdaboopod2podmigrationtxdavcommondatastorepoddingsharing_invitespy"></a>
<div class="modfile"><h4>Modified: CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/podding/sharing_invites.py (14519 => 14520)</h4>
<pre class="diff"><span>
<span class="info">--- CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/podding/sharing_invites.py        2015-03-06 20:13:58 UTC (rev 14519)
+++ CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/podding/sharing_invites.py        2015-03-06 21:20:35 UTC (rev 14520)
</span><span class="lines">@@ -26,33 +26,45 @@
</span><span class="cx">     &quot;&quot;&quot;
</span><span class="cx"> 
</span><span class="cx">     @inlineCallbacks
</span><del>-    def send_shareinvite(self, txn, homeType, ownerUID, ownerName, shareeUID, shareUID, bindMode, bindUID, summary, copy_properties, supported_components):
</del><ins>+    def send_shareinvite(
+        self, txn, homeType, ownerUID, ownerName, shareeUID, shareUID,
+        bindMode, bindUID, summary, copy_properties, supported_components
+    ):
</ins><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Send a sharing invite cross-pod message.
</span><span class="cx"> 
</span><span class="cx">         @param homeType: Type of home being shared.
</span><span class="cx">         @type homeType: C{int}
</span><ins>+
</ins><span class="cx">         @param ownerUID: UID of the sharer.
</span><span class="cx">         @type ownerUID: C{str}
</span><ins>+
</ins><span class="cx">         @param ownerName: owner's name of the sharer calendar
</span><span class="cx">         @type ownerName: C{str}
</span><ins>+
</ins><span class="cx">         @param shareeUID: UID of the sharee
</span><span class="cx">         @type shareeUID: C{str}
</span><ins>+
</ins><span class="cx">         @param shareUID: Resource/invite ID for sharee
</span><span class="cx">         @type shareUID: C{str}
</span><ins>+
</ins><span class="cx">         @param bindMode: bind mode for the share
</span><span class="cx">         @type bindMode: C{str}
</span><span class="cx">         @param bindUID: bind UID of the sharer calendar
</span><span class="cx">         @type bindUID: C{str}
</span><span class="cx">         @param summary: sharing message
</span><span class="cx">         @type summary: C{str}
</span><ins>+
</ins><span class="cx">         @param copy_properties: C{str} name/value for properties to be copied
</span><span class="cx">         @type copy_properties: C{dict}
</span><ins>+
</ins><span class="cx">         @param supported_components: supproted components, may be C{None}
</span><span class="cx">         @type supported_components: C{str}
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx"> 
</span><del>-        _ignore_sender, recipient = yield self.validRequest(ownerUID, shareeUID)
</del><ins>+        _ignore_sender, recipient = yield self.validRequest(
+            ownerUID, shareeUID
+        )
</ins><span class="cx"> 
</span><span class="cx">         request = {
</span><span class="cx">             &quot;action&quot;: &quot;shareinvite&quot;,
</span><span class="lines">@@ -75,14 +87,17 @@
</span><span class="cx">     @inlineCallbacks
</span><span class="cx">     def recv_shareinvite(self, txn, request):
</span><span class="cx">         &quot;&quot;&quot;
</span><del>-        Process a sharing invite cross-pod request. Request arguments as per L{send_shareinvite}.
</del><ins>+        Process a sharing invite cross-pod request.
+        Request arguments as per L{send_shareinvite}.
</ins><span class="cx"> 
</span><span class="cx">         @param request: request arguments
</span><span class="cx">         @type request: C{dict}
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx"> 
</span><span class="cx">         # Sharee home on this pod must exist (create if needed)
</span><del>-        shareeHome = yield txn.homeWithUID(request[&quot;type&quot;], request[&quot;sharee&quot;], create=True)
</del><ins>+        shareeHome = yield txn.homeWithUID(
+            request[&quot;type&quot;], request[&quot;sharee&quot;], create=True
+        )
</ins><span class="cx">         if shareeHome is None or shareeHome.external():
</span><span class="cx">             raise FailedCrossPodRequestError(&quot;Invalid sharee UID specified&quot;)
</span><span class="cx"> 
</span><span class="lines">@@ -100,23 +115,31 @@
</span><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx">     @inlineCallbacks
</span><del>-    def send_shareuninvite(self, txn, homeType, ownerUID, bindUID, shareeUID, shareUID):
</del><ins>+    def send_shareuninvite(
+        self, txn, homeType, ownerUID,
+        bindUID, shareeUID, shareUID
+    ):
</ins><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Send a sharing uninvite cross-pod message.
</span><span class="cx"> 
</span><span class="cx">         @param homeType: Type of home being shared.
</span><span class="cx">         @type homeType: C{int}
</span><ins>+
</ins><span class="cx">         @param ownerUID: UID of the sharer.
</span><span class="cx">         @type ownerUID: C{str}
</span><span class="cx">         @param bindUID: bind UID of the sharer calendar
</span><span class="cx">         @type bindUID: C{str}
</span><ins>+
</ins><span class="cx">         @param shareeUID: UID of the sharee
</span><span class="cx">         @type shareeUID: C{str}
</span><ins>+
</ins><span class="cx">         @param shareUID: Resource/invite ID for sharee
</span><span class="cx">         @type shareUID: C{str}
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx"> 
</span><del>-        _ignore_sender, recipient = yield self.validRequest(ownerUID, shareeUID)
</del><ins>+        _ignore_sender, recipient = yield self.validRequest(
+            ownerUID, shareeUID
+        )
</ins><span class="cx"> 
</span><span class="cx">         request = {
</span><span class="cx">             &quot;action&quot;: &quot;shareuninvite&quot;,
</span><span class="lines">@@ -133,7 +156,8 @@
</span><span class="cx">     @inlineCallbacks
</span><span class="cx">     def recv_shareuninvite(self, txn, request):
</span><span class="cx">         &quot;&quot;&quot;
</span><del>-        Process a sharing uninvite cross-pod request. Request arguments as per L{send_shareuninvite}.
</del><ins>+        Process a sharing uninvite cross-pod request.
+        Request arguments as per L{send_shareuninvite}.
</ins><span class="cx"> 
</span><span class="cx">         @param request: request arguments
</span><span class="cx">         @type request: C{dict}
</span><span class="lines">@@ -153,7 +177,10 @@
</span><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx">     @inlineCallbacks
</span><del>-    def send_sharereply(self, txn, homeType, ownerUID, shareeUID, shareUID, bindStatus, summary=None):
</del><ins>+    def send_sharereply(
+        self, txn, homeType, ownerUID,
+        shareeUID, shareUID, bindStatus, summary=None
+    ):
</ins><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Send a sharing reply cross-pod message.
</span><span class="cx"> 
</span><span class="lines">@@ -171,7 +198,9 @@
</span><span class="cx">         @type summary: C{str}
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx"> 
</span><del>-        _ignore_sender, recipient = yield self.validRequest(shareeUID, ownerUID)
</del><ins>+        _ignore_sender, recipient = yield self.validRequest(
+            shareeUID, ownerUID
+        )
</ins><span class="cx"> 
</span><span class="cx">         request = {
</span><span class="cx">             &quot;action&quot;: &quot;sharereply&quot;,
</span><span class="lines">@@ -190,7 +219,8 @@
</span><span class="cx">     @inlineCallbacks
</span><span class="cx">     def recv_sharereply(self, txn, request):
</span><span class="cx">         &quot;&quot;&quot;
</span><del>-        Process a sharing reply cross-pod request. Request arguments as per L{send_sharereply}.
</del><ins>+        Process a sharing reply cross-pod request.
+        Request arguments as per L{send_sharereply}.
</ins><span class="cx"> 
</span><span class="cx">         @param request: request arguments
</span><span class="cx">         @type request: C{dict}
</span></span></pre></div>
<a id="CalendarServerbranchesuserscdaboopod2podmigrationtxdavcommondatastoretesttest_sqlpy"></a>
<div class="modfile"><h4>Modified: CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/test/test_sql.py (14519 => 14520)</h4>
<pre class="diff"><span>
<span class="info">--- CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/test/test_sql.py        2015-03-06 20:13:58 UTC (rev 14519)
+++ CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/test/test_sql.py        2015-03-06 21:20:35 UTC (rev 14520)
</span><span class="lines">@@ -72,9 +72,9 @@
</span><span class="cx">         txn = self.transactionUnderTest()
</span><span class="cx">         cs = schema.CALENDARSERVER
</span><span class="cx">         version = (yield Select(
</span><del>-            [cs.VALUE, ],
</del><ins>+            [cs.VALUE],
</ins><span class="cx">             From=cs,
</span><del>-            Where=cs.NAME == 'VERSION',
</del><ins>+            Where=cs.NAME == &quot;VERSION&quot;,
</ins><span class="cx">         ).on(txn))
</span><span class="cx">         self.assertNotEqual(version, None)
</span><span class="cx">         self.assertEqual(len(version), 1)
</span></span></pre></div>
<a id="CalendarServerbranchesuserscdaboopod2podmigrationtxdavcommondatastoretestutilpy"></a>
<div class="modfile"><h4>Modified: CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/test/util.py (14519 => 14520)</h4>
<pre class="diff"><span>
<span class="info">--- CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/test/util.py        2015-03-06 20:13:58 UTC (rev 14519)
+++ CalendarServer/branches/users/cdaboo/pod2pod-migration/txdav/common/datastore/test/util.py        2015-03-06 21:20:35 UTC (rev 14520)
</span><span class="lines">@@ -108,10 +108,13 @@
</span><span class="cx">     def __init__(self, count=0):
</span><span class="cx">         self.sharedService = None
</span><span class="cx">         self.currentTestID = None
</span><del>-        self.sharedDBPath = &quot;_test_sql_db&quot; + str(os.getpid()) + (&quot;-{}&quot;.format(count) if count else &quot;&quot;)
</del><span class="cx">         self.ampPort = config.WorkQueue.ampPort + count
</span><span class="cx"> 
</span><ins>+        self.sharedDBPath = &quot;_test_sql_db-{}-{}&quot;.format(
+            os.getpid(), count
+        )
</ins><span class="cx"> 
</span><ins>+
</ins><span class="cx">     def createService(self, serviceFactory):
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Create a L{PostgresService} to use for building a store.
</span><span class="lines">@@ -157,7 +160,10 @@
</span><span class="cx">         return cds
</span><span class="cx"> 
</span><span class="cx"> 
</span><del>-    def buildStore(self, testCase, notifierFactory, directoryService=None, homes=None, enableJobProcessing=True):
</del><ins>+    def buildStore(
+        self, testCase, notifierFactory,
+        directoryService=None, homes=None, enableJobProcessing=True,
+    ):
</ins><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Do the necessary work to build a store for a particular test case.
</span><span class="cx"> 
</span><span class="lines">@@ -169,34 +175,45 @@
</span><span class="cx">         # The directory will be given to us later via setDirectoryService
</span><span class="cx">         if self.sharedService is None:
</span><span class="cx">             ready = Deferred()
</span><ins>+
</ins><span class="cx">             def getReady(connectionFactory, storageService):
</span><span class="cx">                 self.makeAndCleanStore(
</span><del>-                    testCase, notifierFactory, directoryService, attachmentRoot, enableJobProcessing
</del><ins>+                    testCase, notifierFactory, directoryService,
+                    attachmentRoot, enableJobProcessing
</ins><span class="cx">                 ).chainDeferred(ready)
</span><span class="cx">                 return Service()
</span><ins>+
</ins><span class="cx">             self.sharedService = self.createService(getReady)
</span><span class="cx">             self.sharedService.startService()
</span><ins>+
</ins><span class="cx">             def startStopping():
</span><span class="cx">                 log.info(&quot;Starting stopping.&quot;)
</span><span class="cx">                 self.sharedService.unpauseMonitor()
</span><span class="cx">                 return self.sharedService.stopService()
</span><del>-            reactor.addSystemEventTrigger(#@UndefinedVariable
</del><ins>+
+            reactor.addSystemEventTrigger(
</ins><span class="cx">                 &quot;before&quot;, &quot;shutdown&quot;, startStopping)
</span><span class="cx">             result = ready
</span><span class="cx">         else:
</span><span class="cx">             result = self.makeAndCleanStore(
</span><del>-                testCase, notifierFactory, directoryService, attachmentRoot, enableJobProcessing
</del><ins>+                testCase, notifierFactory, directoryService,
+                attachmentRoot, enableJobProcessing
</ins><span class="cx">             )
</span><ins>+
</ins><span class="cx">         def cleanUp():
</span><span class="cx">             def stopit():
</span><span class="cx">                 self.sharedService.pauseMonitor()
</span><span class="cx">             return deferLater(reactor, 0.1, stopit)
</span><ins>+
</ins><span class="cx">         testCase.addCleanup(cleanUp)
</span><span class="cx">         return result
</span><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx">     @inlineCallbacks
</span><del>-    def makeAndCleanStore(self, testCase, notifierFactory, directoryService, attachmentRoot, enableJobProcessing=True):
</del><ins>+    def makeAndCleanStore(
+        self, testCase, notifierFactory, directoryService,
+        attachmentRoot, enableJobProcessing=True
+    ):
</ins><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Create a L{CommonDataStore} specific to the given L{TestCase}.
</span><span class="cx"> 
</span><span class="lines">@@ -213,14 +230,19 @@
</span><span class="cx">         attachmentRoot.createDirectory()
</span><span class="cx"> 
</span><span class="cx">         currentTestID = testCase.id()
</span><del>-        cp = ConnectionPool(self.sharedService.produceConnection, maxConnections=4)
</del><ins>+        cp = ConnectionPool(
+            self.sharedService.produceConnection, maxConnections=4
+        )
</ins><span class="cx">         quota = deriveQuota(testCase)
</span><span class="cx">         store = CommonDataStore(
</span><span class="cx">             cp.connection,
</span><span class="cx">             {&quot;push&quot;: notifierFactory} if notifierFactory is not None else {},
</span><span class="cx">             directoryService,
</span><span class="cx">             attachmentRoot,
</span><del>-            &quot;https://example.com/calendars/__uids__/%(home)s/attachments/%(name)s&quot;,
</del><ins>+            (
+                &quot;https://example.com/calendars/__uids__/&quot;
+                &quot;%(home)s/attachments/%(name)s&quot;
+            ),
</ins><span class="cx">             quota=quota
</span><span class="cx">         )
</span><span class="cx">         store.label = currentTestID
</span><span class="lines">@@ -279,11 +301,13 @@
</span><span class="cx">         # table' statements are issued, so it's not possible to reference a
</span><span class="cx">         # later table.  Therefore it's OK to drop them in the (reverse) order
</span><span class="cx">         # that they happen to be in.
</span><del>-        tables = [t.name for t in schema.model.tables #@UndefinedVariable
-                  # All tables with rows _in_ the schema are populated
-                  # exclusively _by_ the schema and shouldn't be manipulated
-                  # while the server is running, so we leave those populated.
-                  if not t.schemaRows][::-1]
</del><ins>+        tables = [
+            t.name for t in schema.model.tables #@UndefinedVariable
+            # All tables with rows _in_ the schema are populated
+            # exclusively _by_ the schema and shouldn't be manipulated
+            # while the server is running, so we leave those populated.
+            if not t.schemaRows
+        ][::-1]
</ins><span class="cx"> 
</span><span class="cx">         for table in tables:
</span><span class="cx">             try:
</span><span class="lines">@@ -453,24 +477,32 @@
</span><span class="cx">             try:
</span><span class="cx">                 if config.RestrictCalendarsToOneComponentType:
</span><span class="cx">                     for name in ical.allowedStoreComponents:
</span><del>-                        yield home.removeCalendarWithName(home._componentCalendarName[name])
</del><ins>+                        yield home.removeCalendarWithName(
+                            home._componentCalendarName[name]
+                        )
</ins><span class="cx">                 else:
</span><span class="cx">                     yield home.removeCalendarWithName(&quot;calendar&quot;)
</span><span class="cx">                 yield home.removeCalendarWithName(&quot;inbox&quot;)
</span><span class="cx">             except NoSuchHomeChildError:
</span><span class="cx">                 pass
</span><ins>+
</ins><span class="cx">             for calendarName in calendars:
</span><span class="cx">                 calendarObjNames = calendars[calendarName]
</span><ins>+
</ins><span class="cx">                 if calendarObjNames is not None:
</span><span class="cx">                     # XXX should not be yielding!  this SQL will be executed
</span><span class="cx">                     # first!
</span><span class="cx">                     yield home.createCalendarWithName(calendarName)
</span><span class="cx">                     calendar = yield home.calendarWithName(calendarName)
</span><ins>+
</ins><span class="cx">                     for objectName in calendarObjNames:
</span><span class="cx">                         objData, metadata = calendarObjNames[objectName]
</span><ins>+
</ins><span class="cx">                         yield calendar._createCalendarObjectWithNameInternal(
</span><span class="cx">                             objectName,
</span><del>-                            VComponent.fromString(updateToCurrentYear(objData)),
</del><ins>+                            VComponent.fromString(
+                                updateToCurrentYear(objData)
+                            ),
</ins><span class="cx">                             internal_state=ComponentUpdateState.RAW,
</span><span class="cx">                             options=metadata,
</span><span class="cx">                         )
</span><span class="lines">@@ -481,7 +513,8 @@
</span><span class="cx"> 
</span><span class="cx"> def updateToCurrentYear(data):
</span><span class="cx">     &quot;&quot;&quot;
</span><del>-    Update the supplied iCalendar data so that all dates are updated to the current year.
</del><ins>+    Update the supplied iCalendar data so that all dates are updated to the
+    current year.
</ins><span class="cx">     &quot;&quot;&quot;
</span><span class="cx"> 
</span><span class="cx">     nowYear = DateTime.getToday().getYear()
</span><span class="lines">@@ -493,7 +526,8 @@
</span><span class="cx"> 
</span><span class="cx"> def componentUpdate(data):
</span><span class="cx">     &quot;&quot;&quot;
</span><del>-    Update the supplied iCalendar data so that all dates are updated to the current year.
</del><ins>+    Update the supplied iCalendar data so that all dates are updated to the
+    current year.
</ins><span class="cx">     &quot;&quot;&quot;
</span><span class="cx"> 
</span><span class="cx">     if len(relativeDateSubstitutions) == 0:
</span><span class="lines">@@ -540,10 +574,12 @@
</span><span class="cx">                     calendar = yield home.calendarWithName(calendarName)
</span><span class="cx">                     for objectName in calendarObjNames:
</span><span class="cx">                         md5 = calendarObjNames[objectName]
</span><del>-                        obj = yield calendar.calendarObjectWithName(
-                            objectName,
</del><ins>+                        obj = (
+                            yield calendar.calendarObjectWithName(objectName)
</ins><span class="cx">                         )
</span><del>-                        obj.properties()[md5key] = TwistedGETContentMD5.fromString(md5)
</del><ins>+                        obj.properties()[md5key] = (
+                            TwistedGETContentMD5.fromString(md5)
+                        )
</ins><span class="cx">     yield populateTxn.commit()
</span><span class="cx"> 
</span><span class="cx"> 
</span><span class="lines">@@ -574,7 +610,9 @@
</span><span class="cx">                     # XXX should not be yielding!  this SQL will be executed
</span><span class="cx">                     # first!
</span><span class="cx">                     yield home.createAddressBookWithName(addressbookName)
</span><del>-                    addressbook = yield home.addressbookWithName(addressbookName)
</del><ins>+                    addressbook = (
+                        yield home.addressbookWithName(addressbookName)
+                    )
</ins><span class="cx">                     for objectName in addressbookObjNames:
</span><span class="cx">                         objData = addressbookObjNames[objectName]
</span><span class="cx">                         yield addressbook.createAddressBookObjectWithName(
</span><span class="lines">@@ -605,13 +643,17 @@
</span><span class="cx">                 if addressbookObjNames is not None:
</span><span class="cx">                     # XXX should not be yielding!  this SQL will be executed
</span><span class="cx">                     # first!
</span><del>-                    addressbook = yield home.addressbookWithName(addressbookName)
</del><ins>+                    addressbook = (
+                        yield home.addressbookWithName(addressbookName)
+                    )
</ins><span class="cx">                     for objectName in addressbookObjNames:
</span><span class="cx">                         md5 = addressbookObjNames[objectName]
</span><span class="cx">                         obj = yield addressbook.addressbookObjectWithName(
</span><span class="cx">                             objectName,
</span><span class="cx">                         )
</span><del>-                        obj.properties()[md5key] = TwistedGETContentMD5.fromString(md5)
</del><ins>+                        obj.properties()[md5key] = (
+                            TwistedGETContentMD5.fromString(md5)
+                        )
</ins><span class="cx">     yield populateTxn.commit()
</span><span class="cx"> 
</span><span class="cx"> 
</span><span class="lines">@@ -634,8 +676,8 @@
</span><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx"> def buildTestDirectory(
</span><del>-    store, dataRoot, accounts=None, resources=None, augments=None, proxies=None,
-    serversDB=None, cacheSeconds=0
</del><ins>+    store, dataRoot, accounts=None, resources=None, augments=None,
+    proxies=None, serversDB=None, cacheSeconds=0,
</ins><span class="cx"> ):
</span><span class="cx">     &quot;&quot;&quot;
</span><span class="cx">     @param store: the store for the directory to use
</span><span class="lines">@@ -745,7 +787,8 @@
</span><span class="cx">     @inlineCallbacks
</span><span class="cx">     def buildStoreAndDirectory(
</span><span class="cx">         self, accounts=None, resources=None, augments=None, proxies=None,
</span><del>-        extraUids=None, serversDB=None, cacheSeconds=0, storeBuilder=theStoreBuilder
</del><ins>+        extraUids=None, serversDB=None, cacheSeconds=0,
+        storeBuilder=theStoreBuilder,
</ins><span class="cx">     ):
</span><span class="cx"> 
</span><span class="cx">         self.serverRoot = self.mktemp()
</span><span class="lines">@@ -798,10 +841,12 @@
</span><span class="cx">         if not os.path.exists(config.LogRoot):
</span><span class="cx">             os.makedirs(config.LogRoot)
</span><span class="cx"> 
</span><del>-        # Work queues for implicit scheduling slow down tests a lot and require them all to add
-        # &quot;waits&quot; for work to complete. Rewriting all the current tests to do that is not practical
-        # right now, so we will turn this off by default. Instead we will have a set of tests dedicated
-        # to work queue-based scheduling which will patch this option to True.
</del><ins>+        # Work queues for implicit scheduling slow down tests a lot and require
+        # them all to add &quot;waits&quot; for work to complete.
+        # Rewriting all the current tests to do that is not practical right
+        # now, so we will turn this off by default.
+        # Instead we will have a set of tests dedicated to work queue-based
+        # scheduling which will patch this option to True.
</ins><span class="cx">         config.Scheduling.Options.WorkQueues.Enabled = False
</span><span class="cx"> 
</span><span class="cx">         self.config = config
</span><span class="lines">@@ -835,20 +880,25 @@
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         if self.savedStore is None:
</span><span class="cx">             self.savedStore = self.storeUnderTest()
</span><ins>+
</ins><span class="cx">         self.counter += 1
</span><ins>+
</ins><span class="cx">         if txn is None:
</span><span class="cx">             txn = self.savedStore.newTransaction(
</span><span class="cx">                 self.id() + &quot; #&quot; + str(self.counter)
</span><span class="cx">             )
</span><span class="cx">         else:
</span><span class="cx">             txn._label = self.id() + &quot; #&quot; + str(self.counter)
</span><ins>+
</ins><span class="cx">         @inlineCallbacks
</span><span class="cx">         def maybeCommitThis():
</span><span class="cx">             try:
</span><span class="cx">                 yield txn.commit()
</span><span class="cx">             except AlreadyFinishedError:
</span><span class="cx">                 pass
</span><ins>+
</ins><span class="cx">         self.addCleanup(maybeCommitThis)
</span><ins>+
</ins><span class="cx">         return txn
</span><span class="cx"> 
</span><span class="cx"> 
</span><span class="lines">@@ -879,14 +929,13 @@
</span><span class="cx">         return self.store
</span><span class="cx"> 
</span><span class="cx"> 
</span><del>-    @inlineCallbacks
</del><span class="cx">     def homeUnderTest(self, txn=None, name=&quot;home1&quot;, status=None, create=False):
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Get the calendar home detailed by C{requirements['home1']}.
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         if txn is None:
</span><span class="cx">             txn = self.transactionUnderTest()
</span><del>-        returnValue((yield txn.calendarHomeWithUID(name, status=status, create=create)))
</del><ins>+        return txn.calendarHomeWithUID(name, status=status, create=create)
</ins><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx">     @inlineCallbacks
</span><span class="lines">@@ -894,19 +943,24 @@
</span><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Get the calendar detailed by C{requirements['home1']['calendar_1']}.
</span><span class="cx">         &quot;&quot;&quot;
</span><del>-        returnValue((
-            yield (yield self.homeUnderTest(txn, name=home, status=status)).calendarWithName(name)
-        ))
</del><ins>+        home = yield self.homeUnderTest(txn, home, status=status)
+        calendar = yield home.calendarWithName(name)
+        returnValue(calendar)
</ins><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx">     @inlineCallbacks
</span><del>-    def calendarObjectUnderTest(self, txn=None, name=&quot;1.ics&quot;, calendar_name=&quot;calendar_1&quot;, home=&quot;home1&quot;, status=None):
</del><ins>+    def calendarObjectUnderTest(
+        self, txn=None, name=&quot;1.ics&quot;, calendar_name=&quot;calendar_1&quot;, home=&quot;home1&quot;, status=None
+    ):
</ins><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Get the calendar detailed by
</span><span class="cx">         C{requirements[home][calendar_name][name]}.
</span><span class="cx">         &quot;&quot;&quot;
</span><del>-        returnValue((yield (yield self.calendarUnderTest(txn, name=calendar_name, home=home, status=status))
-                     .calendarObjectWithName(name)))
</del><ins>+        calendar = yield self.calendarUnderTest(
+            txn, name=calendar_name, home=home, status=status
+        )
+        object = yield calendar.calendarObjectWithName(name)
+        returnValue(object)
</ins><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx">     def addressbookHomeUnderTest(self, txn=None, name=&quot;home1&quot;):
</span><span class="lines">@@ -921,61 +975,66 @@
</span><span class="cx">     @inlineCallbacks
</span><span class="cx">     def addressbookUnderTest(self, txn=None, name=&quot;addressbook&quot;, home=&quot;home1&quot;):
</span><span class="cx">         &quot;&quot;&quot;
</span><del>-        Get the addressbook detailed by C{requirements['home1']['addressbook']}.
</del><ins>+        Get the addressbook detailed by
+        C{requirements['home1']['addressbook']}.
</ins><span class="cx">         &quot;&quot;&quot;
</span><del>-        returnValue((
-            yield (yield self.addressbookHomeUnderTest(txn=txn, name=home)).addressbookWithName(name)
-        ))
</del><ins>+        home = yield self.addressbookHomeUnderTest(txn=txn, name=home)
+        addressbook = yield home.addressbookWithName(name)
+        returnValue(addressbook)
</ins><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx">     @inlineCallbacks
</span><del>-    def addressbookObjectUnderTest(self, txn=None, name=&quot;1.vcf&quot;, addressbook_name=&quot;addressbook&quot;, home=&quot;home1&quot;):
</del><ins>+    def addressbookObjectUnderTest(
+        self, txn=None, name=&quot;1.vcf&quot;,
+        addressbook_name=&quot;addressbook&quot;, home=&quot;home1&quot;,
+    ):
</ins><span class="cx">         &quot;&quot;&quot;
</span><span class="cx">         Get the addressbook detailed by
</span><span class="cx">         C{requirements['home1']['addressbook']['1.vcf']}.
</span><span class="cx">         &quot;&quot;&quot;
</span><del>-        returnValue((yield (yield self.addressbookUnderTest(txn=txn, name=addressbook_name, home=home))
-                    .addressbookObjectWithName(name)))
</del><ins>+        addressBook = yield self.addressbookUnderTest(
+            txn=txn, name=addressbook_name, home=home
+        )
+        object = yield addressBook.addressbookObjectWithName(name)
+        returnValue(object)
</ins><span class="cx"> 
</span><span class="cx"> 
</span><del>-    @inlineCallbacks
</del><span class="cx">     def notificationCollectionUnderTest(self, txn=None, name=&quot;home1&quot;, status=None, create=False):
</span><span class="cx">         if txn is None:
</span><span class="cx">             txn = self.transactionUnderTest()
</span><del>-        returnValue((yield txn.notificationsWithUID(name, status=status, create=create)))
</del><ins>+        return txn.notificationsWithUID(name, status=status, create=create)
</ins><span class="cx"> 
</span><span class="cx"> 
</span><del>-    @inlineCallbacks
</del><span class="cx">     def userRecordWithShortName(self, shortname):
</span><del>-        record = yield self.directory.recordWithShortName(self.directory.recordType.user, shortname)
-        returnValue(record)
</del><ins>+        return self.directory.recordWithShortName(
+            self.directory.recordType.user, shortname
+        )
</ins><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx">     @inlineCallbacks
</span><span class="cx">     def userUIDFromShortName(self, shortname):
</span><del>-        record = yield self.directory.recordWithShortName(self.directory.recordType.user, shortname)
</del><ins>+        record = yield self.directory.recordWithShortName(
+            self.directory.recordType.user, shortname
+        )
</ins><span class="cx">         returnValue(record.uid if record is not None else None)
</span><span class="cx"> 
</span><span class="cx"> 
</span><del>-    @inlineCallbacks
</del><span class="cx">     def addRecordFromFields(self, fields):
</span><span class="cx">         updatedRecord = DirectoryRecord(self.directory, fields)
</span><del>-        yield self.directory.updateRecords((updatedRecord,), create=True)
</del><ins>+        return self.directory.updateRecords((updatedRecord,), create=True)
</ins><span class="cx"> 
</span><span class="cx"> 
</span><del>-    @inlineCallbacks
</del><span class="cx">     def removeRecord(self, uid):
</span><del>-        yield self.directory.removeRecords([uid])
</del><ins>+        return self.directory.removeRecords([uid])
</ins><span class="cx"> 
</span><span class="cx"> 
</span><del>-    @inlineCallbacks
</del><span class="cx">     def changeRecord(self, record, fieldname, value, directory=None):
</span><span class="cx">         if directory is None:
</span><span class="cx">             directory = self.directory
</span><span class="cx">         fields = record.fields.copy()
</span><span class="cx">         fields[fieldname] = value
</span><span class="cx">         updatedRecord = DirectoryRecord(directory, fields)
</span><del>-        yield directory.updateRecords((updatedRecord,))
</del><ins>+        return directory.updateRecords((updatedRecord,))
</ins><span class="cx"> 
</span><span class="cx"> 
</span><span class="cx"> 
</span></span></pre>
</div>
</div>

</body>
</html>