meerschaum 2.7.5__tar.gz → 2.7.6__tar.gz

Sign up to get free protection for your applications and to get access to all the features.
Files changed (276) hide show
  1. {meerschaum-2.7.5/meerschaum.egg-info → meerschaum-2.7.6}/PKG-INFO +4 -4
  2. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/shell/Shell.py +4 -6
  3. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/shell/ShellCompleter.py +6 -5
  4. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/clear.py +6 -3
  5. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/copy.py +33 -27
  6. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/sync.py +22 -18
  7. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pipes.py +2 -3
  8. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_default.py +5 -0
  9. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_version.py +1 -1
  10. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_misc.py +3 -2
  11. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_pipes.py +8 -9
  12. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_SQLConnector.py +1 -0
  13. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_pipes.py +37 -10
  14. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_sql.py +9 -1
  15. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/jobs/_Job.py +1 -0
  16. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/plugins/__init__.py +7 -3
  17. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/daemon/Daemon.py +5 -1
  18. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/daemon/__init__.py +2 -2
  19. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/misc.py +7 -6
  20. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/packages/__init__.py +31 -27
  21. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/packages/_packages.py +1 -1
  22. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/prompt.py +54 -36
  23. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/venv/__init__.py +12 -3
  24. {meerschaum-2.7.5 → meerschaum-2.7.6/meerschaum.egg-info}/PKG-INFO +4 -4
  25. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum.egg-info/requires.txt +3 -3
  26. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_jobs.py +1 -1
  27. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_pipes_dtypes.py +0 -1
  28. {meerschaum-2.7.5 → meerschaum-2.7.6}/LICENSE +0 -0
  29. {meerschaum-2.7.5 → meerschaum-2.7.6}/NOTICE +0 -0
  30. {meerschaum-2.7.5 → meerschaum-2.7.6}/README.md +0 -0
  31. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/__init__.py +0 -0
  32. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/__main__.py +0 -0
  33. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/__init__.py +0 -0
  34. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/arguments/__init__.py +0 -0
  35. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/arguments/_parse_arguments.py +0 -0
  36. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/arguments/_parser.py +0 -0
  37. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/docs/__init__.py +0 -0
  38. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/docs/index.py +0 -0
  39. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/entry.py +0 -0
  40. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/gui/__init__.py +0 -0
  41. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/gui/app/__init__.py +0 -0
  42. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/gui/app/_windows.py +0 -0
  43. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/gui/app/actions.py +0 -0
  44. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/gui/app/pipes.py +0 -0
  45. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/shell/ValidAutoSuggest.py +0 -0
  46. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/shell/__init__.py +0 -0
  47. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/shell/resources/__init__.py +0 -0
  48. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/shell/updates.py +0 -0
  49. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/term/TermPageHandler.py +0 -0
  50. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/term/__init__.py +0 -0
  51. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/_internal/term/tools.py +0 -0
  52. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/__init__.py +0 -0
  53. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/api.py +0 -0
  54. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/attach.py +0 -0
  55. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/bootstrap.py +0 -0
  56. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/deduplicate.py +0 -0
  57. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/delete.py +0 -0
  58. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/drop.py +0 -0
  59. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/edit.py +0 -0
  60. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/install.py +0 -0
  61. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/login.py +0 -0
  62. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/os.py +0 -0
  63. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/pause.py +0 -0
  64. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/python.py +0 -0
  65. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/register.py +0 -0
  66. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/reload.py +0 -0
  67. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/restart.py +0 -0
  68. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/setup.py +0 -0
  69. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/sh.py +0 -0
  70. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/show.py +0 -0
  71. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/sql.py +0 -0
  72. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/stack.py +0 -0
  73. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/start.py +0 -0
  74. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/stop.py +0 -0
  75. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/tag.py +0 -0
  76. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/uninstall.py +0 -0
  77. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/upgrade.py +0 -0
  78. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/actions/verify.py +0 -0
  79. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/__init__.py +0 -0
  80. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/_chain.py +0 -0
  81. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/_events.py +0 -0
  82. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/_oauth2.py +0 -0
  83. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/_websockets.py +0 -0
  84. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/__init__.py +0 -0
  85. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/assets/__init__.py +0 -0
  86. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/assets/ansi_up.js +0 -0
  87. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/assets/banner_1920x320.png +0 -0
  88. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/assets/favicon.ico +0 -0
  89. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/assets/logo_48x48.png +0 -0
  90. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/assets/logo_500x500.png +0 -0
  91. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/callbacks/__init__.py +0 -0
  92. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/callbacks/custom.py +0 -0
  93. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/callbacks/dashboard.py +0 -0
  94. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/callbacks/jobs.py +0 -0
  95. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/callbacks/login.py +0 -0
  96. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/callbacks/pipes.py +0 -0
  97. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/callbacks/plugins.py +0 -0
  98. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/callbacks/register.py +0 -0
  99. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/components.py +0 -0
  100. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/connectors.py +0 -0
  101. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/graphs.py +0 -0
  102. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/jobs.py +0 -0
  103. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/keys.py +0 -0
  104. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pages/__init__.py +0 -0
  105. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pages/dashboard.py +0 -0
  106. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pages/error.py +0 -0
  107. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pages/job.py +0 -0
  108. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pages/login.py +0 -0
  109. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pages/pipes.py +0 -0
  110. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pages/plugins.py +0 -0
  111. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/pages/register.py +0 -0
  112. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/plugins.py +0 -0
  113. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/sessions.py +0 -0
  114. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/sync.py +0 -0
  115. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/users.py +0 -0
  116. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/websockets.py +0 -0
  117. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/dash/webterm.py +0 -0
  118. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/models/__init__.py +0 -0
  119. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/models/_interfaces.py +0 -0
  120. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/models/_locations.py +0 -0
  121. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/models/_metrics.py +0 -0
  122. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/models/_pipes.py +0 -0
  123. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/__init__.py +0 -0
  124. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/__init__.py +0 -0
  125. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/css/__init__.py +0 -0
  126. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/css/bootstrap.min.css +0 -0
  127. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/css/dash.css +0 -0
  128. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/css/dbc_dark.css +0 -0
  129. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/css/styles.css +0 -0
  130. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/css/xterm.css +0 -0
  131. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/ico/__init__.py +0 -0
  132. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/ico/logo.ico +0 -0
  133. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/js/__init__.py +0 -0
  134. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/js/action_button.js +0 -0
  135. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/js/main.js +0 -0
  136. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/js/terminado.js +0 -0
  137. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/js/xterm.js +0 -0
  138. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/static/png/__init__.py +0 -0
  139. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/templates/__init__.py +0 -0
  140. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/templates/index.html +0 -0
  141. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/templates/old_index.html +0 -0
  142. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/templates/secret.html +0 -0
  143. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/resources/templates/termpage.html +0 -0
  144. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/__init__.py +0 -0
  145. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_actions.py +0 -0
  146. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_connectors.py +0 -0
  147. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_index.py +0 -0
  148. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_jobs.py +0 -0
  149. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_login.py +0 -0
  150. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_misc.py +0 -0
  151. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_pipes.py +0 -0
  152. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_plugins.py +0 -0
  153. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_users.py +0 -0
  154. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_version.py +0 -0
  155. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/routes/_webterm.py +0 -0
  156. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/api/tables/__init__.py +0 -0
  157. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/__init__.py +0 -0
  158. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_dash.py +0 -0
  159. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_edit.py +0 -0
  160. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_environment.py +0 -0
  161. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_formatting.py +0 -0
  162. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_jobs.py +0 -0
  163. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_patch.py +0 -0
  164. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_paths.py +0 -0
  165. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_preprocess.py +0 -0
  166. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_read_config.py +0 -0
  167. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_shell.py +0 -0
  168. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/_sync.py +0 -0
  169. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/paths.py +0 -0
  170. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/resources/__init__.py +0 -0
  171. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/stack/__init__.py +0 -0
  172. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/stack/grafana/__init__.py +0 -0
  173. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/stack/mosquitto/__init__.py +0 -0
  174. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/stack/mosquitto/resources/__init__.py +0 -0
  175. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/stack/resources/__init__.py +0 -0
  176. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/config/static/__init__.py +0 -0
  177. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/_Connector.py +0 -0
  178. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/__init__.py +0 -0
  179. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_APIConnector.py +0 -0
  180. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/__init__.py +0 -0
  181. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_actions.py +0 -0
  182. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_fetch.py +0 -0
  183. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_jobs.py +0 -0
  184. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_login.py +0 -0
  185. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_plugins.py +0 -0
  186. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_request.py +0 -0
  187. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_uri.py +0 -0
  188. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/api/_users.py +0 -0
  189. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/parse.py +0 -0
  190. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/plugin/PluginConnector.py +0 -0
  191. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/plugin/__init__.py +0 -0
  192. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/poll.py +0 -0
  193. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/__init__.py +0 -0
  194. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_cli.py +0 -0
  195. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_create_engine.py +0 -0
  196. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_fetch.py +0 -0
  197. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_instance.py +0 -0
  198. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_plugins.py +0 -0
  199. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_uri.py +0 -0
  200. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/_users.py +0 -0
  201. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/tables/__init__.py +0 -0
  202. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/tables/types.py +0 -0
  203. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/sql/tools.py +0 -0
  204. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/valkey/_ValkeyConnector.py +0 -0
  205. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/valkey/__init__.py +0 -0
  206. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/valkey/_fetch.py +0 -0
  207. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/valkey/_pipes.py +0 -0
  208. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/valkey/_plugins.py +0 -0
  209. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/connectors/valkey/_users.py +0 -0
  210. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/__init__.py +0 -0
  211. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_attributes.py +0 -0
  212. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_bootstrap.py +0 -0
  213. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_clear.py +0 -0
  214. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_copy.py +0 -0
  215. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_data.py +0 -0
  216. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_deduplicate.py +0 -0
  217. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_delete.py +0 -0
  218. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_drop.py +0 -0
  219. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_dtypes.py +0 -0
  220. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_edit.py +0 -0
  221. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_fetch.py +0 -0
  222. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_register.py +0 -0
  223. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_show.py +0 -0
  224. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_sync.py +0 -0
  225. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Pipe/_verify.py +0 -0
  226. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/Plugin/__init__.py +0 -0
  227. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/User/_User.py +0 -0
  228. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/User/__init__.py +0 -0
  229. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/core/__init__.py +0 -0
  230. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/jobs/_Executor.py +0 -0
  231. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/jobs/__init__.py +0 -0
  232. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/jobs/systemd.py +0 -0
  233. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/plugins/_Plugin.py +0 -0
  234. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/plugins/bootstrap.py +0 -0
  235. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/__init__.py +0 -0
  236. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/_get_pipes.py +0 -0
  237. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/daemon/FileDescriptorInterceptor.py +0 -0
  238. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/daemon/RotatingFile.py +0 -0
  239. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/daemon/StdinFile.py +0 -0
  240. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/daemon/_names.py +0 -0
  241. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/dataframe.py +0 -0
  242. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/debug.py +0 -0
  243. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/dtypes/__init__.py +0 -0
  244. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/dtypes/sql.py +0 -0
  245. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/formatting/__init__.py +0 -0
  246. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/formatting/_jobs.py +0 -0
  247. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/formatting/_pipes.py +0 -0
  248. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/formatting/_pprint.py +0 -0
  249. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/formatting/_shell.py +0 -0
  250. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/interactive.py +0 -0
  251. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/networking.py +0 -0
  252. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/packages/lazy_loader.py +0 -0
  253. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/pool.py +0 -0
  254. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/process.py +0 -0
  255. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/schedule.py +0 -0
  256. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/sql.py +0 -0
  257. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/threading.py +0 -0
  258. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/typing.py +0 -0
  259. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/venv/_Venv.py +0 -0
  260. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/warnings.py +0 -0
  261. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum/utils/yaml.py +0 -0
  262. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum.egg-info/SOURCES.txt +0 -0
  263. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum.egg-info/dependency_links.txt +0 -0
  264. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum.egg-info/entry_points.txt +0 -0
  265. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum.egg-info/top_level.txt +0 -0
  266. {meerschaum-2.7.5 → meerschaum-2.7.6}/meerschaum.egg-info/zip-safe +0 -0
  267. {meerschaum-2.7.5 → meerschaum-2.7.6}/setup.cfg +0 -0
  268. {meerschaum-2.7.5 → meerschaum-2.7.6}/setup.py +0 -0
  269. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_actions.py +0 -0
  270. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_arguments.py +0 -0
  271. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_deduplicate.py +0 -0
  272. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_pipe_data.py +0 -0
  273. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_sql.py +0 -0
  274. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_sync.py +0 -0
  275. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_users.py +0 -0
  276. {meerschaum-2.7.5 → meerschaum-2.7.6}/tests/test_verify.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: meerschaum
