MCPcopy Index your code
hub / github.com/pathwaycom/pathway / without

Method without

python/pathway/internals/schema.py:399–414  ·  view source on GitHub ↗
(self, *args: str | expr.ColumnReference)

Source from the content-addressed store, hash-verified

397 return schema_builder(columns=columns, id_dtype=self.id.dtype)
398
399 def without(self, *args: str | expr.ColumnReference) -> type[Schema]:
400 columns: dict[str, ColumnDefinition] = {
401 col.name: col.to_definition() for col in self.__columns__.values()
402 }
403 for arg in args:
404 if isinstance(arg, str):
405 name = arg
406 else:
407 name = arg._name
408 try:
409 columns.pop(name)
410 except KeyError:
411 raise ValueError(
412 f"Schema.without() argument {name!r} has to refer to an existing column."
413 )
414 return schema_builder(columns=columns, id_dtype=self.id.dtype)
415
416 def with_id_type(self, type, *, append_only: bool | None = None):
417 type = dt.wrap(type)

Callers

nothing calls this directly

Calls 3

to_definitionMethod · 0.80
valuesMethod · 0.80
schema_builderFunction · 0.70

Tested by

no test coverage detected