Work done in #58 adds an ability to include or exclude single schema, but recently I've met the need to limit considered schemas to a list of them or symmetrically to exclude a list of schemas from consideration, hence this feature request. Also I'd like to submit a pull request with implementation.
As for implementation I see 2 possible ways:
- make
get_inspector() and schemainspect.pg.obj.PostgreSQL.filter_schema() to accept list of strings in schema and exclude_schema parameter. Here again we have 2 possibilities: accept list in addition to just string to keep old behaviour or accept only list and break compatibility
- treat
schema and include_schema parameters as regular expression patterns thus keeping function signature but slighly changing old behaviour: passing plain string would mean matching schema by given prefix
What do you think? Personally I lean towards the first alternative, i.e. accept a list of strings in addition to just string in corresponding function and method parameters.
Work done in #58 adds an ability to include or exclude single schema, but recently I've met the need to limit considered schemas to a list of them or symmetrically to exclude a list of schemas from consideration, hence this feature request. Also I'd like to submit a pull request with implementation.
As for implementation I see 2 possible ways:
get_inspector()andschemainspect.pg.obj.PostgreSQL.filter_schema()to accept list of strings inschemaandexclude_schemaparameter. Here again we have 2 possibilities: accept list in addition to just string to keep old behaviour or accept only list and break compatibilityschemaandinclude_schemaparameters as regular expression patterns thus keeping function signature but slighly changing old behaviour: passing plain string would mean matching schema by given prefixWhat do you think? Personally I lean towards the first alternative, i.e. accept a list of strings in addition to just string in corresponding function and method parameters.