3
- Version: 2.7.5
3
+ Version: 2.7.6
4
4
  Summary: Sync Time-Series Pipes with Meerschaum
5
5
  Home-page: https://meerschaum.io
6
6
  Author: Bennett Meares
@@ -127,7 +127,7 @@ Provides-Extra: sql
127
127
  Requires-Dist: numpy>=1.18.5; extra == "sql"
128
128
  Requires-Dist: pandas[parquet]>=2.0.1; extra == "sql"
129
129
  Requires-Dist: pyarrow>=16.1.0; extra == "sql"
130
- Requires-Dist: dask[complete]>=2024.5.1; extra == "sql"
130
+ Requires-Dist: dask[complete]>=2024.12.1; extra == "sql"
131
131
  Requires-Dist: partd>=1.4.2; extra == "sql"
132
132
  Requires-Dist: pytz; extra == "sql"
133
133
  Requires-Dist: joblib>=0.17.0; extra == "sql"
@@ -187,7 +187,7 @@ Requires-Dist: valkey>=6.0.0; extra == "api"
187
187
  Requires-Dist: numpy>=1.18.5; extra == "api"
188
188
  Requires-Dist: pandas[parquet]>=2.0.1; extra == "api"
189
189
  Requires-Dist: pyarrow>=16.1.0; extra == "api"
190
- Requires-Dist: dask[complete]>=2024.5.1; extra == "api"
190
+ Requires-Dist: dask[complete]>=2024.12.1; extra == "api"
191
191
  Requires-Dist: partd>=1.4.2; extra == "api"
192
192
  Requires-Dist: pytz; extra == "api"
193
193
  Requires-Dist: joblib>=0.17.0; extra == "api"
@@ -292,7 +292,7 @@ Requires-Dist: pycparser>=2.21.0; extra == "full"
292
292
  Requires-Dist: numpy>=1.18.5; extra == "full"
293
293
  Requires-Dist: pandas[parquet]>=2.0.1; extra == "full"
294
294
  Requires-Dist: pyarrow>=16.1.0; extra == "full"
295
- Requires-Dist: dask[complete]>=2024.5.1; extra == "full"
295
+ Requires-Dist: dask[complete]>=2024.12.1; extra == "full"
296
296
  Requires-Dist: partd>=1.4.2; extra == "full"
297
297
  Requires-Dist: pytz; extra == "full"
298
298
  Requires-Dist: joblib>=0.17.0; extra == "full"
@@ -742,8 +742,7 @@ class Shell(cmd.Cmd):
742
742
  """
743
743
  from meerschaum import get_connector
744
744
  from meerschaum.connectors.parse import parse_instance_keys
745
- from meerschaum.utils.warnings import warn, info
746
- from meerschaum.utils.misc import remove_ansi
745
+ from meerschaum.utils.warnings import info
747
746
 
748
747
  if action is None:
749
748
  action = []
@@ -829,7 +828,7 @@ class Shell(cmd.Cmd):
829
828
  """
830
829
  from meerschaum import get_connector
831
830
  from meerschaum.connectors.parse import parse_repo_keys
832
- from meerschaum.utils.warnings import warn, info
831
+ from meerschaum.utils.warnings import info
833
832
 
834
833
  if action is None:
835
834
  action = []
@@ -878,7 +877,6 @@ class Shell(cmd.Cmd):
878
877
 
879
878
  Note that executors are API instances.
880
879
  """
881
- from meerschaum import get_connector
882
880
  from meerschaum.connectors.parse import parse_executor_keys
883
881
  from meerschaum.utils.warnings import warn, info
884
882
  from meerschaum.jobs import get_executor_keys_from_context
@@ -894,7 +892,7 @@ class Shell(cmd.Cmd):
894
892
  executor_keys = get_executor_keys_from_context()
895
893
 
896
894
  if executor_keys == 'systemd' and get_executor_keys_from_context() != 'systemd':
897
- warn(f"Cannot execute via `systemd`, falling back to `local`...", stack=False)
895
+ warn("Cannot execute via `systemd`, falling back to `local`...", stack=False)
898
896
  executor_keys = 'local'
899
897
 
900
898
  conn = parse_executor_keys(executor_keys, debug=debug)
@@ -935,7 +933,7 @@ class Shell(cmd.Cmd):
935
933
  if args['action'][0] not in shell_attrs['_actions']:
936
934
  try:
937
935
  print(textwrap.dedent(getattr(self, f"do_{args['action'][0]}").__doc__))
938
- except Exception as e:
936
+ except Exception:
939
937
  print(f"No help on '{args['action'][0]}'.")
940
938
  return ""
941
939
  parse_help(args)
@@ -7,13 +7,15 @@ Implement the prompt_toolkit Completer base class.
7
7
  """
8
8
 
9
9
  from __future__ import annotations
10
- from prompt_toolkit.completion import Completer, Completion
11
- from meerschaum.utils.typing import Optional
12
- from meerschaum.actions import get_shell, get_completer, get_main_action_name, get_action
10
+ from meerschaum.actions import get_shell, get_main_action_name, get_action
13
11
  from meerschaum._internal.arguments import parse_line
14
12
 
15
13
  from meerschaum.utils.packages import attempt_import, ensure_readline
16
- prompt_toolkit = attempt_import('prompt_toolkit', lazy=False, install=True)
14
+
15
+ prompt_toolkit_completion = attempt_import('prompt_toolkit.completion', lazy=False, install=True)
16
+ Completer = prompt_toolkit_completion.Completer
17
+ Completion = prompt_toolkit_completion.Completion
18
+
17
19
 
18
20
  class ShellCompleter(Completer):
19
21
  """
@@ -30,7 +32,6 @@ class ShellCompleter(Completer):
30
32
  yielded = []
31
33
  ensure_readline()
32
34
  parts = document.text.split('-')
33
- ends_with_space = parts[0].endswith(' ')
34
35
  last_action_line = parts[0].split('+')[-1]
35
36
  part_0_subbed_spaces = last_action_line.replace(' ', '_')
36
37
  parsed_text = (part_0_subbed_spaces + '-'.join(parts[1:]))
@@ -130,12 +130,15 @@ def _ask_with_rowcounts(
130
130
  )
131
131
 
132
132
 
133
- pipes_rowcounts = {p: p.get_rowcount(begin=begin, end=end, debug=debug) for p in pipes}
133
+ pipes_rowcounts = {
134
+ pipe: pipe.get_rowcount(begin=begin, end=end, debug=debug)
135
+ for pipe in pipes
136
+ }
134
137
  print_options(
135
- [str(p) + f'\n{rc}\n' for p, rc in pipes_rowcounts.items()],
138
+ [str(pipe) + f'\n{rowcount:,}\n' for pipe, rowcount in pipes_rowcounts.items()],
136
139
  header='Number of Rows to be Deleted'
137
140
  )
138
- total_num_rows = sum([rc for p, rc in pipes_rowcounts.items()])
141
+ total_num_rows = sum([rowcount for rowcount in pipes_rowcounts.values()])
139
142
  question = (
140
143
  f"Are you sure you want to delete {total_num_rows:,} rows across {len(pipes)} pipe"
141
144
  + ('s' if len(pipes) != 1 else '')
@@ -7,7 +7,7 @@ Functions for copying elements.
7
7
  """
8
8
 
9
9
  from __future__ import annotations
10
- from meerschaum.utils.typing import Union, Any, Sequence, SuccessTuple, Optional, Tuple, List
10
+ from meerschaum.utils.typing import Any, SuccessTuple, Optional, List
11
11
 
