tomasbedrich / pycaching

A Python 3 interface for working with Geocaching.com website.
https://pycaching.readthedocs.io/
GNU Lesser General Public License v3.0
61 stars 46 forks source link

No current way to get the raw HTML cache description #216

Closed DarkOutcast6 closed 1 year ago

DarkOutcast6 commented 1 year ago

There is no current way to get a raw HTML cache description (at least that I know)

FriedrichFroebel commented 1 year ago

This is correct. Feel free to submit a PR for adding a new description_html attribute.

DarkOutcast6 commented 1 year ago

@FriedrichFroebel What library do you use to strip the geocaching website? I’ll try my best to find a way to get the raw HTML version of the description.

FriedrichFroebel commented 1 year ago

While I like to support users with their use cases of pycaching, I recommend you to check out the existing documentation before asking rather trivial questions. In this case, you will find a corresponding paragraph in the docs and inside the README: https://pycaching.readthedocs.io/en/latest/quickstart.html There you can read that pycaching has four direct dependencies (three if you ignore Python itself); this will reveal that beautifulsoup4 is responsible for parsing. description basically is soup.text, description_html should probably become str(soup) or similar.

By the way: No need to always mention me here explicitly. Being a collaborator, I have enabled all notifications for this repository and thus get notified anyway.

DarkOutcast6 commented 1 year ago

Just made a pull request for this issue. Pull request number is #218. It would be great if you could explain what I need to add to make it be usable for the user.

Thank you so much for the help, though!

FriedrichFroebel commented 1 year ago

By adding a simple test you should be able to ensure that the attribute can indeed be accessed and contains the correct data. Documentation is already present, so at least in theory this should be sufficient to make it usable.