You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I'm not mistaken, to_item() might return None. It seems errback should be called in this case.
There can be non-autoextract ways to get Product, so there should be a way to turn it off (or turn it on, depending on what the default we decide on). It could be a separate provider or an option.
The text was updated successfully, but these errors were encountered:
This is definitely a good idea. Asking for pages to get the items is very confusing and introduce a lot of boilerplate code.
If I'm not mistaken, to_item() might return None. It seems errback should be called in this case.
If we don't allow the None case, then we limit the functionality of this new approach. It wouldn't be entirely the same to use the product instead of the product page. I don't like that. We have to think twice regarding the None case and the error handling in general in the Page Objects model. We might decide to remove the option to return None but introduce some way to raise errors instead.
An idea: allow callbacks to request item classes directly. So, instead of writing one of those:
it would be possible to write
Edge cases:
The text was updated successfully, but these errors were encountered: