i have xml and xpath i need to get value from xml using xpath not getting value
from fastapi import FastAPI
from xml.etree import ElementTree as ET
from lxml import etree
from io import StringIO
import lxml.etree
Select sibling node value based on multiple sibling conditions not using an xpath string
There are various answers to finding a xml node using xpath like here. In python using lxml is there a more pythonic way building this condition list? I know I can build the xpath sting using f-string but maybe there is a more elegant way.