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

v0.5.5 #11

Merged
merged 15 commits into from
Dec 30, 2020
Merged

v0.5.5 #11

merged 15 commits into from
Dec 30, 2020

Conversation

ms7m
Copy link
Owner

@ms7m ms7m commented Dec 30, 2020

  • You can now directly return DiscordResponse inside your handler. Dispike will either check the function result, or will look at your hint for the function (this is perferred)
  • You can now use NotReadyResponse, this response returns nothing to discord when an interaction is called, but saves the token and ID as well as methods sync_send_callback and async_send_callback that allow for sending a DiscordResponse later.

⚠️ Warning ⚠️

Autocompletion for creating new models under DiscordCommand, CommandChoice, CommandOption, SubcommandOption, CommandTypes on VSCode is broken. (follow discussion here pydantic/pydantic#650, microsoft/python-language-server#1898). PyCharm appears to work using an external plugin.

@todo
Copy link

todo bot commented Dec 30, 2020

Make a file full of common pytest fixtures for easy access.

# TODO: Make a file full of common pytest fixtures for easy access.
respx.post(
f"https://discord.com/api/v8/interactions/{_created_content._interaction_id}/{_created_content._interaction_token}/callback"
).mock(return_value=Response(status_code=200))
await _created_content.async_send_callback(sample_discord_response)


This comment was generated by todo based on a TODO comment in ded3706 in #11. cc @ms7m.

Repository owner deleted a comment from todo bot Dec 30, 2020
@codecov
Copy link

codecov bot commented Dec 30, 2020

Codecov Report

Merging #11 (b66db50) into master (11a99be) will increase coverage by 17.90%.
The diff coverage is 87.93%.

Impacted file tree graph

@@             Coverage Diff             @@
##           master      #11       +/-   ##
===========================================
+ Coverage   65.20%   83.10%   +17.90%     
===========================================
  Files          17       13        -4     
  Lines         684      444      -240     
===========================================
- Hits          446      369       -77     
+ Misses        238       75      -163     
Impacted Files Coverage Δ
dispike/server.py 86.27% <84.61%> (+20.88%) ⬆️
dispike/response.py 91.89% <90.00%> (-1.29%) ⬇️
dispike/eventer.py 92.30% <100.00%> (+4.80%) ⬆️
dispike/helper/utils.py
dispike/helper/color.py
dispike/helper/__init__.py
dispike/helper/embed.py

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 11a99be...b66db50. Read the comment docs.

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.

1 participant