12
12
  def copy(
13
13
  action: Optional[List[str]] = None,
@@ -69,44 +69,53 @@ def _copy_pipes(
69
69
  Copy pipes' attributes and make new pipes.
70
70
  """
71
71
  from meerschaum import get_pipes, Pipe
72
- from meerschaum.utils.prompt import prompt, yes_no
72
+ from meerschaum.utils.prompt import prompt, yes_no, get_connectors_completer
73
73
  from meerschaum.utils.warnings import warn
74
74
  from meerschaum.utils.formatting import print_tuple
75
75
  from meerschaum.utils.formatting._shell import clear_screen
76
76
  pipes = get_pipes(as_list=True, **kw)
77
77
  successes = 0
78
- for p in pipes:
79
- ck = prompt(f"Connector keys for copy of {p}:", default=p.connector_keys)
80
- mk = prompt(f"Metric key for copy of {p}:", default=p.metric_key)
81
- lk = prompt(f"Location key for copy of {p} ('None' to omit):", default=str(p.location_key))
78
+ for pipe in pipes:
79
+ ck = prompt(
80
+ f"Connector keys for copy of {pipe}:",
81
+ default=pipe.connector_keys,
82
+ completer=get_connectors_completer(),
83
+ )
84
+ mk = prompt(f"Metric key for copy of {pipe}:", default=pipe.metric_key)
85
+ lk = prompt(
86
+ f"Location key for copy of {pipe} ('None' to omit):",
87
+ default=str(pipe.location_key),
88
+ )
82
89
  if lk in ('', 'None', '[None]'):
83
90
  lk = None
84
- _new_pipe = Pipe(
85
- ck, mk, lk,
86
- parameters=p.parameters.copy(),
87
- )
91
+
88
92
  instance_keys = prompt(
89
- f"Meerschaum instance to store the new {_new_pipe}:",
90
- default=p.instance_keys
93
+ f"Meerschaum instance for copy of {pipe}:",
94
+ default=pipe.instance_keys
91
95
  )
92
- _new_pipe.instance_keys = instance_keys
93
- if _new_pipe.get_id(debug=debug) is not None:
94
- warn(f"New {_new_pipe} already exists. Skipping...", stack=False)
96
+ new_pipe = Pipe(
97
+ ck, mk, lk,
98
+ instance=instance_keys,
99
+ parameters=pipe.parameters.copy(),
100
+ )
101
+
102
+ if new_pipe.get_id(debug=debug) is not None:
103
+ warn(f"{new_pipe} already exists. Skipping...", stack=False)
95
104
  continue
96
- _register_success_tuple = _new_pipe.register(debug=debug)
105
+ _register_success_tuple = new_pipe.register(debug=debug)
97
106
  if not _register_success_tuple[0]:
98
- warn(f"Failed to register new {_new_pipe}.", stack=False)
107
+ warn(f"Failed to register new {new_pipe}.", stack=False)
99
108
  continue
100
109
 
101
110
  clear_screen(debug=debug)
102
111
  successes += 1
103
112
  print_tuple(
104
- (True, f"Successfully copied attributes of {p} " + f" into {_new_pipe}.")
113
+ (True, f"Successfully copied attributes of {pipe} " + f" into {new_pipe}.")
105
114
  )
106
115
  if (
107
116
  force or yes_no(
108
117
  (
109
- f"Do you want to copy data from {p} into {_new_pipe}?\n\n"
118
+ f"Do you want to copy data from {pipe} into {new_pipe}?\n\n"
110
119
  + "If you specified `--begin`, `--end` or `--params`, data will be filtered."
111
120
  ),
112
121
  noask=noask,
@@ -114,8 +123,8 @@ def _copy_pipes(
114
123
  default='n',
115
124
  )
116
125
  ):
117
- _new_pipe.sync(
118
- p.get_data(
126
+ new_pipe.sync(
127
+ pipe.get_data(
119
128
  debug=debug,
120
129
  as_iterator=True,
121
130
  **kw
@@ -142,17 +151,14 @@ def _copy_connectors(
142
151
  ) -> SuccessTuple:
143
152
  """
144
153
  Create a new connector from an existing one.
145
-
146
154
  """
147
- import os, pathlib
148
155
  from meerschaum.utils.prompt import yes_no, prompt
149
156
  from meerschaum.connectors.parse import parse_connector_keys
150
157
  from meerschaum.config import _config, get_config
151
- from meerschaum.config._edit import write_config
152
- from meerschaum.utils.warnings import info, warn
158
+ from meerschaum.utils.warnings import info
153
159
  from meerschaum.utils.formatting import pprint
154
160
  from meerschaum.actions import get_action
155
- cf = _config()
161
+ _ = _config()
156
162
  if action is None:
157
163
  action = []
158
164
  if connector_keys is None:
@@ -170,7 +176,7 @@ def _copy_connectors(
170
176
 
171
177
  try:
172
178
  conn = parse_connector_keys(ck)
173
- except Exception as e:
179
+ except Exception:
174
180
  return False, f"Unable to parse connector '{ck}'."
175
181
 
176
182
  if len(_keys) == 2:
@@ -275,12 +275,14 @@ def _sync_pipes(
275
275
  import time
276
276
  import os
277
277
  import contextlib
278
+ from datetime import timedelta
278
279
 
279
280
  from meerschaum.utils.warnings import warn, info
280
281
  from meerschaum.utils.formatting._shell import progress
281
282
  from meerschaum.utils.formatting._shell import clear_screen
282
283
  from meerschaum.utils.formatting import print_pipes_results
283
284
  from meerschaum.config.static import STATIC_CONFIG
285
+ from meerschaum.utils.misc import interval_str
284
286
 
285
287
  noninteractive_val = os.environ.get(STATIC_CONFIG['environment']['noninteractive'], None)
286
288
  noninteractive = str(noninteractive_val).lower() in ('1', 'true', 'yes')
@@ -321,7 +323,7 @@ def _sync_pipes(
321
323
  for pipe, (_success, _msg) in results_dict.items()
322
324
  if not _success
323
325
  ]
324
- except Exception as e:
326
+ except Exception:
325
327
  import traceback
326
328
  traceback.print_exc()
327
329
  warn(
@@ -351,9 +353,9 @@ def _sync_pipes(
351
353
  success_msg = (
352
354
  "Successfully spawned threads for pipes:"
353
355
  if unblock
354
- else f"Successfully synced pipes:"
356
+ else "Successfully synced pipes:"
355
357
  )
356
- fail_msg = f"Failed to sync pipes:"
358
+ fail_msg = "Failed to sync pipes:"
357
359
  if results_dict:
358
360
  print_pipes_results(
359
361
  results_dict,
@@ -362,8 +364,10 @@ def _sync_pipes(
362
364
  nopretty = nopretty,
363
365
  )
364
366
 
367
+ lap_duration_text = interval_str(timedelta(seconds=(lap_end - lap_begin)))
368
+
365
369
  msg = (
366
- f"It took {round(lap_end - lap_begin, 2)} seconds to sync " +
370
+ f"It took {lap_duration_text} to sync " +
367
371
  f"{len(success_pipes) + len(failure_pipes)} pipe" +
368
372
  ("s" if (len(success_pipes) + len(failure_pipes)) != 1 else "") + "\n" +
369
373
  f" ({len(success_pipes)} succeeded, {len(failure_pipes)} failed)."
@@ -385,26 +389,26 @@ def _sync_pipes(
385
389
 
386
390
 
387
391
  def _wrap_pipe(
388
- pipe,
389
- unblock: bool = False,
390
- force: bool = False,
391
- debug: bool = False,
392
- min_seconds: int = 1,
393
- workers = None,
394
- verify: bool = False,
395
- deduplicate: bool = False,
396
- bounded: Optional[bool] = None,
397
- chunk_interval: Union[timedelta, int, None] = None,
398
- **kw
399
- ):
392
+ pipe,
393
+ unblock: bool = False,
394
+ force: bool = False,
395
+ debug: bool = False,
396
+ min_seconds: int = 1,
397
+ workers = None,
398
+ verify: bool = False,
399
+ deduplicate: bool = False,
400
+ bounded: Optional[bool] = None,
401
+ chunk_interval: Union[timedelta, int, None] = None,
402
+ **kw
403
+ ):
400
404
  """
401
405
  Wrapper function for handling exceptions.
402
406
  """
403
407
  import time
404
408
  import traceback
405
- from datetime import datetime, timedelta, timezone
409
+ from datetime import datetime, timezone
406
410
  import meerschaum as mrsm
407
- from meerschaum.utils.typing import is_success_tuple, SuccessTuple
411
+ from meerschaum.utils.typing import is_success_tuple
408
412
  from meerschaum.connectors import get_connector_plugin
409
413
  from meerschaum.utils.venv import Venv
410
414
  from meerschaum.plugins import _pre_sync_hooks, _post_sync_hooks
@@ -12,7 +12,6 @@ import shlex
12
12
  from textwrap import dedent
13
13
  from urllib.parse import urlencode
14
14
 
15
- from dash.dependencies import Input, Output, State
16
15
  from meerschaum.utils.typing import List, Optional, Dict, Any, Tuple, Union
17
16
  from meerschaum.utils.misc import string_to_dict
18
17
  from meerschaum.utils.packages import attempt_import, import_dcc, import_html, import_pandas
@@ -76,7 +75,7 @@ def keys_from_state(
76
75
  try:
77
76
  # params = string_to_dict(state['params-textarea.value'])
78
77
  params = string_to_dict(state['search-parameters-editor.value'])
79
- except Exception as e:
78
+ except Exception:
80
79
  params = None
81
80
  else:
82
81
  params = None
@@ -506,7 +505,7 @@ def accordion_items_from_pipe(
506
505
 
507
506
  stats_rows = []
508
507
  if rowcount is not None:
509
- stats_rows.append(html.Tr([html.Td("Row-count"), html.Td(f"{rowcount}")]))
508
+ stats_rows.append(html.Tr([html.Td("Row Count"), html.Td(f"{rowcount:,}")]))
510
509
  if interval is not None:
511
510
  stats_rows.append(
512
511
  html.Tr([html.Td("Timespan"), html.Td(humanfriendly.format_timespan(interval))])
@@ -76,6 +76,11 @@ default_system_config = {
76
76
  },
77
77
  'instance': {
78
78
  'stale_temporary_tables_minutes': 1440,
79
+ 'temporary_target': {
80
+ 'prefix': '_',
81
+ 'transaction_id_length': 4,
82
+ 'separator': '_',
83
+ },
79
84
  },
80
85
  'chunksize': 100_000,
81
86
  'poolclass': 'sqlalchemy.pool.QueuePool',
@@ -2,4 +2,4 @@
2
2
  Specify the Meerschaum release version.
3
3
  """
4
4
 
5
- __version__ = "2.7.5"
5
+ __version__ = "2.7.6"
@@ -20,12 +20,13 @@ def get_mrsm_version(self, **kw) -> Optional[str]:
20
20
  use_token=False,
21
21
  **kw
22
22
  ).json()
23
- except Exception as e:
23
+ except Exception:
24
24
  return None
25
25
  if isinstance(j, dict) and 'detail' in j:
26
26
  return None
27
27
  return j
28
28
 
29
+
29
30
  def get_chaining_status(self, **kw) -> Optional[bool]:
30
31
  """
31
32
  Fetch the chaining status of the API instance.
@@ -39,7 +40,7 @@ def get_chaining_status(self, **kw) -> Optional[bool]:
39
40
  )
40
41
  if not response:
41
42
  return None
42
- except Exception as e:
43
+ except Exception:
43
44
  return None
44
45
 
45
46
  return response.json()
@@ -9,8 +9,7 @@ Register or fetch Pipes from the API
9
9
  from __future__ import annotations
10
10
  import time
11
11
  import json
12
- from io import StringIO
13
- from datetime import datetime
12
+ from datetime import datetime, timedelta
14
13
 
15
14
  import meerschaum as mrsm
16
15
  from meerschaum.utils.debug import dprint
@@ -178,11 +177,11 @@ def sync_pipe(
178
177
  """Sync a DataFrame into a Pipe."""
179
178
  from decimal import Decimal
180
179
  from meerschaum.utils.debug import dprint
181
- from meerschaum.utils.misc import json_serialize_datetime, items_str
180
+ from meerschaum.utils.misc import json_serialize_datetime, items_str, interval_str
182
181
  from meerschaum.config import get_config
183
182
  from meerschaum.utils.packages import attempt_import
184
- from meerschaum.utils.dataframe import get_numeric_cols, to_json, get_bytes_cols
185
- begin = time.time()
183
+ from meerschaum.utils.dataframe import get_numeric_cols, to_json
184
+ begin = time.perf_counter()
186
185
  more_itertools = attempt_import('more_itertools')
187
186
  if df is None:
188
187
  msg = f"DataFrame is `None`. Cannot sync {pipe}."
@@ -304,9 +303,10 @@ def sync_pipe(
304
303
  num_success_chunks += 1
305
304
 
306
305
  success_tuple = True, (
307
- f"It took {round(time.time() - begin, 2)} seconds to sync {rowcount} row"
306
+ f"It took {interval_str(timedelta(seconds=(time.perf_counter() - begin)))} "
307
+ + "to sync {rowcount:,} row"
308
308
  + ('s' if rowcount != 1 else '')
309
- + f" across {num_success_chunks} chunk" + ('s' if num_success_chunks != 1 else '') +
309
+ + f" across {num_success_chunks:,} chunk" + ('s' if num_success_chunks != 1 else '') +
310
310
  f" to {pipe}."
311
311
  )
312
312
  return success_tuple
@@ -549,10 +549,9 @@ def create_metadata(
549
549
  if debug:
550
550
  dprint("Create metadata response: {response.text}")
551
551
  try:
552
- metadata_response = json.loads(response.text)
552
+ _ = json.loads(response.text)
553
553
  except Exception as e:
554
554
  warn(f"Failed to create metadata on {self}:\n{e}")
555
- metadata_response = False
556
555
  return False
557
556
 
558
557
 
@@ -69,6 +69,7 @@ class SQLConnector(Connector):
69
69
  get_pipe_schema,
70
70
  create_pipe_table_from_df,
71
71
  get_pipe_columns_indices,
72
+ get_temporary_target,
72
73
  )
73
74
  from ._plugins import (
74
75
  register_plugin,
@@ -1505,7 +1505,6 @@ def sync_pipe(
1505
1505
  UPDATE_QUERIES,
1506
1506
  get_reset_autoincrement_queries,
1507
1507
  )
1508
- from meerschaum.utils.misc import generate_password
1509
1508
  from meerschaum.utils.dtypes import are_dtypes_equal
1510
1509
  from meerschaum.utils.dtypes.sql import get_db_type_from_pd_type
1511
1510
  from meerschaum import Pipe
@@ -1720,9 +1719,7 @@ def sync_pipe(
1720
1719
  warn(f"Could not reset auto-incrementing primary key for {pipe}.", stack=False)
1721
1720
 
1722
1721
  if update_df is not None and len(update_df) > 0:
1723
- transact_id = generate_password(3)
1724
- temp_prefix = '##' if self.flavor != 'oracle' else '_'
1725
- temp_target = temp_prefix + transact_id + '_' + pipe.target
1722
+ temp_target = self.get_temporary_target(pipe.target, label='update')
1726
1723
  self._log_temporary_tables_creation(temp_target, create=(not pipe.temporary), debug=debug)
1727
1724
  temp_pipe = Pipe(
1728
1725
  pipe.connector_keys.replace(':', '_') + '_', pipe.metric_key, pipe.location_key,
@@ -1743,7 +1740,7 @@ def sync_pipe(
1743
1740
  static=True,
1744
1741
  autoincrement=False,
1745
1742
  parameters={
1746
- 'schema': (self.internal_schema if self.flavor != 'mssql' else None),
1743
+ 'schema': self.internal_schema,
1747
1744
  'hypertable': False,
1748
1745
  },
1749
1746
  )
@@ -1910,15 +1907,18 @@ def sync_pipe_inplace(
1910
1907
  )
1911
1908
  from meerschaum.utils.misc import generate_password
1912
1909
 
1913
- transact_id = generate_password(3)
1914
- def get_temp_table_name(label: str) -> str:
1915
- temp_prefix = '##' if self.flavor != 'oracle' else '_'
1916
- return temp_prefix + transact_id + '_' + label + '_' + pipe.target
1910
+ transaction_id_length = (
1911
+ mrsm.get_config(
1912
+ 'system', 'connectors', 'sql', 'instance', 'temporary_target', 'transaction_id_length'
1913
+ )
1914
+ )
1915
+ transact_id = generate_password(transaction_id_length)
1917
1916
 
1918
1917
  internal_schema = self.internal_schema
1918
+ target = pipe.target
1919
1919
  temp_table_roots = ['backtrack', 'new', 'delta', 'joined', 'unseen', 'update']
1920
1920
  temp_tables = {
1921
- table_root: get_temp_table_name(table_root)
1921
+ table_root: self.get_temporary_target(target, transact_id=transact_id, label=table_root)
1922
1922
  for table_root in temp_table_roots
1923
1923
  }
1924
1924
  temp_table_names = {
@@ -3626,3 +3626,30 @@ def get_pipe_schema(self, pipe: mrsm.Pipe) -> Union[str, None]:
3626
3626
  A schema string or `None` if nothing is configured.
3627
3627
  """
3628
3628
  return pipe.parameters.get('schema', self.schema)
3629
+
3630
+
3631
+ @staticmethod
3632
+ def get_temporary_target(
3633
+ target: str,
3634
+ transact_id: Optional[str, None] = None,
3635
+ label: Optional[str] = None,
3636
+ separator: Optional[str] = None,
3637
+ ) -> str:
3638
+ """
3639
+ Return a unique(ish) temporary target for a pipe.
3640
+ """
3641
+ from meerschaum.utils.misc import generate_password
3642
+ temp_target_cf = (
3643
+ mrsm.get_config('system', 'connectors', 'sql', 'instance', 'temporary_target') or {}
3644
+ )
3645
+ transaction_id_len = temp_target_cf.get('transaction_id_length', 3)
3646
+ transact_id = transact_id or generate_password(transaction_id_len)
3647
+ temp_prefix = temp_target_cf.get('prefix', '_')
3648
+ separator = separator or temp_target_cf.get('separator', '_')
3649
+ return (
3650
+ temp_prefix
3651
+ + target
3652
+ + separator
3653
+ + transact_id
3654
+ + ((separator + label) if label else '')
3655
+ )
@@ -778,6 +778,7 @@ def to_sql(
778
778
  import time
779
779
  import json
780
780
  from decimal import Decimal
781
+ from datetime import timedelta
781
782
  from meerschaum.utils.warnings import error, warn
782
783
  import warnings
783
784
  import functools
@@ -816,6 +817,7 @@ def to_sql(
816
817
  PD_TO_SQLALCHEMY_DTYPES_FLAVORS,
817
818
  get_db_type_from_pd_type,
818
819
  )
820
+ from meerschaum.utils.misc import interval_str
819
821
  from meerschaum.connectors.sql._create_engine import flavor_configs
820
822
  from meerschaum.utils.packages import attempt_import, import_pandas
821
823
  sqlalchemy = attempt_import('sqlalchemy', debug=debug)
@@ -998,7 +1000,13 @@ def to_sql(
998
1000
 
999
1001
  end = time.perf_counter()
1000
1002
  if success:
1001
- msg = f"It took {round(end - start, 2)} seconds to sync {len(df)} rows to {name}."
1003
+ num_rows = len(df)
1004
+ msg = (
1005
+ f"It took {interval_str(timedelta(seconds=(end - start)))} "
1006
+ + f"to sync {num_rows:,} row"
1007
+ + ('s' if num_rows != 1 else '')
1008
+ + f" to {name}."
1009
+ )
1002
1010
  stats['start'] = start
1003
1011
  stats['end'] = end
1004
1012
  stats['duration'] = end - start
@@ -313,6 +313,7 @@ class Job:
313
313
  if not cleanup_success:
314
314
  return cleanup_success, cleanup_msg
315
315
 
316
+ _ = self.daemon._properties.pop('result', None)
316
317
  return cleanup_success, f"Deleted {self}."
317
318
 
318
319
  def is_running(self) -> bool:
@@ -126,8 +126,8 @@ def pre_sync_hook(
126
126
 
127
127
 
128
128
  def post_sync_hook(
129
- function: Callable[[Any], Any],
130
- ) -> Callable[[Any], Any]:
129
+ function: Callable[[Any], Any],
130
+ ) -> Callable[[Any], Any]:
131
131
  """
132
132
  Register a function as a sync hook to be executed upon completion of a sync.
133
133
 
@@ -143,10 +143,14 @@ def post_sync_hook(
143
143
  Examples
144
144
  --------
145
145
  >>> from meerschaum.plugins import post_sync_hook
146
+ >>> from meerschaum.utils.misc import interval_str
147
+ >>> from datetime import timedelta
146
148
  >>>
147
149
  >>> @post_sync_hook
148
150
  ... def log_sync(pipe, success_tuple, duration=None, **kwargs):
149
- ... print(f"It took {round(duration, 2)} seconds to sync {pipe}.")
151
+ ... duration_delta = timedelta(seconds=duration)
152
+ ... duration_text = interval_str(duration_delta)
153
+ ... print(f"It took {duration_text} to sync {pipe}.")
150
154
  >>>
151
155
  """
152
156
  with _locks['_post_sync_hooks']:
@@ -1017,7 +1017,8 @@ class Daemon:
1017
1017
 
1018
1018
  def read_pickle(self) -> Daemon:
1019
1019
  """Read a Daemon's pickle file and return the `Daemon`."""
1020
- import pickle, traceback
1020
+ import pickle
1021
+ import traceback
1021
1022
  if not self.pickle_path.exists():
1022
1023
  error(f"Pickle file does not exist for daemon '{self.daemon_id}'.")
1023
1024
 
@@ -1053,6 +1054,9 @@ class Daemon:
1053
1054
  if self._properties is None:
1054
1055
  self._properties = {}
1055
1056
 
1057
+ if self._properties.get('result', None) is None:
1058
+ _ = self._properties.pop('result', None)
1059
+
1056
1060
  if _file_properties is not None:
1057
1061
  self._properties = apply_patch_to_config(
1058
1062
  _file_properties,
@@ -37,7 +37,7 @@ def daemon_entry(sysargs: Optional[List[str]] = None) -> SuccessTuple:
37
37
  filtered_sysargs = [arg for arg in sysargs if arg not in ('-d', '--daemon')]
38
38
  try:
39
39
  label = shlex.join(filtered_sysargs) if sysargs else None
40
- except Exception as e:
40
+ except Exception:
41
41
  label = ' '.join(filtered_sysargs) if sysargs else None
42
42
 
43
43
  name = _args.get('name', None)
@@ -45,7 +45,7 @@ def daemon_entry(sysargs: Optional[List[str]] = None) -> SuccessTuple:
45
45
  if name:
46
46
  try:
47
47
  daemon = Daemon(daemon_id=name)
48
- except Exception as e:
48
+ except Exception:
49
49
  daemon = None
50
50
 
51
51
  if daemon is not None: