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

[DatasetMigration] Migration fails if no source_params are set #92

Open
jsh2134 opened this issue Jun 20, 2018 · 1 comment
Open

[DatasetMigration] Migration fails if no source_params are set #92

jsh2134 opened this issue Jun 20, 2018 · 1 comment

Comments

@jsh2134
Copy link
Contributor

jsh2134 commented Jun 20, 2018

If no source params are passed an error is returned

DatasetMigration.create(
    source_id=dataset$id,
    target_id=dataset$id,
    target_fields=fields
)

Error parsing API response
Error in value[[3L]](cond) : {"non_field_errors": ["No input provided"]}

WIth source_params

DatasetMigration.create(
    source_id=dataset$id,
    target_id=dataset$id,
    source_params=list(limit=1),
    target_fields=fields
)
# success

The NULL value must be sent incorrectly.

Oddly enough, if I pass source_params and no target_fields, we do not have this problem. So maybe the API serializer?

@jsh2134
Copy link
Contributor Author

jsh2134 commented Jun 20, 2018

passing some dummy params will work

DatasetMigration.create(
    source_id=dataset$id,
    target_id=dataset$id,
    source_params=list(fake_kwarg=1),
    target_fields=fields
)

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

No branches or pull requests

1 participant