mdbq 2.8.2__tar.gz → 2.8.3__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.
Files changed (55) hide show
  1. {mdbq-2.8.2 → mdbq-2.8.3}/PKG-INFO +1 -1
  2. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/company/copysh.py +25 -24
  3. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/pbix/refresh_all.py +1 -1
  4. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq.egg-info/PKG-INFO +1 -1
  5. {mdbq-2.8.2 → mdbq-2.8.3}/setup.py +1 -1
  6. {mdbq-2.8.2 → mdbq-2.8.3}/README.txt +0 -0
  7. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/__init__.py +0 -0
  8. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/__version__.py +0 -0
  9. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/aggregation/__init__.py +0 -0
  10. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/aggregation/aggregation.py +0 -0
  11. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/aggregation/df_types.py +0 -0
  12. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/aggregation/mysql_types.py +0 -0
  13. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/aggregation/optimize_data.py +0 -0
  14. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/aggregation/query_data.py +0 -0
  15. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/bdup/__init__.py +0 -0
  16. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/bdup/bdup.py +0 -0
  17. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/clean/__init__.py +0 -0
  18. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/clean/clean_upload.py +0 -0
  19. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/clean/data_clean.py +0 -0
  20. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/company/__init__.py +0 -0
  21. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/company/copysh_bak.py +0 -0
  22. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/company/home_sh.py +0 -0
  23. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/config/__init__.py +0 -0
  24. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/config/get_myconf.py +0 -0
  25. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/config/myconfig.py +0 -0
  26. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/config/products.py +0 -0
  27. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/config/set_support.py +0 -0
  28. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/config/update_conf.py +0 -0
  29. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/dataframe/__init__.py +0 -0
  30. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/dataframe/converter.py +0 -0
  31. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/log/__init__.py +0 -0
  32. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/log/mylogger.py +0 -0
  33. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/mongo/__init__.py +0 -0
  34. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/mongo/mongo.py +0 -0
  35. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/mysql/__init__.py +0 -0
  36. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/mysql/mysql.py +0 -0
  37. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/mysql/recheck_mysql.py +0 -0
  38. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/mysql/s_query.py +0 -0
  39. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/mysql/year_month_day.py +0 -0
  40. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/other/__init__.py +0 -0
  41. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/other/porxy.py +0 -0
  42. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/other/pov_city.py +0 -0
  43. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/other/sku_picture.py +0 -0
  44. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/other/ua_sj.py +0 -0
  45. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/pbix/__init__.py +0 -0
  46. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/pbix/pbix_refresh.py +0 -0
  47. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/pbix/refresh_all_old.py +0 -0
  48. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/req_post/__init__.py +0 -0
  49. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/req_post/req_tb.py +0 -0
  50. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/spider/__init__.py +0 -0
  51. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq/spider/aikucun.py +0 -0
  52. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq.egg-info/SOURCES.txt +0 -0
  53. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq.egg-info/dependency_links.txt +0 -0
  54. {mdbq-2.8.2 → mdbq-2.8.3}/mdbq.egg-info/top_level.txt +0 -0
  55. {mdbq-2.8.2 → mdbq-2.8.3}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: mdbq
3
- Version: 2.8.2
3
+ Version: 2.8.3
4
4
  Home-page: https://pypi.org/project/mdbq
5
5
  Author: xigua,
6
6
  Author-email: 2587125111@qq.com
@@ -16,13 +16,13 @@ from mdbq.aggregation import optimize_data
16
16
  from mdbq.config import set_support
17
17
  from mdbq.config import myconfig
18
18
  from mdbq.mysql import mysql
19
- from mdbq.pbix import refresh_all
20
19
  from mdbq.clean import clean_upload
21
20
  warnings.filterwarnings('ignore')
22
21
 
23
22
 
24
23
  if platform.system() == 'Windows':
25
24
  # windows版本
25
+ from mdbq.pbix import refresh_all
26
26
  Data_Path = r'C:\同步空间\BaiduSyncdisk'
27
27
  D_PATH = os.path.join(f'C:\\Users\\{getpass.getuser()}\\Downloads')
28
28
  Share_Path = os.path.join(r'\\192.168.1.198\时尚事业部\01.运营部\天猫报表') # 共享文件根目录
@@ -275,25 +275,26 @@ class TbFiles:
275
275
  print(f'{src} 所需同步的文件不存在,请检查:pd_list参数')
276
276
 
277
277
  # 刷新共享位置的指定文件/文件夹
