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

Add sync functions #9

Merged
merged 10 commits into from
Oct 25, 2023
Merged

Add sync functions #9

merged 10 commits into from
Oct 25, 2023

Conversation

silentworks
Copy link
Collaborator

@silentworks silentworks commented Oct 23, 2023

What kind of change does this PR introduce?

Update with sync functions, added pytests and throw error messages instead of returning them.

What is the current behavior?

There are only async functions, no pytests and errors are returned

What is the new behavior?

We now have sync functions, pytests and errors are thrown

Additional context

Addresses #6

Add pytests
Throw errors instead of returning them
Copy link
Contributor

@anand2312 anand2312 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haven't tested yet but a few comments

supafunc/_async/functions_client.py Outdated Show resolved Hide resolved
supafunc/_async/functions_client.py Outdated Show resolved Hide resolved
supafunc/_async/functions_client.py Outdated Show resolved Hide resolved
supafunc/_async/functions_client.py Outdated Show resolved Hide resolved
supafunc/_async/functions_client.py Outdated Show resolved Hide resolved
supafunc/errors.py Outdated Show resolved Hide resolved
supafunc/errors.py Outdated Show resolved Hide resolved
supafunc/errors.py Outdated Show resolved Hide resolved
supafunc/errors.py Outdated Show resolved Hide resolved
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't really like the create_client functions tbh; what do you think about just not providing them? It's easy enough for the user to just import the client they want and instantiate it, the create_client functions don't really do much else either so it feels like bloat

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be removed too but this will be a breaking change and we should remove this in all the python libraries at the same time.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree - we can add deprecation warnings to all of them now and remove them soon

silentworks and others added 4 commits October 23, 2023 16:28
Co-authored-by: Anand <40204976+anand2312@users.noreply.github.com>
Co-authored-by: Anand <40204976+anand2312@users.noreply.github.com>
.github/workflows/ci.yml Outdated Show resolved Hide resolved
supafunc/_async/functions_client.py Outdated Show resolved Hide resolved
supafunc/_async/functions_client.py Show resolved Hide resolved
@codecov-commenter
Copy link

Welcome to Codecov 🎉

Once merged to your default branch, Codecov will compare your coverage reports and display the results in this comment.

Thanks for integrating Codecov - We've got you covered ☂️

Copy link
Contributor

@anand2312 anand2312 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Nice work on the tests too!

@silentworks silentworks merged commit e2db242 into main Oct 25, 2023
6 checks passed
@silentworks silentworks deleted the silentworks/sync_functions branch October 25, 2023 08:37
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.

3 participants