Skip to main content

extract_file_path

Function extract_file_path 

Source
pub fn extract_file_path(node_id: &str) -> Option<String>
Expand description

Extract file path from a CodeNode ID.

IDs follow the pattern prefix:path/to/file.py::Name. This extracts path/to/file.py.

Examples:

  • "func:brain/signal.py::fuse"Some("brain/signal.py")
  • "mod:brain/signal.py"Some("brain/signal.py")
  • "method:brain/store.py::Dual::get"Some("brain/store.py")