278
- excel_path = os.path.join(self.share_path, 'EXCEL报表')
279
- files = os.listdir(excel_path)
280
- files = [f'{excel_path}\\{item}' for item in files if item.endswith('.xlsx') or item.endswith('.xls')]
281
- r = refresh_all.RefreshAll()
282
- for file in files:
283
- if '~' in file or 'DS_Store' in file or 'baidu' in file or 'xunlei' in file:
284
- continue
285
- if file.endswith('.xlsx') or file.endswith('.xls'):
286
- r.refresh_excel(file=file)
287
- time.sleep(5)
288
-
289
- # 临时加的
290
- # excel_file = f'\\\\192.168.1.198\\时尚事业部\\01.运营部\\0-电商周报-每周五更新\\0-WLM_运营周报-1012输出.xlsx'
291
- dir_files = f'\\\\192.168.1.198\\时尚事业部\\01.运营部\\0-电商周报-每周五更新'
292
- files = os.listdir(dir_files)
293
- for file in files:
294
- if file.endswith('.xlsx') and file.startswith('0-WLM_运营周报') and '~' not in file and 'baidu' not in file:
295
- excel_file = os.path.join(dir_files, file)
296
- r.refresh_excel(file=excel_file)
278
+ if platform.system() == 'Windows':
279
+ excel_path = os.path.join(self.share_path, 'EXCEL报表')
280
+ files = os.listdir(excel_path)
281
+ files = [f'{excel_path}\\{item}' for item in files if item.endswith('.xlsx') or item.endswith('.xls')]
282
+ r = refresh_all.RefreshAll()
283
+ for file in files:
284
+ if '~' in file or 'DS_Store' in file or 'baidu' in file or 'xunlei' in file:
285
+ continue
286
+ if file.endswith('.xlsx') or file.endswith('.xls'):
287
+ r.refresh_excel(file=file)
288
+ time.sleep(5)
289
+
290
+ # 临时加的
291
+ # excel_file = f'\\\\192.168.1.198\\时尚事业部\\01.运营部\\0-电商周报-每周五更新\\0-WLM_运营周报-1012输出.xlsx'
292
+ dir_files = f'\\\\192.168.1.198\\时尚事业部\\01.运营部\\0-电商周报-每周五更新'
293
+ files = os.listdir(dir_files)
294
+ for file in files:
295
+ if file.endswith('.xlsx') and file.startswith('0-WLM_运营周报') and '~' not in file and 'baidu' not in file:
296
+ excel_file = os.path.join(dir_files, file)
297
+ r.refresh_excel(file=excel_file)
297
298
 
298
299
  self.before_max_time = self.check_change() # 重置值, 避免重复同步
299
300
 
@@ -339,9 +340,9 @@ def op_data(days: int =100):
339
340
 
340
341
 
341
342
  def main():
342
- if platform.system() != 'Windows':
343
- print(f'只可以在 windows 运行')
344
- return
343
+ # if platform.system() != 'Windows':
344
+ # print(f'只可以在 windows 运行')
345
+ # return
345
346
  t = TbFiles()
346
347
  while True:
347
348
  system = platform.system() # 本机系统
@@ -357,7 +358,7 @@ def main():
357
358
  b.download_dir(local_path=upload_path, remote_path=bd_remoto_path)
358
359
 
359
360
  clean_upload.main(
360
- is_mysql=True, # 调试时加,False: 是否后续的聚合数据及清理
361
+ is_mysql=True, # 调试时加,False: 不进行后续的聚合数据及清理
361
362
  is_company=True, # 公司电脑不需要移动文件到原始文件
362
363
  )
363
364
 
@@ -1,6 +1,5 @@
1
1
  import os
2
2
  import sys
3
- import win32com.client
4
3
  import time
5
4
  import psutil
6
5
  from pywinauto.application import Application
@@ -51,6 +50,7 @@ class RefreshAll:
51
50
 
52
51
  def refresh_excel(self, file):
53
52
  # 刷新 excel
53
+ import win32com.client
54
54
  if not os.path.isfile(file):
55
55
  now = datetime.datetime.now().strftime('%Y-%m-%d %H:%M:%S ')
56
56
  print(f'{now}{file} -> 文件不存在')
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: mdbq
3
- Version: 2.8.2
3
+ Version: 2.8.3
4
4
  Home-page: https://pypi.org/project/mdbq
5
5
  Author: xigua,
6
6
  Author-email: 2587125111@qq.com
@@ -3,7 +3,7 @@
3
3
  from setuptools import setup, find_packages
4
4
 
5
5
  setup(name='mdbq',
6
- version='2.8.2',
6
+ version='2.8.3',
7
7
  author='xigua, ',
8
8
  author_email="2587125111@qq.com",
9
9
  url='https://pypi.org/project/mdbq',
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