auto_error_fixer 0.1.5 → 0.1.6

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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # 更新日志
2
2
 
3
+ ## [0.1.6] - 2026-01-22
4
+ ### 功能变更
5
+ - 修改面板访问端口从3001到7210
6
+ - 修改面板访问路径从/panel/AEF更改为/AEF/panel
7
+ - 保持原有文件路径结构不变
8
+
3
9
  ## [0.1.5] - 2026-01-20
4
10
  ### 跨平台增强
5
11
  - 添加跨平台路径标准化功能,自动处理Windows与Unix/Linux/Mac路径分隔符差异
@@ -61,6 +67,7 @@
61
67
  - 创建管理控制面板界面
62
68
  - 实现基本的错误处理逻辑
63
69
 
70
+ [0.1.6]: https://github.com/DLZstudio/AEF/releases/tag/v0.1.6
64
71
  [0.1.5]: https://github.com/DLZstudio/AEF/releases/tag/v0.1.5
65
72
  [0.1.4]: https://github.com/DLZstudio/AEF/releases/tag/v0.1.4
66
73
  [0.1.3]: https://github.com/DLZstudio/AEF/releases/tag/v0.1.3
@@ -1,5 +1,2 @@
1
- qwen --resume 076143e9-f5d8-461d-a15a-c63e02ff9f9c
1
+ qwen --resume 8ce8fb1a-6330-49a0-9718-689b6b84c99c
2
2
 
3
- qwen --resume 82d0a245-483e-49ab-b7b0-8e1046790edd
4
-
5
- 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
@@ -441,7 +441,7 @@
441
441
  const password = passwordInput.value;
442
442
 
443
443
  try {
444
- const response = await fetch('/panel/AEF/login', {
444
+ const response = await fetch('/AEF/panel/login', {
445
445
  method: 'POST',
446
446
  headers: {
447
447
  'Content-Type': 'application/json'
@@ -477,7 +477,7 @@
477
477
  // 加载状态数据
478
478
  async function loadStatusData() {
479
479
  try {
480
- const response = await fetch('/panel/AEF/status');
480
+ const response = await fetch('/AEF/panel/status');
481
481
  const data = await response.json();
482
482
 
483
483
  // 更新状态指示器
@@ -515,7 +515,7 @@
515
515
  // 加载配置数据
516
516
  async function loadConfigData() {
517
517
  try {
518
- const response = await fetch('/panel/AEF/config');
518
+ const response = await fetch('/AEF/panel/config');
519
519
  const data = await response.json();
520
520
 
521
521
  if (data.content) {
@@ -531,7 +531,7 @@
531
531
  try {
532
532
  const content = configEditor.value;
533
533
 
534
- const response = await fetch('/panel/AEF/config', {
534
+ const response = await fetch('/AEF/panel/config', {
535
535
  method: 'POST',
536
536
  headers: {
537
537
  'Content-Type': 'application/json'
@@ -564,7 +564,7 @@
564
564
  // 切换AEF状态
565
565
  toggleAefBtn.addEventListener('click', async () => {
566
566
  try {
567
- const response = await fetch('/panel/AEF/toggle', {
567
+ const response = await fetch('/AEF/panel/toggle', {
568
568
  method: 'POST',
569
569
  headers: {
570
570
  'Content-Type': 'application/json'
@@ -606,7 +606,7 @@
606
606
  if (!isLoggedIn) return;
607
607
 
608
608
  try {
609
- const response = await fetch('/panel/AEF/log');
609
+ const response = await fetch('/AEF/panel/log');
610
610
  const data = await response.json();
611
611
 
612
612
  if (data.log !== currentLogContent) {
package/README.md CHANGED
@@ -112,6 +112,15 @@ http://your-server:3001/panel/AEF
112
112
  - 手动启用/禁用AEF
113
113
  - 手动重启服务器
114
114
 
115
+ ## 访问控制面板
116
+
117
+ AEF提供了一个Web管理界面,可通过以下URL访问:
118
+ ```
119
+ http://your-server:7210/AEF/panel
120
+ ```
121
+
122
+ 默认密码是 `123456`(可在配置文件中修改)。
123
+
115
124
  ## 高级功能
116
125
 
117
126
  ### AI驱动的错误预测
package/index.js CHANGED
@@ -643,12 +643,12 @@ class AEF {
643
643
  this.app.use(express.json());
644
644
 
645
645
  // 控制面板路由
646
- this.app.get('/panel/AEF', (req, res) => {
646
+ this.app.get('/AEF/panel', (req, res) => {
647
647
  res.sendFile(path.join(__dirname, 'DLZstudio', 'AEF', 'views', 'panel.html'));
648
648
  });
649
649
 
650
650
  // 验证密码接口
651
- this.app.post('/panel/AEF/login', (req, res) => {
651
+ this.app.post('/AEF/panel/login', (req, res) => {
652
652
  const { password } = req.body;
653
653
  if (password === this.config.password) {
654
654
  res.json({ success: true });
@@ -658,7 +658,7 @@ class AEF {
658
658
  });
659
659
 
660
660
  // 获取状态接口
661
- this.app.get('/panel/AEF/status', (req, res) => {
661
+ this.app.get('/AEF/panel/status', (req, res) => {
662
662
  res.json({
663
663
  isEnabled: this.isEnabled,
664
664
  config: this.config,
@@ -680,18 +680,18 @@ class AEF {
680
680
  });
681
681
 
682
682
  // 切换AEF状态接口
683
- this.app.post('/panel/AEF/toggle', (req, res) => {
683
+ this.app.post('/AEF/panel/toggle', (req, res) => {
684
684
  this.isEnabled = !this.isEnabled;
685
685
  res.json({ success: true, isEnabled: this.isEnabled });
686
686
  });
687
687
 
688
688
  // 获取日志接口
689
- this.app.get('/panel/AEF/log', (req, res) => {
689
+ this.app.get('/AEF/panel/log', (req, res) => {
690
690
  res.json({ log: this.getLog() });
691
691
  });
692
692
 
693
693
  // 获取配置文件内容
694
- this.app.get('/panel/AEF/config', (req, res) => {
694
+ this.app.get('/AEF/panel/config', (req, res) => {
695
695
  try {
696
696
  const configContent = fs.readFileSync(this.configPath, 'utf8');
697
697
  res.json({ content: configContent });
@@ -701,7 +701,7 @@ class AEF {
701
701
  });
702
702
 
703
703
  // 更新配置文件内容
704
- this.app.post('/panel/AEF/config', (req, res) => {
704
+ this.app.post('/AEF/panel/config', (req, res) => {
705
705
  try {
706
706
  const { content } = req.body;
707
707
  fs.writeFileSync(this.configPath, content);
@@ -730,7 +730,7 @@ class AEF {
730
730
  });
731
731
  });
732
732
 
733
- const port = process.env.AEF_PANEL_PORT || 3001;
733
+ const port = process.env.AEF_PANEL_PORT || 7210;
734
734
  this.server.listen(port, () => {
735
735
  this.log(`AEF控制面板已在端口 ${port} 上启动`, 'info');
736
736
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "auto_error_fixer",
3
- "version": "0.1.5",
3
+ "version": "0.1.6",
4
4
  "description": "AEF (Auto Error Fixer) - 自动故障修复系统,能够自动检测、修复服务器错误并在必要时重启服务器,支持跨平台错误处理",
5
5
  "main": "index.js",
6
6
  "scripts": {