ankane/pgsync · error · Error
Table not found in source: #{table.name}
Error message
Table not found in source: #{table.name} What it means
Error "Table not found in source: #{table.name}" thrown in ankane/pgsync.
Source
Thrown at lib/pgsync/task_resolver.rb:187
end
end
[groups, tables]
end
def no_schema_tables
@no_schema_tables ||= begin
search_path_index = source.search_path.map.with_index.to_h
source.tables.group_by(&:name).map do |group, t2|
[group, t2.select { |t| search_path_index[t.schema] }.sort_by { |t| search_path_index[t.schema] }.first]
end.to_h
end
end
# for tables without a schema, find the table in the search path
def fully_resolve(table, error: true)
return table if table.schema
resolved_table = no_schema_tables[table.name]
raise Error, "Table not found in source: #{table.name}" if !resolved_table && error
resolved_table
end
# parse command line arguments and YAML
def to_arr(value)
if value.is_a?(Array)
value
else
# Split by commas, but don't use commas inside double quotes
# https://stackoverflow.com/questions/21105360/regex-find-comma-not-inside-quotes
value.to_s.split(/(?!\B"[^"]*),(?![^"]*"\B)/)
end
end
def sql_arg
args[1]
end
View on GitHub (pinned to 57bdddf5db)
When it happens
Trigger: Thrown at lib/pgsync/task_resolver.rb:187 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of ankane/pgsync@57bdddf5db (2026-08-23).
Data as JSON: /api/errors/2d68fb4d3de7b4d5.
Report an issue: GitHub.