As a secondary lock for the front wheel (even in the badlands of London) or a primary lock if in sight I have taken to using one of these.
https://www.decathlon.co.uk/500-bike-d-lock-blue-id_8342017.html
Actually mine only cost £3.50 in a sale and has I think a notch less security rating than that one.
I always have a pannier of some sort with me so I don't need something that will go in a jersey pocket or in my rectum.
It's pretty light and on tour I can keep it close to hand whereas the big D lock has to go at the back of a pannier with all my worldly goods stacked on top.
I used to use a cable for the front wheel but reckon this is better - it's not really much heavier, if at all, is more compact, easier to stash and I reckon ALL cable locks tempt thieves. Although this is an admittedly puny D lock I reckon a thief would still have to take a big hammer or power tool to it. And if they have those with them they can get through a "proper" D lock anyway. And steal a better looking bike. The bikes I ride aren't prime thief material for various reasons.
note - don't actually use cafes much as I'm very particular about my coffee. I'm more likely to be found at a Spoons and many of their more architecturally boring/modern branches have outside seating and often proper bike racks in clear sight. Such spoons establishments have powered two rides from Birmingham to London and almost 24 hours of ambling riding from London to Great Yarmouth - I commend their branches in Lowestoft and Great Yarmouth. Oh and Norwich by the river
and ...