Skip to content

Commit 61a3017

Browse files
EepyElvyrapre-commit-ci[bot]i0bsmAxYoLo01
authored
feat: implement get function (#801)
* fix: unfuck the branch * feat: Add single-arg cache * feat: more work on get * Update get.pyi * ci: correct from checks. * Update get.py * ci: correct from checks. * Update get.py * Update get.py * ci: correct from checks. * Update get.py * Update get.py * ci: correct from checks. * Update get.py * Update get.py * feat: more work on get * feat: more work on get * feat: more work on get * feat: more work on get * Update get.py * Update get.py * ci: correct from checks. * Update get.py * Update get.py * ci: correct from checks. * Update get.py * feat: more work on get * docs: work on docs for get * Update get.py * Update get.pyi * Update get.py * ci: correct from checks. * Update get.pyi * ci: correct from checks. * Update get.py * feat: Allow `list[obj]` * Update docs/get.rst Co-authored-by: Sofia <41456914+ffl0w@users.noreply.github.com> * Update interactions/client/get.py Co-authored-by: Sofia <41456914+ffl0w@users.noreply.github.com> * fix: Fix `TpyeVar`s * fix: * fix: allow py3.9 typehints * fix: fix cache attribute and instance checks * Update interactions/client/get.py Co-authored-by: Max <maxyolo01.ytb@gmail.com> * Update interactions/client/get.py Co-authored-by: Max <maxyolo01.ytb@gmail.com> * refactor: Optimize `_search_iterable` * refactor: Optimize `_search_iterable`and use a list of tuples instead of a tuple of tuples * Update migration.rst * Update migration.rst * Update migration.rst * Update migration.rst * Update migration.rst * Update migration.rst * Update migration.rst Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Sofia <41456914+ffl0w@users.noreply.github.com> Co-authored-by: Max <maxyolo01.ytb@gmail.com>
1 parent bc969ae commit 61a3017

File tree

6 files changed

+534
-1
lines changed

6 files changed

+534
-1
lines changed

docs/api.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ Interactions
2020

2121
ext.rst
2222
context.rst
23+
get.rst
2324

2425
.. toctree::
2526
:maxdepth: 2

docs/get.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
.. currentmodule:: interactions
2+
3+
The ``get`` utility method
4+
================
5+
6+
.. automodule:: interactions.client.get
7+
:members:
8+
:noindex:

docs/migration.rst

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,13 @@ portal and add the intent to your current intents when connecting:
6666
4.1.0 → 4.3.0
6767
~~~~~~~~~~~~~~~
6868

69-
``4.3.0`` introduces a new method of creating commands, subcommands, and options.
69+
A new big change in this release is the implementation of the ``get` utility method.
70+
It allows you to no longer use ``**await bot._http...``.
71+
72+
You can get more information by reading the `get-documentation`_.
73+
74+
75+
``4.3.0`` also introduces a new method of creating commands, subcommands, and options.
7076
There are also numerous new features, such as a default scope and utilities.
7177

7278
The following example shows and explains how to create commands effortlessly and use new features mentioned above:
@@ -175,3 +181,5 @@ The following example shows and explains how to create commands effortlessly and
175181
# configurable
176182
177183
bot.start()
184+
185+
.. _get-documentation: https://interactionspy.readthedocs.io/en/latest/get.html#the-get-utility-method

interactions/client/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,4 +8,5 @@
88
from .context import * # noqa: F401 F403
99
from .decor import * # noqa: F401 F403
1010
from .enums import * # noqa: F401 F403
11+
from .get import * # noqa: F401 F403
1112
from .models import * # noqa: F401 F403

0 commit comments

Comments
 (0)