Skip to content

Commit f74f7ea

Browse files
committed
rename order_by to order
1 parent 2fecb49 commit f74f7ea

File tree

17 files changed

+194
-190
lines changed

17 files changed

+194
-190
lines changed

github/core/client.py

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -503,7 +503,7 @@ def fetch_advisories(
503503
*,
504504
cursor: str | None = MISSING,
505505
limit: int = MISSING,
506-
order_by: AdvisoryOrder = MISSING,
506+
order: AdvisoryOrder = MISSING,
507507
reverse: bool = MISSING,
508508
**kwargs, # TODO
509509
) -> Connection[Advisory]:
@@ -519,7 +519,7 @@ def fetch_advisories(
519519
The cursor to start at.
520520
limit: :class:`int`
521521
The maximum number of elements to yield.
522-
order_by: :class:`~github.AdvisoryOrder`
522+
order: :class:`~github.AdvisoryOrder`
523523
The field by which to order the elements.
524524
reverse: :class:`bool`
525525
Whether to yield the elements in reverse order.
@@ -537,7 +537,7 @@ def fetch_advisories(
537537

538538
return github.Connection(
539539
self._http.collect_query_advisories,
540-
order_by.value if order_by is not MISSING else None,
540+
order.value if order is not MISSING else None,
541541
data_map=lambda d: github.Advisory._from_data(d, http=self._http),
542542
cursor=cursor if cursor is not MISSING else None,
543543
limit=limit if limit is not MISSING else None,
@@ -551,7 +551,7 @@ def fetch_sponsorables(
551551
*,
552552
cursor: str | None = MISSING,
553553
limit: int = MISSING,
554-
order_by: SponsorableOrder = MISSING,
554+
order: SponsorableOrder = MISSING,
555555
reverse: bool = MISSING,
556556
**kwargs, # TODO
557557
) -> Connection[Organization | User]:
@@ -573,7 +573,7 @@ def fetch_sponsorables(
573573
The cursor to start at.
574574
limit: :class:`int`
575575
The maximum number of elements to yield.
576-
order_by: :class:`~github.SponsorableOrder`
576+
order: :class:`~github.SponsorableOrder`
577577
The field by which to order the elements.
578578
reverse: :class:`bool`
579579
Whether to yield the elements in reverse order.
@@ -591,7 +591,7 @@ def fetch_sponsorables(
591591

592592
return github.Connection(
593593
self._http.collect_query_sponsorables,
594-
order_by.value if order_by is not MISSING else None,
594+
order.value if order is not MISSING else None,
595595
data_map=lambda d: github.Organization._from_data(d, http=self._http) if d["__typename"] == "Organization" else github.User._from_data(d, http=self._http),
596596
cursor=cursor if cursor is not MISSING else None,
597597
limit=limit if limit is not MISSING else None,
@@ -605,7 +605,7 @@ def fetch_vulnerabilities(
605605
*,
606606
cursor: str | None = MISSING,
607607
limit: int = MISSING,
608-
order_by: VulnerabilityOrder = MISSING,
608+
order: VulnerabilityOrder = MISSING,
609609
reverse: bool = MISSING,
610610
**kwargs, # TODO
611611
) -> Connection[Vulnerability]:
@@ -621,7 +621,7 @@ def fetch_vulnerabilities(
621621
The cursor to start at.
622622
limit: :class:`int`
623623
The maximum number of elements to yield.
624-
order_by: :class:`~github.VulnerabilityOrder`
624+
order: :class:`~github.VulnerabilityOrder`
625625
The field by which to order the elements.
626626
reverse: :class:`bool`
627627
Whether to yield the elements in reverse order.
@@ -639,7 +639,7 @@ def fetch_vulnerabilities(
639639

640640
return github.Connection(
641641
self._http.collect_query_vulnerabilities,
642-
order_by.value if order_by is not MISSING else None,
642+
order.value if order is not MISSING else None,
643643
data_map=lambda d: github.Vulnerability._from_data(d),
644644
cursor=cursor if cursor is not MISSING else None,
645645
limit=limit if limit is not MISSING else None,

github/core/http.py

Lines changed: 93 additions & 93 deletions
Large diffs are not rendered by default.

github/git/reference.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ def fetch_pulls(
213213
*,
214214
cursor: str | None = MISSING,
215215
limit: int = MISSING,
216-
order_by: PullOrder = MISSING,
216+
order: PullOrder = MISSING,
217217
reverse: bool = MISSING,
218218
**kwargs, # TODO
219219
) -> Connection[Pull]:
@@ -229,7 +229,7 @@ def fetch_pulls(
229229
The cursor to start at.
230230
limit: :class:`int`
231231
The maximum number of elements to yield.
232-
order_by: :class:`~github.PullOrder`
232+
order: :class:`~github.PullOrder`
233233
The field by which to order the elements.
234234
reverse: :class:`bool`
235235
Whether to yield the elements in reverse order.
@@ -248,7 +248,7 @@ def fetch_pulls(
248248
return github.Connection(
249249
self._http.collect_reference_pulls,
250250
self.id,
251-
order_by.value if order_by is not MISSING else None,
251+
order.value if order is not MISSING else None,
252252
data_map=lambda d: github.Pull._from_data(d, http=self._http),
253253
cursor=cursor if cursor is not MISSING else None,
254254
limit=limit if limit is not MISSING else None,

github/interfaces/discussionauthor.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def fetch_discussions(
3737
*,
3838
cursor: str | None = MISSING,
3939
limit: int = MISSING,
40-
order_by: DiscussionOrder = MISSING,
40+
order: DiscussionOrder = MISSING,
4141
repository: Repository = MISSING,
4242
reverse: bool = MISSING,
4343
**kwargs, # TODO
@@ -54,7 +54,7 @@ def fetch_discussions(
5454
The cursor to start at.
5555
limit: :class:`int`
5656
The maximum number of elements to yield.
57-
order_by: :class:`~github.DiscussionOrder`
57+
order: :class:`~github.DiscussionOrder`
5858
The field by which to order the elements.
5959
repository: :class:`~github.Repository`
6060
The repository to filter discussions by.
@@ -78,7 +78,7 @@ def fetch_discussions(
7878
return github.Connection(
7979
self._http.collect_discussionauthor_discussions,
8080
self.id,
81-
order_by.value if order_by is not MISSING else None,
81+
order.value if order is not MISSING else None,
8282
repository.id if repository is not MISSING else None,
8383
data_map=lambda d: github.Discussion._from_data(d, http=self._http),
8484
cursor=cursor if cursor is not MISSING else None,

github/interfaces/labelable.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ def fetch_labels(
110110
*,
111111
cursor: str | None = MISSING,
112112
limit: int = MISSING,
113-
order_by: LabelOrder = MISSING,
113+
order: LabelOrder = MISSING,
114114
reverse: bool = MISSING,
115115
**kwargs, # TODO
116116
) -> Connection[Label]:
@@ -127,7 +127,7 @@ def fetch_labels(
127127
The cursor to start at.
128128
limit: :class:`int`
129129
The maximum number of elements to yield.
130-
order_by: :class:`~github.LabelOrder`
130+
order: :class:`~github.LabelOrder`
131131
The field by which to order the elements.
132132
reverse: :class:`bool`
133133
Whether to yield the elements in reverse order.
@@ -149,7 +149,7 @@ def fetch_labels(
149149
return github.Connection(
150150
self._http.collect_labelable_labels,
151151
self.id,
152-
order_by.value if order_by is not MISSING else None,
152+
order.value if order is not MISSING else None,
153153
data_map=lambda d: github.Label._from_data(d, http=self._http),
154154
cursor=cursor if cursor is not MISSING else None,
155155
limit=limit if limit is not MISSING else None,

github/interfaces/packageowner.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ def fetch_packages(
7878
*,
7979
cursor: str | None = MISSING,
8080
limit: int = MISSING,
81-
order_by: PackageOrder = MISSING,
81+
order: PackageOrder = MISSING,
8282
repository: Repository = MISSING,
8383
reverse: bool = MISSING,
8484
**kwargs, # TODO
@@ -95,7 +95,7 @@ def fetch_packages(
9595
The cursor to start at.
9696
limit: :class:`int`
9797
The maximum number of elements to yield.
98-
order_by: :class:`~github.PackageOrder`
98+
order: :class:`~github.PackageOrder`
9999
The field by which to order the elements.
100100
repository: :class:`~github.Repository`
101101
The repository to filter packages to.
@@ -119,7 +119,7 @@ def fetch_packages(
119119
return github.Connection(
120120
self._http.collect_packageowner_packages,
121121
self.id,
122-
order_by.value if order_by is not MISSING else None,
122+
order.value if order is not MISSING else None,
123123
repository.id if repository is not MISSING else None,
124124
data_map=lambda d: github.Package._from_data(d, http=self._http),
125125
cursor=cursor if cursor is not MISSING else None,

github/interfaces/reactable.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ def fetch_reactions(
110110
*,
111111
cursor: str | None = MISSING,
112112
limit: int = MISSING,
113-
order_by: ReactionOrder = MISSING,
113+
order: ReactionOrder = MISSING,
114114
reverse: bool = MISSING,
115115
) -> Connection[Reaction]:
116116
"""
@@ -125,7 +125,7 @@ def fetch_reactions(
125125
The cursor to start at.
126126
limit: :class:`int`
127127
The maximum number of elements to yield.
128-
order_by: :class:`~github.ReactionOrder`
128+
order: :class:`~github.ReactionOrder`
129129
The field by which to order the elements.
130130
reverse: :class:`bool`
131131
Whether to yield the elements in reverse order.
@@ -147,7 +147,7 @@ def fetch_reactions(
147147
return github.Connection(
148148
self._http.collect_reactable_reactions,
149149
self.id,
150-
order_by.value if order_by is not MISSING else None,
150+
order.value if order is not MISSING else None,
151151
data_map=lambda d: github.Reaction._from_data(d, http=self._http),
152152
cursor=cursor if cursor is not MISSING else None,
153153
limit=limit if limit is not MISSING else None,

github/interfaces/repositoryowner.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ def fetch_repositories(
129129
*,
130130
cursor: str | None = MISSING,
131131
limit: int = MISSING,
132-
order_by: RepositoryOrder = MISSING,
132+
order: RepositoryOrder = MISSING,
133133
reverse: bool = MISSING,
134134
**kwargs, # TODO
135135
) -> Connection[Repository]:
@@ -146,7 +146,7 @@ def fetch_repositories(
146146
The cursor to start at.
147147
limit: :class:`int`
148148
The maximum number of elements to yield.
149-
order_by: :class:`~github.RepositoryOrder`
149+
order: :class:`~github.RepositoryOrder`
150150
The field by which to order the elements.
151151
reverse: :class:`bool`
152152
Whether to yield the elements in reverse order.
@@ -168,7 +168,7 @@ def fetch_repositories(
168168
return github.Connection(
169169
self._http.collect_repositoryowner_repositories,
170170
self.id,
171-
order_by.value if order_by is not MISSING else None,
171+
order.value if order is not MISSING else None,
172172
data_map=lambda d: github.Repository._from_data(d, http=self._http),
173173
cursor=cursor if cursor is not MISSING else None,
174174
limit=limit if limit is not MISSING else None,

github/interfaces/starrable.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ def fetch_stargazers(
9999
*,
100100
cursor: str | None = MISSING,
101101
limit: int = MISSING,
102-
order_by: StargazerOrder = MISSING,
102+
order: StargazerOrder = MISSING,
103103
reverse: bool = MISSING,
104104
) -> Connection[User]:
105105
"""
@@ -114,6 +114,8 @@ def fetch_stargazers(
114114
The cursor to start at.
115115
limit: :class:`int`
116116
The maximum number of elements to yield.
117+
order: :class:`~github.StargazerOrder`
118+
The field by which to order the elements.
117119
reverse: :class:`bool`
118120
Whether to yield the elements in reverse order.
119121
@@ -134,7 +136,7 @@ def fetch_stargazers(
134136
return github.Connection(
135137
self._http.collect_starrable_stargazers,
136138
self.id,
137-
order_by.value if order_by is not MISSING else None,
139+
order.value if order is not MISSING else None,
138140
data_map=lambda d: github.User._from_data(d, http=self._http),
139141
cursor=cursor if cursor is not MISSING else None,
140142
limit=limit if limit is not MISSING else None,

github/organization/organization.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -699,7 +699,7 @@ def fetch_mannequins(
699699
*,
700700
cursor: str | None = MISSING,
701701
limit: int = MISSING,
702-
order_by: MannequinOrder = MISSING,
702+
order: MannequinOrder = MISSING,
703703
reverse: bool = MISSING,
704704
**kwargs, # TODO
705705
) -> Connection[Mannequin]:
@@ -715,7 +715,7 @@ def fetch_mannequins(
715715
The cursor to start at.
716716
limit: :class:`int`
717717
The maximum number of elements to yield.
718-
order_by: :class:`~github.MannequinOrder`
718+
order: :class:`~github.MannequinOrder`
719719
The field by which to order the elements.
720720
reverse: :class:`bool`
721721
Whether to yield the elements in reverse order.
@@ -734,7 +734,7 @@ def fetch_mannequins(
734734
return github.Connection(
735735
self._http.collect_organization_mannequins,
736736
self.id,
737-
order_by.value if order_by is not MISSING else None,
737+
order.value if order is not MISSING else None,
738738
data_map=lambda d: github.Mannequin._from_data(d, http=self._http),
739739
cursor=cursor if cursor is not MISSING else None,
740740
limit=limit if limit is not MISSING else None,
@@ -748,7 +748,7 @@ def fetch_teams(
748748
*,
749749
cursor: str | None = MISSING,
750750
limit: int = MISSING,
751-
order_by: TeamOrder = MISSING,
751+
order: TeamOrder = MISSING,
752752
reverse: bool = MISSING,
753753
**kwargs, # TODO
754754
) -> Connection[Team]:
@@ -764,7 +764,7 @@ def fetch_teams(
764764
The cursor to start at.
765765
limit: :class:`int`
766766
The maximum number of elements to yield.
767-
order_by: :class:`~github.TeamOrder`
767+
order: :class:`~github.TeamOrder`
768768
The field by which to order the elements.
769769
reverse: :class:`bool`
770770
Whether to yield the elements in reverse order.
@@ -783,7 +783,7 @@ def fetch_teams(
783783
return github.Connection(
784784
self._http.collect_organization_teams,
785785
self.id,
786-
order_by.value if order_by is not MISSING else None,
786+
order.value if order is not MISSING else None,
787787
data_map=lambda d: github.Team._from_data(d, http=self._http),
788788
cursor=cursor if cursor is not MISSING else None,
789789
limit=limit if limit is not MISSING else None,

0 commit comments

Comments
 (0)