pdd-skills 3.1.13 → 3.2.3

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 (51) hide show
  1. package/LICENSE +21 -21
  2. package/package.json +1 -1
  3. package/scaffolds/python-fullstack/.github/workflows/ci.yml +1 -1
  4. package/scaffolds/python-fullstack/Dockerfile +1 -1
  5. package/scaffolds/python-fullstack/docker-compose.yml +1 -1
  6. package/scaffolds/python-fullstack/frontend/Dockerfile +1 -1
  7. package/scaffolds/python-fullstack/frontend/nginx.conf +1 -1
  8. package/scaffolds/python-fullstack/frontend/postcss.config.js +1 -1
  9. package/scaffolds/python-fullstack/frontend/src/api/client.ts +1 -1
  10. package/scaffolds/python-fullstack/frontend/src/composables/useResponsive.ts +1 -1
  11. package/scaffolds/python-fullstack/frontend/src/router/index.ts +1 -1
  12. package/scaffolds/python-fullstack/frontend/src/stores/user.ts +1 -1
  13. package/scaffolds/python-fullstack/frontend/src/styles/responsive.css +1 -1
  14. package/scaffolds/python-fullstack/frontend/src/styles/variables.css +1 -1
  15. package/scaffolds/python-fullstack/frontend/src/views/DashboardView.vue +1 -1
  16. package/scaffolds/python-fullstack/frontend/src/views/HomeView.vue +1 -1
  17. package/scaffolds/python-fullstack/frontend/src/views/LoginView.vue +1 -1
  18. package/scaffolds/python-fullstack/frontend/tailwind.config.js +1 -1
  19. package/skills/core/official-doc-writer/README.md +232 -232
  20. package/skills/core/official-doc-writer/SKILL.md +4 -7
  21. package/skills/core/official-doc-writer/fonts/FONTS_LIST.md +44 -44
  22. package/skills/core/official-doc-writer/references/GBT_9704-2012_/345/205/232/346/224/277/346/234/272/345/205/263/345/205/254/346/226/207/346/240/274/345/274/217.md +422 -422
  23. package/skills/core/pdd-ba/SKILL.md +1 -11
  24. package/skills/core/pdd-entropy-reduction/SKILL.md +1 -9
  25. package/skills/core/pdd-extract-features/SKILL.md +1 -10
  26. package/skills/core/pdd-generate-spec/SKILL.md +1 -10
  27. package/skills/core/pdd-main/evals/evals.json +215 -215
  28. package/skills/core/pdd-verify-feature/SKILL.md +1 -10
  29. package/skills/core/pdd-vm/SKILL.md +1 -11
  30. package/skills/entropy/expert-arch-enforcer/SKILL.md +292 -292
  31. package/skills/entropy/expert-auto-refactor/SKILL.md +316 -327
  32. package/skills/entropy/expert-code-quality/SKILL.md +468 -468
  33. package/skills/entropy/expert-entropy-auditor/SKILL.md +276 -276
  34. package/skills/expert/expert-activiti/SKILL.md +488 -497
  35. package/skills/expert/expert-bug-fixer/SKILL.md +1 -26
  36. package/skills/expert/expert-mysql/SKILL.md +832 -832
  37. package/skills/expert/expert-ruoyi/SKILL.md +664 -674
  38. package/skills/expert/expert-springcloud/SKILL.md +1 -10
  39. package/skills/expert/expert-vue3/SKILL.md +1 -10
  40. package/skills/expert/testcase-agent/SKILL.md +5 -0
  41. package/skills/expert/testcase-modeler/SKILL.md +40 -2
  42. package/skills/pr/pdd-multi-review/SKILL.md +534 -534
  43. package/skills/pr/pdd-pr-batch/SKILL.md +303 -303
  44. package/skills/pr/pdd-pr-create/SKILL.md +344 -344
  45. package/skills/pr/pdd-pr-merge/SKILL.md +286 -286
  46. package/skills/pr/pdd-pr-review/SKILL.md +217 -217
  47. package/skills/pr/pdd-task-manager/SKILL.md +636 -636
  48. package/skills/pr/pdd-template-engine/SKILL.md +386 -386
  49. package/tests/login_manager.py +5 -30
  50. package/tests/recorder.py +362 -294
  51. package/tests/testcase-ai.py +1184 -11
@@ -20,6 +20,8 @@ import re
20
20
  import asyncio
21
21
  from dataclasses import dataclass, field
22
22
  from typing import Optional, List, Dict, Any
23
+ from tests.framework.logger import log
24
+ from tests.framework.mcp_client import check_result_has_error
23
25
 
24
26
 
25
27
  @dataclass
@@ -72,23 +74,6 @@ class LoginManager:
72
74
  self._element_cache = {}
73
75
  self._snapshot_dir = snapshot_dir
74
76
 
75
- @staticmethod
76
- def _check_result_has_error(content: str) -> bool:
77
- if not content:
78
- return False
79
- content_lower = content.lower()
80
- strict_errors = ["mcp error", "input validation error", "invalid arguments",
81
- "elementclickinterceptederror", "not interactable"]
82
- if any(err in content_lower for err in strict_errors):
83
- return True
84
- loose_patterns = ["error:", "failed to", "did not become", "timeout",
85
- "could not", "unable to", "no such", "cannot find"]
86
- if any(p in content_lower for p in loose_patterns):
87
- return True
88
- if content_lower.startswith("error:") or content_lower.startswith("err:"):
89
- return True
90
- return False
91
-
92
77
  async def check_and_ensure_login(
93
78
  self,
94
79
  session,
@@ -495,7 +480,7 @@ class LoginManager:
495
480
  elements = parsed.elements
496
481
  elif isinstance(parsed, list):
497
482
  elements = parsed
498
- except:
483
+ except Exception:
499
484
  elements = []
500
485
 
501
486
  user_element = None
@@ -558,7 +543,7 @@ class LoginManager:
558
543
  for c in click_result.content:
559
544
  if hasattr(c, 'text'): err_text += c.text
560
545
  if (hasattr(click_result, 'is_error') and click_result.is_error) or \
561
- self._check_result_has_error(err_text):
546
+ check_result_has_error(err_text):
562
547
  log(f"[Auto-Logout] 点击失败: {err_text[:100]}", 3)
563
548
  return False
564
549
  except Exception as e:
@@ -586,7 +571,7 @@ class LoginManager:
586
571
  for c in logout_result.content:
587
572
  if hasattr(c, 'text'): err += c.text
588
573
  if (hasattr(logout_result, 'is_error') and logout_result.is_error) or \
589
- self._check_result_has_error(err):
574
+ check_result_has_error(err):
590
575
  log(f"[Auto-Logout] 点击退出失败: {err[:100]}", 3)
591
576
  return False
592
577
  except Exception as e:
@@ -678,16 +663,6 @@ class LoginManager:
678
663
  return matches >= 2
679
664
 
680
665
 
681
- def log(msg: str, level: int = 0, timestamp: bool = True):
682
- """日志输出函数"""
683
- from datetime import datetime
684
- if timestamp:
685
- prefix = datetime.now().strftime("[%H:%M:%S]")
686
- else:
687
- prefix = ""
688
-
689
- indent = " " * level
690
- print(f"{prefix}{indent}{msg}")
691
666
 
692
667
 
693
668
  if __name__ == "__main__":