pycharm-odoo icon indicating copy to clipboard operation
pycharm-odoo copied to clipboard

Plugin does not recognize xml_id when string is split in multiple lines

Open pnajman-modoolar opened this issue 1 year ago • 3 comments

PyCharm version 2023.1 Odoo plugin version: 2023.3.4.231

Works for "normal" xml_id strings Selection_873

But it doesn't work when the xml_id string is split in multiple lines Selection_874

pnajman-modoolar avatar Apr 01 '23 05:04 pnajman-modoolar

Hi @pnajman-modoolar . I already know this problem. However, this case is rare, so I haven't support it yet. Are you using multilines XML IDs in real work?

trinhanhngoc avatar Apr 01 '23 08:04 trinhanhngoc

Hi @pnajman-modoolar . I already know this problem. However, this case is rare, so I haven't support it yet. Are you using multilines XML IDs in real work?

Hi @trinhanhngoc,

Sometimes xml_ids can get get really long and then black will brake it down to match code line length rule.

This is not some everyday issue, but it can happen. No need for some high priority. It's for when you have some free time and nothing else to do :)

Cheers, Petar

pnajman-modoolar avatar Apr 01 '23 09:04 pnajman-modoolar

I have been doing some very long ones while using mapped method. For example when working with attribute values on product templates. So I have been forced to store the string on a variable, but then I then get a proper type guessing and all the other goodies.

So.... +1 to this.

jcfernandez-890825 avatar Apr 01 '23 14:04 jcfernandez-890825