DIYgod/RSSHub · error · Error
${userInfo.message}
Error message
${userInfo.message} What it means
Thrown by the DXY user profile thread route when the user-info API (`/bbs/newweb/personal-page/user-info`) returns a non-success `code`. The route fetches user metadata before fetching their post list. If the userId is invalid, the signature is rejected, or the user account is restricted, the API returns an error code with a `message` that is re-thrown.
Source
Thrown at lib/routes/dxy/profile/thread.ts:51
const userId = ctx.req.param('userId');
const { limit = '30' } = ctx.req.query();
const userInfo = await cache.tryGet(`dxy:user-info:${userId}`, async () => {
const userInfoParams = {
userId,
serverTimestamp: Date.now(),
timestamp: Date.now(),
noncestr: generateNonce(8, 'number'),
};
const { data: userInfo } = await got(`${webBaseUrl}/bbs/newweb/personal-page/user-info`, {
searchParams: {
...userInfoParams,
sign: sign(userInfoParams),
},
});
if (userInfo.code !== 'success') {
throw new Error(userInfo.message);
}
return userInfo.data;
});
const postList = await cache.tryGet(
`dxy:user:post:${userId}`,
async () => {
const postListParams = {
userId,
type: '0',
pageNum: '1',
pageSize: limit,
serverTimestamp: Date.now(),
timestamp: Date.now(),
noncestr: generateNonce(8, 'number'),
};
View on GitHub (pinned to bed535e087)
Solutions
- Verify the userId by visiting the user's DXY profile page in a browser.
- Retry — may be transient.
- Inspect the upstream message for the specific error.
- If persistent, check for RSSHub updates.
Example fix
// before
if (userInfo.code !== 'success') {
throw new Error(userInfo.message);
}
// after
if (userInfo.code !== 'success') {
throw new Error(`DXY user-info API error (userId=${userId}, code=${userInfo.code}): ${userInfo.message}`);
} Defensive patterns
Strategy: try-catch
Type guard
function isDxyUserInfoSuccess(resp: unknown): boolean {
return typeof resp === 'object' && resp !== null && (resp as any).code === 'success';
} Try / catch
try {
const feed = await fetch(`${rsshubUrl}/dxy/bbs/profile/thread/${userId}`);
} catch (e) {
console.error(`DXY user-info API error for userId ${userId}: ${e.message}`);
throw e;
} Prevention
- Verify the userId by visiting the user's DXY profile page.
- Retry after a delay — transient errors are common with signed API requests.
- If the error mentions signature, the signing algorithm may have rotated.
- Inspect the upstream message for the specific error reason.
When it happens
Trigger: The userId doesn't exist or has been deleted; the user's profile is private or restricted; signature validation fails; rate limiting; the user-info API endpoint structure changed.
Common situations: Incorrect userId from an outdated URL; the user account was suspended; signing algorithm mismatch; transient API error.
Related errors
AI-assisted analysis of DIYgod/RSSHub@bed535e087 (2026-08-12).
Data as JSON: /api/errors/8057081ebf91b2eb.
Report an issue: GitHub.