advertools icon indicating copy to clipboard operation
advertools copied to clipboard

How to get started with development?

Open lakshaytalkstomachines opened this issue 1 year ago • 2 comments

Hi can we a have a small readme for how to get started with development?

  1. How can we build locally and pip install with -e.

lakshaytalkstomachines avatar Feb 21 '24 16:02 lakshaytalkstomachines

Thanks! I was considering this some time ago, and I guess it's time to provide proper instructions for dev installs.

Do you have any suggestions or recommendations for the library in the mean time?

eliasdabbas avatar Feb 21 '24 20:02 eliasdabbas

Yes i was thinking of creating a function for sitemaps which would convert sitemap to df but from local file instead of downloading it. Sometime requests time out for some sitemaps when downloading it from code but when as a human i go to browser it gives me it ( weird IK).

lakshaytalkstomachines avatar Feb 22 '24 13:02 lakshaytalkstomachines

This should be doable. It's actually in the plan, and should be straightforward to implement.

This line can be made optional if resp_headers is defined, so if you're offline you don't go there. Before that, the definition of resp_headers should also be optional with a try/except block (lines 488, 492).

This way you manually download a sitemap, then run the function from the file URL of the sitemap file.

Does this make sense, or did you have something else in mind?

eliasdabbas avatar Feb 22 '24 17:02 eliasdabbas

Yes this makes sense. I just faced some issues with setting up dev environment for this. I cloned the repo and tried to install it with pip install -e <path to repo>. Usually the changes in the source gets reflected in the installation but not with this though. Any clues to this? Maybe ill raise a PR for the same as well ?

lakshaytalkstomachines avatar Feb 22 '24 20:02 lakshaytalkstomachines

Please try the new path release: pip install advertools==0.14.2 I made checking for response headers optional, you can now manually install an XML sitemap and run the function locally on your computer. Let me know if you get any issues on this.

Thanks for letting me know about the local dev install. Can you please detail all steps you took?

  • Create a virtual environment
  • Activate it
  • Within this venv clone the repo git clone https://github.com/eliasdabbas/advertools.git
  • cd into the repo
  • Run pip install -e .

Let me know please if it still doesn't work. Thanks

eliasdabbas avatar Feb 24 '24 10:02 eliasdabbas

Assuming this is working, and closing the issue.

Feel free to re-open if you still have issues. Thanks.

eliasdabbas avatar Feb 28 '24 09:02 eliasdabbas

Sorry for the late reply. Yes this is working.

lakshaytalkstomachines avatar Feb 28 '24 20:02 lakshaytalkstomachines