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

remove deprecated app.bsky.unspecced.getPopular #1988

Merged
merged 4 commits into from
Jan 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .changeset/rich-turkeys-buy.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
---
'@atproto/bsky': patch
'@atproto/api': patch
'@atproto/pds': patch
---

remove deprecated app.bsky.unspecced.getPopular endpoint
40 changes: 0 additions & 40 deletions lexicons/app/bsky/unspecced/getPopular.json

This file was deleted.

13 changes: 0 additions & 13 deletions packages/api/src/client/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,6 @@ import * as AppBskyNotificationRegisterPush from './types/app/bsky/notification/
import * as AppBskyNotificationUpdateSeen from './types/app/bsky/notification/updateSeen'
import * as AppBskyRichtextFacet from './types/app/bsky/richtext/facet'
import * as AppBskyUnspeccedDefs from './types/app/bsky/unspecced/defs'
import * as AppBskyUnspeccedGetPopular from './types/app/bsky/unspecced/getPopular'
import * as AppBskyUnspeccedGetPopularFeedGenerators from './types/app/bsky/unspecced/getPopularFeedGenerators'
import * as AppBskyUnspeccedGetTimelineSkeleton from './types/app/bsky/unspecced/getTimelineSkeleton'
import * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecced/searchActorsSkeleton'
Expand Down Expand Up @@ -279,7 +278,6 @@ export * as AppBskyNotificationRegisterPush from './types/app/bsky/notification/
export * as AppBskyNotificationUpdateSeen from './types/app/bsky/notification/updateSeen'
export * as AppBskyRichtextFacet from './types/app/bsky/richtext/facet'
export * as AppBskyUnspeccedDefs from './types/app/bsky/unspecced/defs'
export * as AppBskyUnspeccedGetPopular from './types/app/bsky/unspecced/getPopular'
export * as AppBskyUnspeccedGetPopularFeedGenerators from './types/app/bsky/unspecced/getPopularFeedGenerators'
export * as AppBskyUnspeccedGetTimelineSkeleton from './types/app/bsky/unspecced/getTimelineSkeleton'
export * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecced/searchActorsSkeleton'
Expand Down Expand Up @@ -2395,17 +2393,6 @@ export class UnspeccedNS {
this._service = service
}

getPopular(
params?: AppBskyUnspeccedGetPopular.QueryParams,
opts?: AppBskyUnspeccedGetPopular.CallOptions,
): Promise<AppBskyUnspeccedGetPopular.Response> {
return this._service.xrpc
.call('app.bsky.unspecced.getPopular', params, undefined, opts)
.catch((e) => {
throw AppBskyUnspeccedGetPopular.toKnownErr(e)
})
}

getPopularFeedGenerators(
params?: AppBskyUnspeccedGetPopularFeedGenerators.QueryParams,
opts?: AppBskyUnspeccedGetPopularFeedGenerators.CallOptions,
Expand Down
49 changes: 0 additions & 49 deletions packages/api/src/client/lexicons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7563,54 +7563,6 @@ export const schemaDict = {
},
},
},
AppBskyUnspeccedGetPopular: {
lexicon: 1,
id: 'app.bsky.unspecced.getPopular',
defs: {
main: {
type: 'query',
description:
'DEPRECATED: will be removed soon. Use a feed generator alternative.',
parameters: {
type: 'params',
properties: {
includeNsfw: {
type: 'boolean',
default: false,
},
limit: {
type: 'integer',
minimum: 1,
maximum: 100,
default: 50,
},
cursor: {
type: 'string',
},
},
},
output: {
encoding: 'application/json',
schema: {
type: 'object',
required: ['feed'],
properties: {
cursor: {
type: 'string',
},
feed: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.feed.defs#feedViewPost',
},
},
},
},
},
},
},
},
AppBskyUnspeccedGetPopularFeedGenerators: {
lexicon: 1,
id: 'app.bsky.unspecced.getPopularFeedGenerators',
Expand Down Expand Up @@ -7978,7 +7930,6 @@ export const ids = {
AppBskyNotificationUpdateSeen: 'app.bsky.notification.updateSeen',
AppBskyRichtextFacet: 'app.bsky.richtext.facet',
AppBskyUnspeccedDefs: 'app.bsky.unspecced.defs',
AppBskyUnspeccedGetPopular: 'app.bsky.unspecced.getPopular',
AppBskyUnspeccedGetPopularFeedGenerators:
'app.bsky.unspecced.getPopularFeedGenerators',
AppBskyUnspeccedGetTimelineSkeleton: 'app.bsky.unspecced.getTimelineSkeleton',
Expand Down
39 changes: 0 additions & 39 deletions packages/api/src/client/types/app/bsky/unspecced/getPopular.ts

This file was deleted.

12 changes: 0 additions & 12 deletions packages/bsky/src/lexicon/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ import * as AppBskyNotificationGetUnreadCount from './types/app/bsky/notificatio
import * as AppBskyNotificationListNotifications from './types/app/bsky/notification/listNotifications'
import * as AppBskyNotificationRegisterPush from './types/app/bsky/notification/registerPush'
import * as AppBskyNotificationUpdateSeen from './types/app/bsky/notification/updateSeen'
import * as AppBskyUnspeccedGetPopular from './types/app/bsky/unspecced/getPopular'
import * as AppBskyUnspeccedGetPopularFeedGenerators from './types/app/bsky/unspecced/getPopularFeedGenerators'
import * as AppBskyUnspeccedGetTimelineSkeleton from './types/app/bsky/unspecced/getTimelineSkeleton'
import * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecced/searchActorsSkeleton'
Expand Down Expand Up @@ -1530,17 +1529,6 @@ export class UnspeccedNS {
this._server = server
}

getPopular<AV extends AuthVerifier>(
cfg: ConfigOf<
AV,
AppBskyUnspeccedGetPopular.Handler<ExtractAuth<AV>>,
AppBskyUnspeccedGetPopular.HandlerReqCtx<ExtractAuth<AV>>
>,
) {
const nsid = 'app.bsky.unspecced.getPopular' // @ts-ignore
return this._server.xrpc.method(nsid, cfg)
}

getPopularFeedGenerators<AV extends AuthVerifier>(
cfg: ConfigOf<
AV,
Expand Down
49 changes: 0 additions & 49 deletions packages/bsky/src/lexicon/lexicons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7563,54 +7563,6 @@ export const schemaDict = {
},
},
},
AppBskyUnspeccedGetPopular: {
lexicon: 1,
id: 'app.bsky.unspecced.getPopular',
defs: {
main: {
type: 'query',
description:
'DEPRECATED: will be removed soon. Use a feed generator alternative.',
parameters: {
type: 'params',
properties: {
includeNsfw: {
type: 'boolean',
default: false,
},
limit: {
type: 'integer',
minimum: 1,
maximum: 100,
default: 50,
},
cursor: {
type: 'string',
},
},
},
output: {
encoding: 'application/json',
schema: {
type: 'object',
required: ['feed'],
properties: {
cursor: {
type: 'string',
},
feed: {
type: 'array',
items: {
type: 'ref',
ref: 'lex:app.bsky.feed.defs#feedViewPost',
},
},
},
},
},
},
},
},
AppBskyUnspeccedGetPopularFeedGenerators: {
lexicon: 1,
id: 'app.bsky.unspecced.getPopularFeedGenerators',
Expand Down Expand Up @@ -7978,7 +7930,6 @@ export const ids = {
AppBskyNotificationUpdateSeen: 'app.bsky.notification.updateSeen',
AppBskyRichtextFacet: 'app.bsky.richtext.facet',
AppBskyUnspeccedDefs: 'app.bsky.unspecced.defs',
AppBskyUnspeccedGetPopular: 'app.bsky.unspecced.getPopular',
AppBskyUnspeccedGetPopularFeedGenerators:
'app.bsky.unspecced.getPopularFeedGenerators',
AppBskyUnspeccedGetTimelineSkeleton: 'app.bsky.unspecced.getTimelineSkeleton',
Expand Down
49 changes: 0 additions & 49 deletions packages/bsky/src/lexicon/types/app/bsky/unspecced/getPopular.ts

This file was deleted.

23 changes: 0 additions & 23 deletions packages/pds/src/api/app/bsky/unspecced/getPopular.ts

This file was deleted.

2 changes: 0 additions & 2 deletions packages/pds/src/api/app/bsky/unspecced/index.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
import { Server } from '../../../../lexicon'
import AppContext from '../../../../context'
import getPopular from './getPopular'
import getPopularFeedGenerators from './getPopularFeedGenerators'

// THIS IS A TEMPORARY UNSPECCED ROUTE
export default function (server: Server, ctx: AppContext) {
getPopular(server, ctx)
getPopularFeedGenerators(server, ctx)
}
12 changes: 0 additions & 12 deletions packages/pds/src/lexicon/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,6 @@ import * as AppBskyNotificationGetUnreadCount from './types/app/bsky/notificatio
import * as AppBskyNotificationListNotifications from './types/app/bsky/notification/listNotifications'
import * as AppBskyNotificationRegisterPush from './types/app/bsky/notification/registerPush'
import * as AppBskyNotificationUpdateSeen from './types/app/bsky/notification/updateSeen'
import * as AppBskyUnspeccedGetPopular from './types/app/bsky/unspecced/getPopular'
import * as AppBskyUnspeccedGetPopularFeedGenerators from './types/app/bsky/unspecced/getPopularFeedGenerators'
import * as AppBskyUnspeccedGetTimelineSkeleton from './types/app/bsky/unspecced/getTimelineSkeleton'
import * as AppBskyUnspeccedSearchActorsSkeleton from './types/app/bsky/unspecced/searchActorsSkeleton'
Expand Down Expand Up @@ -1530,17 +1529,6 @@ export class UnspeccedNS {
this._server = server
}

getPopular<AV extends AuthVerifier>(
cfg: ConfigOf<
AV,
AppBskyUnspeccedGetPopular.Handler<ExtractAuth<AV>>,
AppBskyUnspeccedGetPopular.HandlerReqCtx<ExtractAuth<AV>>
>,
) {
const nsid = 'app.bsky.unspecced.getPopular' // @ts-ignore
return this._server.xrpc.method(nsid, cfg)
}

getPopularFeedGenerators<AV extends AuthVerifier>(
cfg: ConfigOf<
AV,
Expand Down
Loading
Loading