life-itself / web3

Making sense of web3 & crypto. Introduction to key concepts and ideas. Rigorous, constructive analysis of key claims pro and con. A look at the deeper hopes and aspirations.

Home Page:https://web3.lifeitself.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Build error on sec-remarks related to YOUTUBE_REGEX

rufuspollock opened this issue · comments

Some reason build is failing on sec-remarks note

11:38:36 AM: info  - Compiled successfully
11:38:36 AM: info  - Collecting page data...
11:38:40 AM: info  - Generating static pages (0/302)
11:38:42 AM: info  - Generating static pages (75/302)
11:38:43 AM: info  - Generating static pages (150/302)
11:38:43 AM: info  - Generating static pages (226/302)
11:38:44 AM: Error occurred prerendering page "/notes/sec-remarks". Read more: https://nextjs.org/docs/messages/prerender-error
11:38:44 AM: TypeError: Cannot read properties of null (reading '1')
11:38:44 AM:     at Paragraph (/opt/build/repo/site/.next/server/pages/[...slug].js:509:77)

Debugging in dev mode get more informative:

image

What i can't work out is why this regex is matching at all in that doc as no href links at all.

Testing locally have found that YOUTUBE_REGEX is testing true on https://www.sec.gov/news/speech/gensler-remarks-crypto-markets-040422

@khalilcodes suggest we remove YOUTUBE_REGEX everywhere if we can and just use YOUTUBE_ID_REGEX.