scrapinghub / dateparser

python parser for human readable dates
BSD 3-Clause "New" or "Revised" License
2.55k stars 465 forks source link

Dateparser online demo #882

Closed vimtor closed 3 years ago

vimtor commented 3 years ago

Hi there!

The first time I used dateparser I missed a simple way to try it out for my use case. Since it is an awesome package, I've built an online demo of the library so users can try it out.

Here it is

Maybe you want to add it to your docs 😉

noviluni commented 3 years ago

Hi @vimtor!

Thank you for building this! You did a really nice job!

I would love to add it to the README, but would you mind adding a small note like "powered by dateparser" or something similar pointing to this Github repository and/or the PyPI package link? I found a link to the docs when clicking the image, but it's a little bit hidden.

I also would love if you add a Free/Open Source license to your Github project, in that way we will be able to submit PRs like adding support for settings, etc, and the process will be more transparent. :)

Of course, both things are up to you, this doesn't block adding this link to our Readme. I added a PR with the URL: https://github.com/scrapinghub/dateparser/pull/883 Let me know what you think! :)

vimtor commented 3 years ago

Hey @noviluni! Thanks! Glad you liked it ❤

I did it on twitch while streaming, so it was quite improvised.

I will add both things you mention, once they are online I'll let you know

vimtor commented 3 years ago

Done! I added both the copy on the web and the license in the repo.

noviluni commented 3 years ago

I merged the PR. thanks @vimtor ! :smile:

ernstki commented 1 year ago

Hi all,

The demo site is currently returning a 404 with the following error (copy-pasted from Chrome's dev tools)

Access to fetch at 'https://dateparser-demo-production.up.railway.app/?text=three%20days%20ago&timezone=America/New_York' from origin 'https://dateparser-demo.netlify.app' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.

Firefox gives a similar error:

Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at https://dateparser-demo-production.up.railway.app/?text=three%20days%20ago&timezone=America/New_York. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing). Status code: 404.

I am not well-versed in these kinds of errors, but I assume this is a server-side rather than a client-side problem. Would you like an issue opened here, or in @vimtor's repository?

vimtor commented 1 year ago

With the whole Heroku thing I had to move it to other place but I don't want it to consume my free tier. Could you host it yourself and I change the endpoint?

ernstki commented 1 year ago

Sadly, I don't have the skills or the wherewithal to host it, no. Perhaps the thing to do is remove it from the README (for now) and open a new issue to see if somebody else has ideas for the hosting?