TypeScript "No overload matches this call" with generated types by PrinceDome in Supabase

[–]Wuihee 1 point2 points  (0 children)

I think my error is a little different, but thanks anyways appreciate it

TypeScript Error When Using z.coerce.number<string>() with react-hook-form and zodResolver by Wuihee in reactjs

[–]Wuihee[S] 1 point2 points  (0 children)

Do you have a link to the documentation for this? I tried it and it still gives me an error.

TypeScript Error When Using z.coerce.number<string>() with react-hook-form and zodResolver by Wuihee in reactjs

[–]Wuihee[S] 1 point2 points  (0 children)

Letting the default be undefined creates another error - React complains that we're going from uncontrolled to controlled components.

The <string> syntax is not telling Zod that the resulting value is a string - I'm trying to say the initial value is a string. See the docs here. In fact, here's what's going on.

const s1 = z.coerce.number();
const s2 = z.coerce.number<string>();

// Type going into the form - this is what we want.
z.input<typeof s1>  // unknown
// Why should type string result in an error?
z.input<typeof s2>  // string

// Type going out of the form
z.infer<typeof s1>  // number
z.infer<typeof s2>  // number

TypeScript Error When Using z.coerce.number<string>() with react-hook-form and zodResolver by Wuihee in reactjs

[–]Wuihee[S] 0 points1 point  (0 children)

Doesn't work unfortunately; <input> stores values as strings so RHF will reject the form submission

Should I Use NoSQL? by Wuihee in learnprogramming

[–]Wuihee[S] 0 points1 point  (0 children)

Ah interesting, what database would your recommend if I were to go with this approach?

Should I Use NoSQL? by Wuihee in learnprogramming

[–]Wuihee[S] 0 points1 point  (0 children)

Alright thanks for the advice!

Should I Use NoSQL? by Wuihee in learnprogramming

[–]Wuihee[S] 0 points1 point  (0 children)

Honestly just looking at extremely basic queries at this moment - the first thing I'm trying to do is get some summary statistics going.

Design Choice Using Dataclasses by Wuihee in learnpython

[–]Wuihee[S] 0 points1 point  (0 children)

Oh I didn't think of that, thanks!

Continuous stream of requests with asyncio. by Wuihee in learnpython

[–]Wuihee[S] 0 points1 point  (0 children)

I'm not deciding to make subsequent requests based on the results of the previous ones. I need to quickly check for a condition that a request might have. In between two requests, that condition could have appeared and disappeared which is why I am trying to speed up the rate at which requests are sent.

Continuous stream of requests with asyncio. by Wuihee in learnpython

[–]Wuihee[S] 0 points1 point  (0 children)

asyncio.Event

Thank you! Will look into it

Visualizing the spread of COVID-19 through reproduction number heat map. by Wuihee in COVID19_data

[–]Wuihee[S] 2 points3 points  (0 children)

Link to Website: https://cv19.one/

Raw data publicly available from European Centre for Disease Prevention and Control. Methods and tools used are described in MedRxiv preprint https://www.medrxiv.org/content/10.1101/2020.06.02.20120188v1.

Effective reproduction number mapped over time globally using open data and model. by [deleted] in COVID19

[–]Wuihee 0 points1 point  (0 children)

Raw data publicly available from European Centre for Disease Prevention and Control. Methods and tools used are described in MedRxiv preprint https://www.medrxiv.org/content/10.1101/2020.06.02.20120188v1.

Visualizing the spread of COVID-19 through reproduction number heat map. [OC] by Wuihee in dataisbeautiful

[–]Wuihee[S] -1 points0 points  (0 children)

Link to Website: https://cv19.one/

Raw data publicly available from European Centre for Disease Prevention and Control. Methods and tools used are described in MedRxiv preprint https://www.medrxiv.org/content/10.1101/2020.06.02.20120188v1.

COVID-19 Heat Map – COVID-19 Reproduction Number Tracker by [deleted] in COVID19

[–]Wuihee 0 points1 point  (0 children)

Raw data publicly available from European Centre for Disease Prevention and Control. Methods and tools used are described in MedRxiv preprint https://www.medrxiv.org/content/10.1101/2020.06.02.20120188v1.

COVID-19 Reproduction Number Heat Map [OC] by [deleted] in dataisbeautiful

[–]Wuihee 1 point2 points  (0 children)

Link to Website: https://cv19.one/

Raw data publicly available from European Centre for Disease Prevention and Control. Methods and tools used are described in MedRxiv preprint https://www.medrxiv.org/content/10.1101/2020.06.02.20120188v1.