diff --git a/pipelines/ingest-farcaster-data/cyphers.py b/pipelines/ingest-farcaster-data/cyphers.py index 1540ab2..327d6ae 100644 --- a/pipelines/ingest-farcaster-data/cyphers.py +++ b/pipelines/ingest-farcaster-data/cyphers.py @@ -8,7 +8,7 @@ def __init__(self): def create_user_fid_index(self): logging.info("Creating users index...") - query = """CREATE INDEX farcaster_user_fid_index IF NOT EXISTS FOR (u:User:Farcaster) ON (u.fid)""" + query = """CREATE INDEX farcaster_user_fid_index IF NOT EXISTS FOR (u:User) ON (u.fid)""" self.query(query) def create_cast_index(self): @@ -18,7 +18,7 @@ def create_cast_index(self): def create_wallet_index(self): logging.info("Creating wallets index...") - query = """CREATE INDEX farcaster_wallet_address_index IF NOT EXISTS FOR (w:Wallet:Farcaster) ON (w.address)""" + query = """CREATE INDEX farcaster_wallet_address_index IF NOT EXISTS FOR (w:Wallet) ON (w.address)""" self.query(query) def create_channel_id_index(self): diff --git a/pipelines/ingest-farcaster-data/ingest.py b/pipelines/ingest-farcaster-data/ingest.py index 3397154..5c2aef3 100644 --- a/pipelines/ingest-farcaster-data/ingest.py +++ b/pipelines/ingest-farcaster-data/ingest.py @@ -46,7 +46,7 @@ def create_channel_followers(self): 'username': self.cyphers.sanitize_text(user.get('username', '')), 'display_name': self.cyphers.sanitize_text(user.get('display_name', '')), 'custody_address': user.get('custody_address', ''), - 'allWallets': user.get('verified_addresses').get('eth_addresses'), + 'allWallets': user.get('verified_addresses', {}).get('eth_addresses', []), 'bio_text': self.cyphers.sanitize_text(user.get('profile', {}).get('bio', {}).get('text', '')), 'power_badge': user.get('power_badge', '') } for user in channel["followers"] if isinstance(user, dict)]) @@ -102,13 +102,13 @@ def create_connect_channel_casts(self): """ Connect authors """ - self.cyphers.connect_casts_authors() + # self.cyphers.connect_casts_authors() def run(self): self.create_indexes() - self.create_or_merge_channels() - self.create_channel_followers() - self.connect_channel_members() + # self.create_or_merge_channels() + # self.create_channel_followers() + # self.connect_channel_members() self.create_connect_channel_casts() if __name__ == "__main__":