Skip to content

Save event_no as a non-index column in ParquetWriter#872

Open
astrojarred wants to merge 1 commit intographnet-team:mainfrom
astrojarred:astrojarred/issue871
Open

Save event_no as a non-index column in ParquetWriter#872
astrojarred wants to merge 1 commit intographnet-team:mainfrom
astrojarred:astrojarred/issue871

Conversation

@astrojarred
Copy link
Copy Markdown
Collaborator

The main change here is that instead of setting the self._index_column to the index, we just let it stay as a normal column in the dataframe/parquet file.

This way later we don't get 'column not found' errors when merging files in these places:

  • _process_shard() when calling id = split[index_column]
  • _identify_events() when doing df.select([index_column])

This fixes the bug I was having but would need a maintainer/expert to let me know if this might mess things up downstream, i.e. if somewhere else event_no is expected as an index column. In this case we could just set the index again at the very end of the merging process.

Fixes #871

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ParquetWriter fails when merging files

1 participant