class_docstr: Figures out what linkable specs are valid for a given metric.
  
  e.g. Can you query the metric "bookings" by "listing__country_latest"?
docstr: Generate the set of possible paths that are 1 semantic model join longer that the "current_join_path".
docstr_tok: ["Generate","the","set","of","possible","paths","that","are","1","semantic","model","join","longer","that","the","``","current_join_path","''","."]
code: def _find_next_possible_paths(
      self,
      measure_semantic_model: SemanticModel,
      current_join_path: SemanticModelJoinPath,
  ) -> Sequence[SemanticModelJoinPath]:
      """Generate the set of possible paths that are 1 semantic model join longer that the "current_join_path"."""
      last_semantic_model_in_path = (
          self._semantic_model_lookup.get_by_reference(
              current_join_path.last_semantic_model_reference
          )
      )
      assert last_semantic_model_in_path
      new_join_paths = []
  
      for entity in last_semantic_model_in_path.entities:
          entity_reference = entity.reference
  
          # Don't create cycles in the join path by joining on the same entity.
          if entity_reference in set(
              x.join_on_entity for x in current_join_path.path_elements
          ):
              continue
  
          semantic_models_that_can_be_joined = self._get_semantic_models_with_joinable_entity(
              left_semantic_model_reference=last_semantic_model_in_path.reference,
              entity_reference=entity.reference,
          )
          for semantic_model in semantic_models_that_can_be_joined:
              # Don't create cycles in the join path by repeating a semantic model in the path.
              if (
                  semantic_model.name == measure_semantic_model.name
                  or any(
                      tuple(
                          path_element.semantic_model_reference
                          == semantic_model.reference
                          for path_element in current_join_path.path_elements
                      )
                  )
              ):
                  continue
  
              new_join_path = SemanticModelJoinPath(
                  path_elements=current_join_path.path_elements
                  + (
                      SemanticModelJoinPathElement(
                          semantic_model_reference=semantic_model.reference,
                          join_on_entity=entity_reference,
                      ),
                  )
              )
              new_join_paths.append(new_join_path)
  
      return new_join_paths
  
imports: from __future__ import annotations
  import logging
  import time
  from collections import defaultdict
  from dataclasses import dataclass
  from typing import Dict, FrozenSet, List, Optional, Sequence, Set, Tuple
  from dbt_semantic_interfaces.enum_extension import assert_values_exhausted
  from dbt_semantic_interfaces.pretty_print import pformat_big_objects
  from dbt_semantic_interfaces.protocols.dimension import Dimension, DimensionType
  from dbt_semantic_interfaces.protocols.semantic_manifest import SemanticManifest
  from dbt_semantic_interfaces.protocols.semantic_model import SemanticModel
  from dbt_semantic_interfaces.references import DimensionReference, MeasureReference, MetricReference, SemanticModelReference, TimeDimensionReference
  from dbt_semantic_interfaces.type_enums import MetricType
  from dbt_semantic_interfaces.type_enums.date_part import DatePart
  from dbt_semantic_interfaces.type_enums.time_granularity import TimeGranularity
  from metricflow.dataset.dataset import DataSet
  from metricflow.errors.errors import UnknownMetricLinkingError
  from metricflow.model.semantics.linkable_element_properties import LinkableElementProperties
  from metricflow.model.semantics.semantic_model_join_evaluator import SemanticModelJoinEvaluator
  from metricflow.model.semantics.semantic_model_lookup import SemanticModelLookup
  from metricflow.protocols.semantics import SemanticModelAccessor
  from metricflow.specs.specs import DEFAULT_TIME_GRANULARITY, DimensionSpec, EntityReference, EntitySpec, LinkableSpecSet, TimeDimensionSpec
label_desc: Use image node_id 12 for calling the ValidLinkableSpecResolver obj's underlying member method code with example usage: obj._find_next_possible_paths(measure_semantic_model, current_join_path) and returns: new_join_paths