Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Group data into separate tables #162

Open
roniemartinez opened this issue May 27, 2022 · 0 comments
Open

Group data into separate tables #162

roniemartinez opened this issue May 27, 2022 · 0 comments
Labels
enhancement New feature or request
Milestone

Comments

@roniemartinez
Copy link
Owner

roniemartinez commented May 27, 2022

Output is always flattened into a single list of dictionaries before saving to CSV, JSON, etc.

By grouping data into separate tables, it will be easier to post-process and merge the tables, e.g. connect data from separate pages into one row.

@select(css="...", table="table1")
def function1(element):
    return {"data1": element.text_content()}

@select(css="...", table="table2")
def function2(element):
    return {"data2": element.text_content()}
@roniemartinez roniemartinez added the enhancement New feature or request label May 27, 2022
@roniemartinez roniemartinez added this to the Alpha milestone May 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant