Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F15545525
phabricator 'compact' transaction phid storage
No One
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Authored By
•
mmodell
Mar 16 2018, 1:45 AM
2018-03-16 01:45:53 (UTC+0)
Size
715 B
Referenced Files
None
Subscribers
None
phabricator 'compact' transaction phid storage
View Options
def compute_edge_phids_from_transactions(transactions, edgetype):
final_phids = {}
for trns in transactions:
try:
metadata = json.loads(trns[9])
if "edge:type" in metadata.keys() and metadata[
"edge:type"] is edgetype:
# removed phids:
phids = json.loads(trns[7])
for phid in phids:
final_phids.setdefault(phid, False)
# added phids:
phids = json.loads(trns[8])
for phid in phids:
final_phids.setdefault(phid, True)
except:
pass
return [key for key, val in final_phids.items() if val is True]
File Metadata
Details
Attached
Mime Type
text/plain; charset=utf-8
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5637971
Default Alt Text
phabricator 'compact' transaction phid storage (715 B)
Attached To
Mode
P6852 phabricator 'compact' transaction phid storage
Attached
Detach File
Event Timeline
Log In to Comment