Unit price located in the minimum purchase situation #1 #4

Closed
opened 2023-05-11 19:08:49 +02:00 by Karenzz · 1 comment
Member

When I verified the data accuracy I found that the script we used to locate the price only caught the total cost of the product once a consumer clicked the "Add to Cart" button, which caused a problem when a minimum purchase was required. For example, just like in Seattle (zipcode: 98134) the price we got is $3.98, but the actual price for a unit product should be $1.99.

I tried to locate the unit price in another script, but unfortunately I was stuck in getting the right price printed out. Could you please have a look at this issue? I put my works in fp2_12.py, and the code modified for this part is following the comment "# Extract the price of rice crackers for this zip code".

Thanks for any comments.

When I verified the data accuracy I found that the script we used to locate the price only caught the total cost of the product once a consumer clicked the "Add to Cart" button, which caused a problem when a minimum purchase was required. For example, just like in Seattle (zipcode: 98134) the price we got is $3.98, but the actual price for a unit product should be $1.99. I tried to locate the unit price in another script, but unfortunately I was stuck in getting the right price printed out. Could you please have a look at this issue? I put my works in fp2_12.py, and the code modified for this part is following the comment "# Extract the price of rice crackers for this zip code". Thanks for any comments.
Owner

@karenzz and I looked at it and I wrote some code to extract the minimum purchase element from the page if present, and a regex to extract the minimum quantity and total price from that element.

@karenzz and I looked at it and I wrote some code to extract the minimum purchase element from the page if present, and a regex to extract the minimum quantity and total price from that element.
j closed this issue 2023-05-15 23:19:22 +02:00
Sign in to join this conversation.
No labels
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: SVIG/python-bootcamp#4