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

Automated error report: x_runJob_indexTweets_ParseTweetsError #480

Closed
redshiftzero opened this issue Mar 28, 2025 · 1 comment
Closed

Automated error report: x_runJob_indexTweets_ParseTweetsError #480

redshiftzero opened this issue Mar 28, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@redshiftzero
Copy link
Contributor

Describe the bug

a user got a NOT NULL constraint violation in the tweet_url table on the expandedURL column, hit during indexParseTweets

in that method, we do check if expandedURL is falsy and return early if not:

// Loop over all URL items
        tweetLegacy.entities?.urls.forEach((url: XAPILegacyURL) => {
            // Make sure we have all of the URL information before importing
            if (!url["url"] || !url["display_url"] || !url["expanded_url"] || !url["indices"]) {
                return;
            }

Error report data:

{'exception': 'Error: Error invoking remote method \'X:indexParseTweets\': Error: {"message":"{\\"exception\\":{\\"message\\":\\"NOT NULL constraint failed: tweet_url.expandedURL\\",\\"name\\":\\"SqliteError\\",\\"stack\\":\\"SqliteError: NOT NULL constraint failed: tweet_url.expandedURL\\\\n    at c (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:11:623)\\\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:9680\\\\n    at Array.forEach (<anonymous>)\\\\n    at it.indexTweetURLs (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:9478)\\\\n    at it.indexTweet (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:3387)\\\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:7935\\\\n    at Array.forEach (<anonymous>)\\\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:5485\\\\n    at Array.forEach (<anonymous>)\\\\n    at it.indexParseTweetsResponseData (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:5138)\\\\n    at it.indexParseTweets (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:8373)\\\\n    at async /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:326:15762\\\\n    at async WebContents.<anonymous> (node:electron/js2c/browser_init:2:83724)\\"},\\"sql\\":\\"INSERT INTO tweet_url (url, displayURL, expandedURL, startIndex, endIndex, tweetID) VALUES (?, ?, ?, ?, ?, ?)\\",\\"params\\":[\\"URL_WAS_HERE\\",\\"URL_WAS_HERE\\",null,119,139,\\"TWEET_ID_WAS_HERE\\"]}","name":"Error","stack":"Error: {\\"exception\\":{\\"message\\":\\"NOT NULL constraint failed: tweet_url.expandedURL\\",\\"name\\":\\"SqliteError\\",\\"stack\\":\\"SqliteError: NOT NULL constraint failed: tweet_url.expandedURL\\\\n    at c (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:11:623)\\\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:9680\\\\n    at Array.forEach (<anonymous>)\\\\n    at it.indexTweetURLs (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:9478)\\\\n    at it.indexTweet (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:3387)\\\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:7935\\\\n    at Array.forEach (<anonymous>)\\\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:5485\\\\n    at Array.forEach (<anonymous>)\\\\n    at it.indexParseTweetsResponseData (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:5138)\\\\n    at it.indexParseTweets (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:8373)\\\\n    at async /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:326:15762\\\\n    at async WebContents.<anonymous> (node:electron/js2c/browser_init:2:83724)\\"},\\"sql\\":\\"INSERT INTO tweet_url (url, displayURL, expandedURL, startIndex, endIndex, tweetID) VALUES (?, ?, ?, ?, ?, ?)\\",\\"params\\":[\\"URL_WAS_HERE\\",\\"URL_WAS_HERE\\",null,119,139,\\"TWEET_ID_WAS_HERE\\"]}\\n    at c (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:11:670)\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:9680\\n    at Array.forEach (<anonymous>)\\n    at it.indexTweetURLs (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:9478)\\n    at it.indexTweet (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:3387)\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:7935\\n    at Array.forEach (<anonymous>)\\n    at /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:5485\\n    at Array.forEach (<anonymous>)\\n    at it.indexParseTweetsResponseData (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:5138)\\n    at it.indexParseTweets (/Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:306:8373)\\n    at async /Applications/Cyd.app/Contents/Resources/app-arm64.asar/.vite/build/main.js:326:15762\\n    at async WebContents.<anonymous> (node:electron/js2c/browser_init:2:83724)"}'}

Desktop:

  • OS: macOS
  • Version of Cyd: 1.0.28
@redshiftzero redshiftzero added the bug Something isn't working label Mar 28, 2025
@redshiftzero
Copy link
Contributor Author

in this case, there is no check for expandedURL being falsy on v1.0.28: https://github.com/lockdown-systems/cyd/blob/v1.0.28/src/account_x/x_account_controller.ts#L814-L836

but the bug should be fixed on main given that we do return early if expandedURL is falsy

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant