csvpath 0.0.528__tar.gz → 0.0.529__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {csvpath-0.0.528 → csvpath-0.0.529}/PKG-INFO +1 -1
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/csvpaths.py +23 -3
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/files/file_manager.py +11 -18
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/files/file_registrar.py +0 -30
- csvpath-0.0.529/csvpath/util/reference_finder.py +289 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/reference_parser.py +2 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/pyproject.toml +1 -1
- {csvpath-0.0.528 → csvpath-0.0.529}/LICENSE +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/README.md +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/config/config.ini +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/config/function.imports +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/config/jenkins-local-sftp.ini +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/config/jenkins-s3.ini +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/integrations/sftpplus/handle_auto_arrival.bat +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/integrations/sftpplus/handle_auto_arrival.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/integrations/sftpplus/handle_auto_arrival.sh +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/integrations/sftpplus/handle_mailbox_arrival.bat +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/integrations/sftpplus/handle_mailbox_arrival.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/integrations/sftpplus/handle_mailbox_arrival.sh +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/integrations/sqlite/csvpath +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/assets/integrations/sqlite/schema.sql +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/config/config.ini +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/__init__.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/__init__.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/asker.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/cli.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/const.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/debug_config.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/drill_down.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/function_describer.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/function_lister.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/cli/selecter.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/csvpath.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/__init__.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/errors/error.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/errors/error_collector.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/errors/error_comms.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/errors/error_manager.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/files/file_metadata.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/files/files_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/files/lines_and_headers_cacher.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ckan/ckan.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ckan/ckan_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ckan/datafile.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ckan/dataset.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/event.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/event_result.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/file_listener_ol.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/job.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/ol_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/paths_listener_ol.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/result_listener_ol.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/results_listener_ol.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/run.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/run_listener_ol.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/run_state.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/ol/sender.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/error_metrics.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/metrics.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/otlp_error_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/otlp_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/otlp_result_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/otlp_results_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftp/sftp_sender.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftpplus/arrival_handler.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftpplus/rpc.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftpplus/sftpplus_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftpplus/transfer_creator.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftpplus/transfers.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/slack/event.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/slack/sender.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sqlite/schema.sql +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sqlite/sqlite_result_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sqlite/sqlite_results_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/metadata.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/paths/paths_listener.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/paths/paths_manager.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/paths/paths_metadata.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/paths/paths_registrar.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/registrar.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/readers/file_errors_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/readers/file_lines_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/readers/file_printouts_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/readers/file_unmatched_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/readers/readers.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/result.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/result_file_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/result_metadata.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/result_registrar.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/result_serializer.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/results_manager.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/results_metadata.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/results/results_registrar.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/run/run_listener_stdout.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/run/run_metadata.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/run/run_registrar.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/__init__.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/__init__.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/args.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/args_helper.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/all.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/andf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/any.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/between.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/empty.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/exists.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/inf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/no.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/notf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/orf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/boolean/yes.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/count.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/count_bytes.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/count_headers.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/count_lines.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/count_scans.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/counter.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/every.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/has_matches.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/increment.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/tally.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/counting/total_lines.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/dates/now.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/function.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/function_factory.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/function_finder.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/function_focus.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/append.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/collect.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/empty_stack.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/end.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/header_name.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/header_names_mismatch.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/headers.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/insert.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/mismatch.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/replace.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/headers/reset_headers.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/lines/advance.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/lines/after_blank.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/lines/dups.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/lines/first.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/lines/first_line.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/lines/last.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/lines/stop.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/above.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/add.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/divide.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/equals.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/intf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/mod.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/multiply.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/odd.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/round.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/subtotal.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/subtract.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/math/sum.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/misc/fingerprint.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/misc/importf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/misc/random.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/print/jinjaf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/print/print_line.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/print/print_queue.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/print/printf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/print/table.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/stats/minf.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/stats/percent.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/stats/percent_unique.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/stats/stdev.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/alter.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/caps.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/concat.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/contains.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/length.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/lower.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/metaphone.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/regex.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/starts_with.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/strip.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/substring.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/strings/upper.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/testing/debug.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/__init__.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/boolean.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/datef.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/decimal.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/email.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/nonef.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/string.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/type.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/types/url.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/validity/fail.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/validity/failed.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/validity/line.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/variables/get.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/variables/pushpop.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/variables/put.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/variables/track.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/functions/variables/variables.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/lark_parser.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/lark_transformer.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/matcher.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/__init__.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/equality.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/expression.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/header.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/matchable.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/qualified.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/reference.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/term.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/productions/variable.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/util/exceptions.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/util/expression_encoder.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/util/expression_utility.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/util/lark_print_parser.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/util/print_parser.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/matching/util/runtime_data_collector.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/error_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/explain_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/files_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/logic_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/mode_controller.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/print_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/return_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/run_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/source_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/transfer_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/unmatched_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/modes/validation_mode.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/scanning/__init__.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/scanning/exceptions.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/scanning/parser.out +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/scanning/parsetab.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/scanning/scanner.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/scanning/scanning_lexer.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/box.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/cache.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/caser.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/class_loader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/code.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/config.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/config_exception.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/exceptions.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/file_info.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/file_readers.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/file_writers.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/hasher.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/intermediary.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/last_line_stats.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/line_counter.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/line_monitor.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/line_spooler.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/log_utility.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/metadata_parser.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/nos.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/pandas_data_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/printer.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/s3/s3_data_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/s3/s3_data_writer.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/s3/s3_fingerprinter.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/s3/s3_nos.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/s3/s3_utils.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/s3/s3_xlsx_data_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/sftp/sftp_config.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/sftp/sftp_data_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/sftp/sftp_data_writer.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/sftp/sftp_fingerprinter.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/sftp/sftp_nos.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/sftp/sftp_xlsx_data_reader.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/sqliter.py +0 -0
- {csvpath-0.0.528 → csvpath-0.0.529}/csvpath/util/var_utility.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: csvpath
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.529
|
|
4
4
|
Summary: A data preboarding framework for managing and validating CSV, Excel, and other tabular data files using a Collect, Store, Validate, Publish pattern to create a trusted publisher for downstream data consumers.
|
|
5
5
|
Author: David Kershaw
|
|
6
6
|
Author-email: dk107dk@hotmail.com
|
|
@@ -395,12 +395,34 @@ class CsvPaths(CsvPathsCoordinator, ErrorCollector):
|
|
|
395
395
|
# if we're in source-mode: preceding, but that doesn't matter from the
|
|
396
396
|
# pov of the reference.
|
|
397
397
|
#
|
|
398
|
+
"""
|
|
398
399
|
if filename.startswith("$"):
|
|
400
|
+
#
|
|
401
|
+
# this should already have been done in FileManager. get_named_file looks for '$' and
|
|
402
|
+
# delegates references to results manager, same as below. that value comes in here as
|
|
403
|
+
# the local file var, same as we set below.
|
|
404
|
+
#
|
|
405
|
+
# verified and cleaned up. delete when ready!
|
|
406
|
+
#
|
|
399
407
|
self.logger.debug(
|
|
400
408
|
"File name is a reference: %s. Replacing the path passed in with the reffed data file path.",
|
|
401
409
|
filename,
|
|
402
410
|
)
|
|
403
|
-
|
|
411
|
+
#
|
|
412
|
+
# find file from two types of references: file and results
|
|
413
|
+
# -- results ref is to a sourcemode preceding output or a reference to a result from some run:
|
|
414
|
+
# $sourcemode.results.202:last.source1
|
|
415
|
+
# -- file reference is to a prior version of a file
|
|
416
|
+
# $myfilename.files.3
|
|
417
|
+
# $myfilename.files.yesterday:last
|
|
418
|
+
# $myfilename.files.today:last
|
|
419
|
+
# $myfilename.files.[today|yesterday|yyyy-mm-dd_hh-mm-ss|number|fingerprint]:[last|first|number]
|
|
420
|
+
#
|
|
421
|
+
#
|
|
422
|
+
|
|
423
|
+
file2 = self.results_manager.data_file_for_reference(filename, not_name=crt)
|
|
424
|
+
assert file == file2
|
|
425
|
+
"""
|
|
404
426
|
#
|
|
405
427
|
#
|
|
406
428
|
#
|
|
@@ -541,8 +563,6 @@ class CsvPaths(CsvPathsCoordinator, ErrorCollector):
|
|
|
541
563
|
#
|
|
542
564
|
result.unmatched = csvpath.unmatched
|
|
543
565
|
except Exception as ex: # pylint: disable=W0718
|
|
544
|
-
# ex.trace = traceback.format_exc()
|
|
545
|
-
# ex.source = self
|
|
546
566
|
if self.error_manager.csvpaths is None:
|
|
547
567
|
raise Exception("ErrorManager's CsvPaths cannot be None")
|
|
548
568
|
self.error_manager.handle_error(source=self, msg=f"{ex}")
|
|
@@ -6,6 +6,7 @@ from json import JSONDecodeError
|
|
|
6
6
|
from csvpath.util.file_readers import DataFileReader
|
|
7
7
|
from csvpath.util.file_writers import DataFileWriter
|
|
8
8
|
from csvpath.util.reference_parser import ReferenceParser
|
|
9
|
+
from csvpath.util.reference_finder import ReferenceFinder
|
|
9
10
|
from csvpath.util.exceptions import InputException, FileException
|
|
10
11
|
from csvpath.util.nos import Nos
|
|
11
12
|
from csvpath.util.box import Box
|
|
@@ -86,11 +87,6 @@ class FileManager:
|
|
|
86
87
|
if nos.exists():
|
|
87
88
|
m = self.registrar.get_manifest(path)
|
|
88
89
|
return m["uuid"]
|
|
89
|
-
"""
|
|
90
|
-
with DataFileReader(path) as reader:
|
|
91
|
-
m = json.load(reader.source)
|
|
92
|
-
return m["uuid"]
|
|
93
|
-
"""
|
|
94
90
|
else:
|
|
95
91
|
path = self.named_file_home(name)
|
|
96
92
|
path = os.path.join(path, "manifest.json")
|
|
@@ -99,12 +95,6 @@ class FileManager:
|
|
|
99
95
|
if nos.exists():
|
|
100
96
|
m = self.registrar.get_manifest(path)
|
|
101
97
|
return m[len(m) - 1]["uuid"]
|
|
102
|
-
|
|
103
|
-
"""
|
|
104
|
-
with DataFileReader(path) as reader:
|
|
105
|
-
m = json.load(reader.source)
|
|
106
|
-
return m[len(m) - 1]["uuid"]
|
|
107
|
-
"""
|
|
108
98
|
raise ValueError(f"No manifest for file named {name}")
|
|
109
99
|
|
|
110
100
|
#
|
|
@@ -336,14 +326,17 @@ class FileManager:
|
|
|
336
326
|
#
|
|
337
327
|
def get_named_file(self, name: str) -> str:
|
|
338
328
|
ret = None
|
|
329
|
+
#
|
|
330
|
+
# references can be to results or to prior versions of a file. in
|
|
331
|
+
# prior file version references we can do:
|
|
332
|
+
# $myfilename.files.index
|
|
333
|
+
# $myfilename.files.[yesterday|today]:[last|first|index]
|
|
334
|
+
# $myfilename.files.fingerprint
|
|
335
|
+
# $myfilename.files.[yyyy-mm-dd_hh-mm-ss]:[before|after|None]
|
|
336
|
+
#
|
|
339
337
|
if name.startswith("$"):
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
raise InputException(
|
|
343
|
-
f"Reference datatype must be {ReferenceParser.RESULTS}"
|
|
344
|
-
)
|
|
345
|
-
reman = self._csvpaths.results_manager
|
|
346
|
-
ret = reman.data_file_for_reference(name)
|
|
338
|
+
reff = ReferenceFinder(self._csvpaths, name)
|
|
339
|
+
ret = reff.resolve()
|
|
347
340
|
else:
|
|
348
341
|
if not self.name_exists(name):
|
|
349
342
|
return None
|
|
@@ -54,13 +54,6 @@ class FileRegistrar(Registrar, Listener):
|
|
|
54
54
|
j = []
|
|
55
55
|
self.intermediary.put_json(mpath, j)
|
|
56
56
|
return j
|
|
57
|
-
"""
|
|
58
|
-
try:
|
|
59
|
-
with DataFileReader(mpath) as reader:
|
|
60
|
-
return json.load(reader.source)
|
|
61
|
-
except FileNotFoundError:
|
|
62
|
-
return []
|
|
63
|
-
"""
|
|
64
57
|
|
|
65
58
|
def metadata_update(self, mdata: Metadata) -> None:
|
|
66
59
|
path = mdata.origin_path
|
|
@@ -81,12 +74,7 @@ class FileRegistrar(Registrar, Listener):
|
|
|
81
74
|
mani["mark"] = mark
|
|
82
75
|
jdata = self.get_manifest(manifest_path)
|
|
83
76
|
jdata.append(mani)
|
|
84
|
-
# self.intermediary.clear(manifest_path)
|
|
85
77
|
self.intermediary.put_json(manifest_path, jdata)
|
|
86
|
-
"""
|
|
87
|
-
with DataFileWriter(path=manifest_path, mode="w") as writer:
|
|
88
|
-
json.dump(jdata, writer.sink, indent=2)
|
|
89
|
-
"""
|
|
90
78
|
#
|
|
91
79
|
# drop update into an all-inputs/files record here?
|
|
92
80
|
#
|
|
@@ -178,21 +166,3 @@ class FileRegistrar(Registrar, Listener):
|
|
|
178
166
|
if mark is not None:
|
|
179
167
|
path = f"{path}#{mark}"
|
|
180
168
|
return path
|
|
181
|
-
"""
|
|
182
|
-
with DataFileReader(mpath) as reader:
|
|
183
|
-
mdata = json.load(reader.source)
|
|
184
|
-
if mdata is None or len(mdata) == 0:
|
|
185
|
-
raise InputException(f"Manifest for {home} at {mpath} is empty")
|
|
186
|
-
m = mdata[len(mdata) - 1]
|
|
187
|
-
if "file" not in m:
|
|
188
|
-
raise ValueError(
|
|
189
|
-
"File path cannot be None. Check your config file and named-files."
|
|
190
|
-
)
|
|
191
|
-
path = m["file"]
|
|
192
|
-
mark = None
|
|
193
|
-
if "mark" in m:
|
|
194
|
-
mark = m["mark"]
|
|
195
|
-
if mark is not None:
|
|
196
|
-
path = f"{path}#{mark}"
|
|
197
|
-
return path
|
|
198
|
-
"""
|
|
@@ -0,0 +1,289 @@
|
|
|
1
|
+
# pylint: disable=C0114
|
|
2
|
+
from datetime import timedelta
|
|
3
|
+
import datetime
|
|
4
|
+
|
|
5
|
+
from csvpath.util.reference_parser import ReferenceParser
|
|
6
|
+
|
|
7
|
+
# TODO: probably we should hoist up expr utility, but for now leaving it in matching
|
|
8
|
+
from csvpath.matching.util.expression_utility import ExpressionUtility
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class ReferenceFinder:
|
|
12
|
+
def __init__(self, csvpaths, name) -> None:
|
|
13
|
+
...
|
|
14
|
+
|
|
15
|
+
def resolve(self) -> str:
|
|
16
|
+
...
|
|
17
|
+
|
|
18
|
+
def __new__(cls, csvpaths, name):
|
|
19
|
+
if cls == ReferenceFinder:
|
|
20
|
+
ref = ReferenceParser(name)
|
|
21
|
+
if ref.datatype == ReferenceParser.FILES:
|
|
22
|
+
return FilesReferenceFinder(csvpaths, ref=ref, name=name)
|
|
23
|
+
elif ref.datatype == ReferenceParser.RESULTS:
|
|
24
|
+
return ResultsReferenceFinder(csvpaths, name=name)
|
|
25
|
+
else:
|
|
26
|
+
raise ValueError(
|
|
27
|
+
f"Reference datatype must be in [{ReferenceParser.RESULTS}, {ReferenceParser.FILES}]"
|
|
28
|
+
)
|
|
29
|
+
else:
|
|
30
|
+
instance = super().__new__(cls)
|
|
31
|
+
return instance
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class FilesReferenceFinder:
|
|
35
|
+
#
|
|
36
|
+
# references to prior versions of a file
|
|
37
|
+
# >> by index:
|
|
38
|
+
# $myfilename.files.3
|
|
39
|
+
# >> by day [today|yesterday] and [:first|:last|:index]:
|
|
40
|
+
# $myfilename.files.yesterday:last
|
|
41
|
+
# >> by date and [:before|:after|None]:
|
|
42
|
+
# $myfilename.files.2025-01-01_14-30-00:before
|
|
43
|
+
# >> by fingerprint:
|
|
44
|
+
# $myfilename.files.12467d811d1589ede586e3a42c41046641bedc1c73941f4c21e2fd2966f188b4
|
|
45
|
+
#
|
|
46
|
+
def __init__(self, csvpaths, *, ref, name) -> None:
|
|
47
|
+
self._csvpaths = csvpaths
|
|
48
|
+
self._ref = ref
|
|
49
|
+
self._name = name
|
|
50
|
+
self._mani = None
|
|
51
|
+
|
|
52
|
+
def resolve(self) -> str:
|
|
53
|
+
n = self._ref.name_one
|
|
54
|
+
#
|
|
55
|
+
# fingerprint
|
|
56
|
+
#
|
|
57
|
+
file = self._path_for_fingerprint_if(n)
|
|
58
|
+
if file is not None:
|
|
59
|
+
return file
|
|
60
|
+
#
|
|
61
|
+
# index
|
|
62
|
+
#
|
|
63
|
+
file = self._path_for_index_if(n)
|
|
64
|
+
if file is not None:
|
|
65
|
+
return file
|
|
66
|
+
#
|
|
67
|
+
# day
|
|
68
|
+
#
|
|
69
|
+
file = self._path_for_day_if(n)
|
|
70
|
+
if file is not None:
|
|
71
|
+
return file
|
|
72
|
+
#
|
|
73
|
+
# date
|
|
74
|
+
#
|
|
75
|
+
file = self._path_for_date_if(n)
|
|
76
|
+
if file is not None:
|
|
77
|
+
return file
|
|
78
|
+
raise ValueError(f"Reference {self._name} is not valid")
|
|
79
|
+
|
|
80
|
+
def _is_day(self) -> bool:
|
|
81
|
+
n = self._ref.name_one
|
|
82
|
+
if n.find(":"):
|
|
83
|
+
n = n[0 : n.find(":")]
|
|
84
|
+
return n in ["yesterday", "today"]
|
|
85
|
+
|
|
86
|
+
def _path_for_day_if(self) -> str:
|
|
87
|
+
if self._is_day():
|
|
88
|
+
day = None
|
|
89
|
+
pointer = None
|
|
90
|
+
n = self._ref.name_one
|
|
91
|
+
i = n.find(":")
|
|
92
|
+
if i > -1:
|
|
93
|
+
day = n[0:i]
|
|
94
|
+
pointer = n[i + 1 :]
|
|
95
|
+
else:
|
|
96
|
+
day = n
|
|
97
|
+
pointer = "last"
|
|
98
|
+
pointer = self._pointer(n, "last")
|
|
99
|
+
dat = None
|
|
100
|
+
if day == "today":
|
|
101
|
+
dat = datetime.date.today()
|
|
102
|
+
if day == "yesterday":
|
|
103
|
+
dat = datetime.date.today() - timedelta(days=1)
|
|
104
|
+
ds = self._list_of_records_by_date(dat)
|
|
105
|
+
if pointer == "last":
|
|
106
|
+
return ds[len(ds) - 1]["file"]
|
|
107
|
+
if pointer == "first":
|
|
108
|
+
return ds[0]["file"]
|
|
109
|
+
i = ExpressionUtility.to_int(pointer)
|
|
110
|
+
if not isinstance(i, int):
|
|
111
|
+
raise ValueError(
|
|
112
|
+
f"Pointer {pointer} should be :first, :last, or :N where N is an int"
|
|
113
|
+
)
|
|
114
|
+
return ds[i]["file"]
|
|
115
|
+
|
|
116
|
+
def _path_for_date_if(self) -> str:
|
|
117
|
+
s = self._complete_date_string()
|
|
118
|
+
dat = datetime.datetime.strptime(s, "%Y-%m-%d_%H-%M-%S")
|
|
119
|
+
pointer = self._pointer(self._ref.name_one, "after")
|
|
120
|
+
return self._find_in_date(dat, pointer)
|
|
121
|
+
|
|
122
|
+
def _list_of_records_by_date(self, adate=None) -> list:
|
|
123
|
+
mani = self.manifest
|
|
124
|
+
lst = []
|
|
125
|
+
for _ in mani:
|
|
126
|
+
t = _["time"]
|
|
127
|
+
td = ExpressionUtility.to_datetime(t)
|
|
128
|
+
if adate is None:
|
|
129
|
+
lst.append(_)
|
|
130
|
+
elif (
|
|
131
|
+
adate.year == td.year
|
|
132
|
+
and adate.month == td.month
|
|
133
|
+
and adate.day == td.day
|
|
134
|
+
):
|
|
135
|
+
lst.append(_)
|
|
136
|
+
return lst
|
|
137
|
+
|
|
138
|
+
def _find_in_date(self, adate, pointer) -> list:
|
|
139
|
+
mani = self.manifest
|
|
140
|
+
lst = []
|
|
141
|
+
for _ in mani:
|
|
142
|
+
t = mani["time"]
|
|
143
|
+
td = ExpressionUtility.to_datetime(t)
|
|
144
|
+
lst.append(td)
|
|
145
|
+
#
|
|
146
|
+
# find the right date
|
|
147
|
+
#
|
|
148
|
+
i = self._find_in_dates(lst, adate, pointer)
|
|
149
|
+
if i is None:
|
|
150
|
+
return None
|
|
151
|
+
return mani[i]["file"]
|
|
152
|
+
|
|
153
|
+
def _find_in_dates(
|
|
154
|
+
self, lst: list[datetime.datetime], adate: datetime.datetime, pointer: str
|
|
155
|
+
) -> str:
|
|
156
|
+
for i, d in enumerate(lst):
|
|
157
|
+
if pointer == "before":
|
|
158
|
+
if d > adate:
|
|
159
|
+
if i == 0:
|
|
160
|
+
return None
|
|
161
|
+
else:
|
|
162
|
+
return i - 1
|
|
163
|
+
elif pointer == "after":
|
|
164
|
+
if d > adate:
|
|
165
|
+
return i
|
|
166
|
+
elif pointer is None:
|
|
167
|
+
if (
|
|
168
|
+
d.year == adate.year
|
|
169
|
+
and d.month == adate.month
|
|
170
|
+
and d.day == adate.day
|
|
171
|
+
and d.hour == adate.hour
|
|
172
|
+
and d.minute == adate.minute
|
|
173
|
+
and d.second == adate.second
|
|
174
|
+
):
|
|
175
|
+
return i
|
|
176
|
+
else:
|
|
177
|
+
raise ValueError(
|
|
178
|
+
f"Pointer {pointer} is incorrect. Only 'before' and 'after' are allowed"
|
|
179
|
+
)
|
|
180
|
+
return None
|
|
181
|
+
|
|
182
|
+
def _complete_date_string(self) -> str:
|
|
183
|
+
n = self._not_pointer(self._ref.name_one)
|
|
184
|
+
dat = ""
|
|
185
|
+
chk = 0
|
|
186
|
+
for c in n:
|
|
187
|
+
#
|
|
188
|
+
# 2025-03-23_13-30-00
|
|
189
|
+
#
|
|
190
|
+
# print(f"n[{chk}] = {c}")
|
|
191
|
+
if chk == 0:
|
|
192
|
+
if c != "2":
|
|
193
|
+
raise ValueError(
|
|
194
|
+
f"Character in position {chk} of date string {n} must be 2"
|
|
195
|
+
)
|
|
196
|
+
elif chk == 1:
|
|
197
|
+
if c != "0":
|
|
198
|
+
raise ValueError(
|
|
199
|
+
f"Character in position {chk} of date string {n} must be 0"
|
|
200
|
+
)
|
|
201
|
+
elif chk in [2, 3, 6, 12, 15, 18]:
|
|
202
|
+
if c not in ["1", "2", "3", "4", "5", "6", "7", "8", "9", "0"]:
|
|
203
|
+
raise ValueError(
|
|
204
|
+
f"Character in position {chk} of date string {n} must be an integer"
|
|
205
|
+
)
|
|
206
|
+
elif chk in [4, 7, 13, 16] and c != "-":
|
|
207
|
+
raise ValueError(
|
|
208
|
+
f"Character in position 5 of date string {n} must be a '-'"
|
|
209
|
+
)
|
|
210
|
+
elif chk == 5:
|
|
211
|
+
if c not in ["0", "1", "2", "3"]:
|
|
212
|
+
raise ValueError(
|
|
213
|
+
f"Character in position {chk} of date string {n} must be 0 - 3"
|
|
214
|
+
)
|
|
215
|
+
elif chk == 11:
|
|
216
|
+
if c not in ["0", "1", "2"]:
|
|
217
|
+
raise ValueError(
|
|
218
|
+
f"Character in position {chk} of date string {n} must be 0 - 2"
|
|
219
|
+
)
|
|
220
|
+
elif chk in [14, 17]:
|
|
221
|
+
if c not in ["0", "1", "2", "3", "4", "5"]:
|
|
222
|
+
raise ValueError(
|
|
223
|
+
f"Character in position {chk} of date string {n} must be 0 - 5"
|
|
224
|
+
)
|
|
225
|
+
elif chk == 10:
|
|
226
|
+
if c != "_":
|
|
227
|
+
raise ValueError(
|
|
228
|
+
"Character in position {chk} of date string {n} must be an '_'"
|
|
229
|
+
)
|
|
230
|
+
chk += 1
|
|
231
|
+
|
|
232
|
+
t = "2025-01-01_00-00-00"
|
|
233
|
+
dat = n
|
|
234
|
+
dat = f"{n}{t[chk:]}"
|
|
235
|
+
print(f"dat: {dat}")
|
|
236
|
+
return dat
|
|
237
|
+
|
|
238
|
+
def _pointer(self, n: str, default: str = None) -> str:
|
|
239
|
+
if n is None:
|
|
240
|
+
return None
|
|
241
|
+
if n.find(":") == -1:
|
|
242
|
+
return default
|
|
243
|
+
return n[n.find(":") + 1 :]
|
|
244
|
+
|
|
245
|
+
def _not_pointer(self, n: str) -> str:
|
|
246
|
+
if n is None:
|
|
247
|
+
return None
|
|
248
|
+
if n.find(":") == -1:
|
|
249
|
+
return n
|
|
250
|
+
return n[0 : n.find(":")]
|
|
251
|
+
|
|
252
|
+
def _path_for_fingerprint_if(self) -> str:
|
|
253
|
+
n = self._ref.name_one
|
|
254
|
+
mani = self.manifest
|
|
255
|
+
for r in mani:
|
|
256
|
+
if r.get("fingerprint") == n:
|
|
257
|
+
return r.get("file")
|
|
258
|
+
|
|
259
|
+
def _path_for_index_if(self) -> str:
|
|
260
|
+
n = self._ref.name_one
|
|
261
|
+
if not ExpressionUtility.is_number(n):
|
|
262
|
+
return
|
|
263
|
+
n = ExpressionUtility.to_int(n)
|
|
264
|
+
mani = self.manifest
|
|
265
|
+
for i, r in enumerate(mani):
|
|
266
|
+
if n == i:
|
|
267
|
+
return r.get("file")
|
|
268
|
+
|
|
269
|
+
@property
|
|
270
|
+
def manifest(self):
|
|
271
|
+
if self._mani is None:
|
|
272
|
+
fm = self._csvpaths.file_manager
|
|
273
|
+
r = fm.registrar
|
|
274
|
+
rm = self._ref.root_major
|
|
275
|
+
home = fm.named_file_home(rm)
|
|
276
|
+
mani_path = r.manifest_path(home)
|
|
277
|
+
self._mani = r.get_manifest(mani_path)
|
|
278
|
+
return self._mani
|
|
279
|
+
|
|
280
|
+
|
|
281
|
+
class ResultsReferenceFinder:
|
|
282
|
+
def __init__(self, csvpaths, *, name) -> None:
|
|
283
|
+
self._csvpaths = csvpaths
|
|
284
|
+
self._name = name
|
|
285
|
+
|
|
286
|
+
def resolve(self) -> str:
|
|
287
|
+
reman = self._csvpaths.results_manager
|
|
288
|
+
ret = reman.data_file_for_reference(self._name)
|
|
289
|
+
return ret
|
|
@@ -26,6 +26,7 @@ class ReferenceParser:
|
|
|
26
26
|
CSVPATH = "csvpath"
|
|
27
27
|
METADATA = "metadata"
|
|
28
28
|
RESULTS = "results"
|
|
29
|
+
FILES = "files"
|
|
29
30
|
|
|
30
31
|
def __init__(self, string: str = None) -> None:
|
|
31
32
|
self._root_major = None
|
|
@@ -106,6 +107,7 @@ class ReferenceParser:
|
|
|
106
107
|
ReferenceParser.RESULTS,
|
|
107
108
|
ReferenceParser.CSVPATHS,
|
|
108
109
|
ReferenceParser.CSVPATH,
|
|
110
|
+
ReferenceParser.FILES,
|
|
109
111
|
ReferenceParser.METADATA,
|
|
110
112
|
]:
|
|
111
113
|
raise ReferenceException(f"Unknown datatype {t} in {self}")
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[tool.poetry]
|
|
2
2
|
name = "csvpath"
|
|
3
|
-
version = "0.0.
|
|
3
|
+
version = "0.0.529"
|
|
4
4
|
description = "A data preboarding framework for managing and validating CSV, Excel, and other tabular data files using a Collect, Store, Validate, Publish pattern to create a trusted publisher for downstream data consumers."
|
|
5
5
|
authors = ["David Kershaw <dk107dk@hotmail.com>"]
|
|
6
6
|
readme = "README.md"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/otlp_error_listener.py
RENAMED
|
File without changes
|
|
File without changes
|
{csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/otlp_result_listener.py
RENAMED
|
File without changes
|
{csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/otlp/otlp_results_listener.py
RENAMED
|
File without changes
|
|
File without changes
|
{csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftpplus/arrival_handler.py
RENAMED
|
File without changes
|
|
File without changes
|
{csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftpplus/sftpplus_listener.py
RENAMED
|
File without changes
|
{csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sftpplus/transfer_creator.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sqlite/sqlite_result_listener.py
RENAMED
|
File without changes
|
{csvpath-0.0.528 → csvpath-0.0.529}/csvpath/managers/integrations/sqlite/sqlite_results_listener.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|