dsh-eia-guide-check 0.2.0 → 0.2.2
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 +37 -0
- package/README-es.md +23 -1
- package/README-hi.md +23 -1
- package/README-pt.md +23 -1
- package/README-zh.md +23 -1
- package/README.md +23 -1
- package/SECURITY.md +39 -0
- package/package.json +5 -3
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 0.2.2
|
|
4
|
+
|
|
5
|
+
- Rework the README first screen. The H1 now names what the plugin checks rather
|
|
6
|
+
than repeating the package name, and a question-and-answer table and a standards
|
|
7
|
+
table come before the boundary paragraph.
|
|
8
|
+
|
|
9
|
+
The substance is unchanged and the boundary paragraph is verbatim: in a
|
|
10
|
+
compliance tool that paragraph is what stops a wrong "pass" being read as
|
|
11
|
+
approval, so it moved rather than shrank. What changed is the order - a reader
|
|
12
|
+
or an extractor previously met eleven badges, an install command and a
|
|
13
|
+
disclaimer before learning what the plugin does. The Q&A rows are derived from
|
|
14
|
+
each plugin's own rules and the standards table from the rule pack's
|
|
15
|
+
`document`/`number` fields, so no answer and no standard is hand-typed.
|
|
16
|
+
|
|
17
|
+
All five languages were restructured together; `check:readmes` holds them to the
|
|
18
|
+
same section count, install command and configuration keys.
|
|
19
|
+
|
|
20
|
+
## 0.2.1
|
|
21
|
+
|
|
22
|
+
- Ship `CHANGELOG.md` and `SECURITY.md` inside the package. `files` is an
|
|
23
|
+
allowlist and neither was on it, so no release note had ever reached anyone
|
|
24
|
+
who installed this package, and npm had no changelog section to show.
|
|
25
|
+
## 0.2.0
|
|
26
|
+
|
|
27
|
+
- Release infrastructure brought to the family standard: `verify:self-contained`,
|
|
28
|
+
`check:lockfile`, `check:readmes` and `check:citations` gates, a `prepublishOnly` that
|
|
29
|
+
re-runs the whole chain, SECURITY.md, dependabot, and the OpenSSF Scorecard workflow.
|
|
30
|
+
- `check:citations` enforces the rule this pack's own header states: every `excerpt`
|
|
31
|
+
must be a verbatim quotation, findable in `rules/evidence/`. Rules that are not
|
|
32
|
+
traceable yet are listed in `rules/citations-baseline.json`, and that file can only
|
|
33
|
+
shrink - anything new has to be sourced before it can land.
|
|
34
|
+
- The README install command now names the published package instead of a local tarball.
|
|
35
|
+
- Five-language READMEs hold the same section count and the same configuration keys.
|
|
36
|
+
- Rule pack: 7 rules across EG-001..EG-007.
|
|
37
|
+
- Licensed Apache-2.0.
|
package/README-es.md
CHANGED
|
@@ -1,4 +1,26 @@
|
|
|
1
|
-
# dsh-eia-guide-check
|
|
1
|
+
# dsh-eia-guide-check — Verificación de la hoja de aplicabilidad de directrices de evaluación de impacto ambiental
|
|
2
|
+
|
|
3
|
+
`dsh-eia-guide-check` lee una hoja de aplicabilidad de directrices de una evaluación de impacto ambiental —la cabecera del proyecto más una fila por elemento evaluado— y comprueba la trazabilidad de esa propia hoja: que cada elemento indique la directriz que le aplica, que el número de la directriz siga la forma publicada, que el estado de la directriz proceda del vocabulario que usted configure, que se registre un método de evaluación o una norma aplicable, que ningún elemento esté registrado dos veces, que la cabecera declare el proyecto y el tipo de documento de evaluación, y que no quede ningún marcador de plantilla sin sustituir en la columna de la norma aplicable.
|
|
4
|
+
|
|
5
|
+
## Qué responde
|
|
6
|
+
|
|
7
|
+
| Usted pregunta | Qué responde |
|
|
8
|
+
|---|---|
|
|
9
|
+
| Una fila de elemento deja vacíos el nombre y el número de la directriz. ¿Se informa de ello? | Sí. `EG-001` informa de esa fila cuando `guideName` y `guideCode` están ambos vacíos, porque la fila debe indicar al menos uno de los dos. Solo comprueba que se indique una directriz, nunca si es la correcta para ese elemento: el plugin no incluye ningún catálogo de directrices ni asigna elementos a directrices. |
|
|
10
|
+
| El número de la directriz figura como `HJ 2.3`, sin año. ¿Se detecta? | Sí. `EG-002` comprueba la forma «HJ número—año de cuatro cifras», como en `HJ 2.3—2018`, así que un valor sin el año de cuatro cifras no coincide y se informa fila por fila. Solo comprueba la forma: no que el número exista, no que esté vigente y no que corresponda al nombre que figura al lado. Una celda `guideCode` vacía no se informa aquí: los valores vacíos quedan fuera de esta comprobación de forma. |
|
|
11
|
+
| La columna de estado dice `现行`. ¿Por qué no se ha comprobado nunca? | Porque la lista `values` de `EG-003` viene vacía, es decir, el vocabulario de estados aún no está configurado: la regla se declara a sí misma en `skipped`, con el motivo de que ese vocabulario es propio de la institución, en lugar de pasar en silencio. Una vez configurado, solo comprueba que el valor relleno figure en la lista, no que la directriz esté realmente vigente. |
|
|
12
|
+
| El método de evaluación está puesto, pero la columna de la norma aún dice `【待填】`. ¿Se detecta? | `EG-004` solo exige que esté relleno uno de los dos, `method` o `standard`, así que un método relleno la satisface; no juzga si el método es aplicable ni si la norma es correcta. El marcador que queda lo informa `EG-007`, que busca en la columna de la norma los términos configurados (`【`, `】`, `XXX`, `待填`, `TBD`, `示例` y similares) e informa del primero que encuentra. Esos términos son ajustables, y una celda de norma totalmente vacía no la informa ninguna de las dos reglas. |
|
|
13
|
+
| El elemento `地表水` está registrado dos veces, una por calidad del agua y otra por sedimentos. ¿Qué ocurre? | `EG-005` informa del valor repetido de `element` e indica con qué fila anterior coincide, porque la repetición impide saber qué directriz rige ese elemento. Compara solo el texto sin espacios y el hallazgo requiere confirmación humana: evaluar un mismo elemento por medio es habitual, así que escriba el subelemento en el nombre del elemento en vez de borrar la fila. Si la hoja no tiene columna `element`, la regla informa de que no pudo ejecutarse en lugar de pasar en silencio. |
|
|
14
|
+
| La cabecera no trae el nombre del proyecto ni el tipo de documento de evaluación. ¿Qué ocurre? | `EG-006` informa de que a la cabecera le faltan `project` y `reportType`, porque el tipo de documento (`报告书`/`报告表`/`登记表`) determina qué conjunto de requisitos se aplica. Solo comprueba que la cabecera los declare; no juzga si la clasificación del tipo es correcta. |
|
|
15
|
+
|
|
16
|
+
## Normas que sigue
|
|
17
|
+
|
|
18
|
+
| Documento | Número | Reglas que lo citan |
|
|
19
|
+
|---|---|---|
|
|
20
|
+
| 《环境影响评价技术导则》系列 | 各导则现行版本号本次未逐一核实 | EG-001, EG-002 |
|
|
21
|
+
| 本机构环评质量管理口径(本机构配置) | 无统一标准(本条依据为本机构配置的状态口径) | EG-003 |
|
|
22
|
+
| 《环境影响评价技术导则 总纲》 | HJ 2.1(现行版本号与条号本次未核实) | EG-004, EG-005, EG-007 |
|
|
23
|
+
| 《建设项目环境影响评价分类管理名录》 | 现行版本与条号本次未核实 | EG-006 |
|
|
2
24
|
|
|
3
25
|
**Boundary:** this plugin checks an **环评导则适用性核对表** for traceability — that each environmental element
|
|
4
26
|
names its applicable guideline, that the guideline number follows its published form, that the guideline's status
|
package/README-hi.md
CHANGED
|
@@ -1,4 +1,26 @@
|
|
|
1
|
-
# dsh-eia-guide-check
|
|
1
|
+
# dsh-eia-guide-check — पर्यावरण प्रभाव मूल्यांकन दिशानिर्देश प्रयोज्यता शीट की जाँच
|
|
2
|
+
|
|
3
|
+
`dsh-eia-guide-check` पर्यावरण प्रभाव मूल्यांकन की एक दिशानिर्देश-प्रयोज्यता शीट पढ़ता है — परियोजना हेडर और प्रत्येक मूल्यांकित तत्व की एक पंक्ति — और उसी शीट की संदर्भ-योग्यता जाँचता है: क्या हर तत्व अपना लागू दिशानिर्देश बताता है, क्या दिशानिर्देश क्रमांक प्रकाशित रूप में लिखा है, क्या दिशानिर्देश की स्थिति आपके द्वारा कॉन्फ़िगर की गई शब्दावली से ली गई है, क्या मूल्यांकन विधि या लागू मानक दर्ज है, क्या कोई तत्व दो बार दर्ज नहीं है, क्या हेडर परियोजना और मूल्यांकन दस्तावेज़ का प्रकार घोषित करता है, और क्या मानक-कॉलम में कोई अपरिवर्तित टेम्पलेट प्लेसहोल्डर शेष नहीं है।
|
|
4
|
+
|
|
5
|
+
## यह किन सवालों का जवाब देता है
|
|
6
|
+
|
|
7
|
+
| आपका सवाल | इसका जवाब |
|
|
8
|
+
|---|---|
|
|
9
|
+
| किसी तत्व की पंक्ति में दिशानिर्देश का नाम और क्रमांक दोनों खाली हैं। क्या यह दर्ज होता है? | हाँ। जब `guideName` और `guideCode` दोनों खाली हों, `EG-001` उस पंक्ति को दर्ज करता है, क्योंकि पंक्ति को इनमें से कम से कम एक बताना होता है। यह केवल देखता है कि दिशानिर्देश बताया गया है या नहीं, यह नहीं कि वह उस तत्व के लिए सही है: प्लगिन में दिशानिर्देशों की कोई सूची नहीं है और तत्व से दिशानिर्देश की मैपिंग नहीं की जाती। |
|
|
10
|
+
| दिशानिर्देश क्रमांक `HJ 2.3` लिखा है, वर्ष के बिना। क्या यह पकड़ में आता है? | हाँ। `EG-002` «HJ संख्या—चार अंकों का वर्ष» रूप की जाँच करता है, जैसे `HJ 2.3—2018`, इसलिए चार अंकों के वर्ष के बिना मान मेल नहीं खाता और पंक्ति-दर-पंक्ति दर्ज होता है। यह केवल रूप देखता है: न यह कि क्रमांक वास्तव में मौजूद है, न यह कि वह वर्तमान में लागू है, और न यह कि वह बगल के नाम से मेल खाता है। खाली `guideCode` सेल यहाँ दर्ज नहीं होता — खाली मान इस रूप-जाँच से बाहर रहते हैं। |
|
|
11
|
+
| स्थिति कॉलम में `现行` लिखा है। जाँच क्यों नहीं चली? | क्योंकि `EG-003` की `values` सूची खाली आती है, यानी स्थिति की शब्दावली अभी कॉन्फ़िगर नहीं है: नियम चुपचाप पास होने के बजाय `skipped` में स्वयं को दर्ज करता है और बताता है कि यह शब्दावली संस्था की अपनी है। कॉन्फ़िगर करने के बाद भी यह केवल देखता है कि भरा गया मान सूची में है या नहीं, यह नहीं कि दिशानिर्देश वास्तव में लागू है। |
|
|
12
|
+
| मूल्यांकन विधि भरी है, पर मानक-कॉलम में अब भी `【待填】` लिखा है। क्या यह पकड़ में आता है? | `EG-004` केवल इतना चाहता है कि `method` या `standard` में से एक भरा हो, इसलिए विधि भरी होने पर वह पास हो जाता है; यह नहीं आँकता कि विधि लागू है या मानक सही है। शेष प्लेसहोल्डर `EG-007` दर्ज करता है, जो मानक-कॉलम में कॉन्फ़िगर किए गए शब्द खोजता है (`【`, `】`, `XXX`, `待填`, `TBD`, `示例` आदि) और पहला मिला शब्द दर्ज करता है। ये शब्द बदले जा सकते हैं, और पूरी तरह खाली मानक-सेल इन दोनों में से कोई भी नियम दर्ज नहीं करता। |
|
|
13
|
+
| एक ही तत्व `地表水` दो बार दर्ज है — एक बार जल गुणवत्ता और एक बार तलछट के लिए। क्या होता है? | `EG-005` दोहराया गया `element` मान दर्ज करता है और बताता है कि वह किस पिछली पंक्ति से मेल खाता है, क्योंकि दोहराव से यह तय नहीं होता कि उस तत्व पर कौन-सा दिशानिर्देश लागू है। यह केवल बिना रिक्त स्थान वाले पाठ की तुलना करता है और परिणाम के लिए मानवीय पुष्टि ज़रूरी है: एक ही तत्व को माध्यम के अनुसार बाँटना सामान्य है, इसलिए पंक्ति हटाने के बजाय तत्व के नाम में उप-मद लिखें। शीट में `element` कॉलम न हो तो नियम चुपचाप पास होने के बजाय बताता है कि वह चल नहीं सका। |
|
|
14
|
+
| हेडर में परियोजना का नाम नहीं है और मूल्यांकन दस्तावेज़ का प्रकार भी नहीं लिखा। क्या होता है? | `EG-006` दर्ज करता है कि हेडर में `project` और `reportType` नहीं हैं, क्योंकि दस्तावेज़ का प्रकार (`报告书`/`报告表`/`登记表`) तय करता है कि कौन-सा आवश्यकता-समूह लागू होगा। यह केवल देखता है कि हेडर इन्हें घोषित करता है या नहीं; यह नहीं आँकता कि प्रकार का वर्गीकरण सही है। |
|
|
15
|
+
|
|
16
|
+
## यह किन मानकों पर आधारित है
|
|
17
|
+
|
|
18
|
+
| दस्तावेज़ | संख्यांक | इन्हें उद्धृत करने वाले नियम |
|
|
19
|
+
|---|---|---|
|
|
20
|
+
| 《环境影响评价技术导则》系列 | 各导则现行版本号本次未逐一核实 | EG-001, EG-002 |
|
|
21
|
+
| 本机构环评质量管理口径(本机构配置) | 无统一标准(本条依据为本机构配置的状态口径) | EG-003 |
|
|
22
|
+
| 《环境影响评价技术导则 总纲》 | HJ 2.1(现行版本号与条号本次未核实) | EG-004, EG-005, EG-007 |
|
|
23
|
+
| 《建设项目环境影响评价分类管理名录》 | 现行版本与条号本次未核实 | EG-006 |
|
|
2
24
|
|
|
3
25
|
**Boundary:** this plugin checks an **环评导则适用性核对表** for traceability — that each environmental element
|
|
4
26
|
names its applicable guideline, that the guideline number follows its published form, that the guideline's status
|
package/README-pt.md
CHANGED
|
@@ -1,4 +1,26 @@
|
|
|
1
|
-
# dsh-eia-guide-check
|
|
1
|
+
# dsh-eia-guide-check — Verificação da folha de aplicabilidade das diretrizes de avaliação de impacto ambiental
|
|
2
|
+
|
|
3
|
+
`dsh-eia-guide-check` lê uma folha de aplicabilidade de diretrizes de uma avaliação de impacto ambiental —o cabeçalho do projeto mais uma linha por elemento avaliado— e verifica a rastreabilidade dessa própria folha: se cada elemento indica a diretriz que lhe é aplicável, se o número da diretriz segue a forma publicada, se o estado da diretriz vem do vocabulário que você configurar, se está registado um método de avaliação ou uma norma aplicável, se nenhum elemento está registado duas vezes, se o cabeçalho declara o projeto e o tipo de documento de avaliação, e se não resta nenhum marcador de modelo por substituir na coluna da norma aplicável.
|
|
4
|
+
|
|
5
|
+
## O que ele responde
|
|
6
|
+
|
|
7
|
+
| Você pergunta | O que ele responde |
|
|
8
|
+
|---|---|
|
|
9
|
+
| Uma linha de elemento deixa vazios o nome e o número da diretriz. Isso é reportado? | Sim. `EG-001` reporta essa linha quando `guideName` e `guideCode` estão ambos vazios, porque a linha tem de indicar pelo menos um deles. Verifica apenas se uma diretriz é indicada, nunca se é a correta para esse elemento: o plugin não inclui qualquer catálogo de diretrizes nem associa elementos a diretrizes. |
|
|
10
|
+
| O número da diretriz está escrito como `HJ 2.3`, sem ano. Isso é detetado? | Sim. `EG-002` verifica a forma «HJ número—ano de quatro dígitos», como em `HJ 2.3—2018`, pelo que um valor sem o ano de quatro dígitos não corresponde e é reportado linha a linha. Verifica apenas a forma: não que o número exista, não que esteja em vigor e não que corresponda ao nome ao lado. Uma célula `guideCode` vazia não é reportada aqui: os valores vazios ficam fora desta verificação de forma. |
|
|
11
|
+
| A coluna de estado diz `现行`. Porque é que nunca foi verificada? | Porque a lista `values` de `EG-003` vem vazia, ou seja, o vocabulário de estados ainda não está configurado: a regra reporta-se a si própria em `skipped`, com o motivo de que esse vocabulário é da instituição, em vez de passar em silêncio. Depois de configurado, verifica apenas se o valor preenchido consta da lista, não se a diretriz está realmente em vigor. |
|
|
12
|
+
| O método de avaliação está preenchido, mas a coluna da norma ainda diz `【待填】`. Isso é detetado? | `EG-004` exige apenas que um de `method` ou `standard` esteja preenchido, pelo que um método preenchido a satisfaz; não julga se o método é aplicável nem se a norma está correta. O marcador remanescente é reportado por `EG-007`, que procura na coluna da norma os termos configurados (`【`, `】`, `XXX`, `待填`, `TBD`, `示例` e semelhantes) e reporta o primeiro que encontra. Esses termos são ajustáveis, e uma célula de norma totalmente vazia não é reportada por nenhuma das duas regras. |
|
|
13
|
+
| O elemento `地表水` está registado duas vezes, uma para qualidade da água e outra para sedimentos. O que acontece? | `EG-005` reporta o valor repetido de `element` e indica com que linha anterior coincide, porque a repetição impede saber que diretriz rege esse elemento. Compara apenas o texto sem espaços e o resultado exige confirmação humana: avaliar um mesmo elemento por meio é normal, por isso escreva o subelemento no nome do elemento em vez de apagar a linha. Se a folha não tiver coluna `element`, a regra reporta que não pôde ser executada em vez de passar em silêncio. |
|
|
14
|
+
| O cabeçalho não traz o nome do projeto nem o tipo de documento de avaliação. O que acontece? | `EG-006` reporta que faltam ao cabeçalho `project` e `reportType`, porque o tipo de documento (`报告书`/`报告表`/`登记表`) determina que conjunto de requisitos se aplica. Verifica apenas que o cabeçalho os declare; não julga se a classificação do tipo está correta. |
|
|
15
|
+
|
|
16
|
+
## Normas que segue
|
|
17
|
+
|
|
18
|
+
| Documento | Número | Regras que o citam |
|
|
19
|
+
|---|---|---|
|
|
20
|
+
| 《环境影响评价技术导则》系列 | 各导则现行版本号本次未逐一核实 | EG-001, EG-002 |
|
|
21
|
+
| 本机构环评质量管理口径(本机构配置) | 无统一标准(本条依据为本机构配置的状态口径) | EG-003 |
|
|
22
|
+
| 《环境影响评价技术导则 总纲》 | HJ 2.1(现行版本号与条号本次未核实) | EG-004, EG-005, EG-007 |
|
|
23
|
+
| 《建设项目环境影响评价分类管理名录》 | 现行版本与条号本次未核实 | EG-006 |
|
|
2
24
|
|
|
3
25
|
**Boundary:** this plugin checks an **环评导则适用性核对表** for traceability — that each environmental element
|
|
4
26
|
names its applicable guideline, that the guideline number follows its published form, that the guideline's status
|
package/README-zh.md
CHANGED
|
@@ -1,4 +1,26 @@
|
|
|
1
|
-
# dsh-eia-guide-check
|
|
1
|
+
# dsh-eia-guide-check — 环评导则适用性核对
|
|
2
|
+
|
|
3
|
+
`dsh-eia-guide-check` 读取一份环境影响评价的导则适用性核对表——表头、加上每条评价要素一行——并核对这份核对表自身是否可追溯:每条要素是否指明适用导则、导则编号是否写成通用形式、导则状态是否取自本机构配置的取值、是否填写了评价方法或执行标准、要素是否重复登记、表头是否声明项目与环评文件类型、执行标准栏是否残留未替换的模板占位符。
|
|
4
|
+
|
|
5
|
+
## 它回答什么问题
|
|
6
|
+
|
|
7
|
+
| 你会问 | 它怎么答 |
|
|
8
|
+
|---|---|
|
|
9
|
+
| 某条要素行的适用导则名称与编号都是空的,会被报出吗? | 会。`guideName` 与 `guideCode` 都为空时,`EG-001` 报出该行,因为这一行至少要指明其中一项。它只核对是否指明了导则,**不核对指明得对不对**:本插件不内置导则清单,也不做要素到导则的映射。 |
|
|
10
|
+
| 导则编号写成 `HJ 2.3`,没有年份,会被报出吗? | 会。`EG-002` 按「HJ 数字—四位年份」的形式核对(如 `HJ 2.3—2018`),没有四位年份就匹配不上,会逐行报出。它只核对形式:不核对编号是否真实存在、是否现行有效,也不核对是否与旁边的名称对应。`guideCode` 栏为空时本条不报——空值不参与这项形式核对。 |
|
|
11
|
+
| 状态栏填的是 `现行`,为什么没查? | 因为 `EG-003` 的 `values` 出厂为空,表示状态口径尚未配置:本条在 `skipped` 中报告自己不执行,并说明这一取值口径由本机构规定,而不是静默通过。配置之后,它也只核对所填值是否在册,不判断该导则是否真的现行有效。 |
|
|
12
|
+
| 评价方法填了,但执行标准栏还写着 `【待填】`,能查出来吗? | `EG-004` 只要求 `method` 与 `standard` 至少填了一个,方法填了它就通过;它不判断方法是否适用、标准是否正确。残留的占位符由 `EG-007` 报出:它在执行标准栏里找配置的占位符词(`【`、`】`、`XXX`、`待填`、`TBD`、`示例` 等),报出命中的那一个。这些词可按本机构模板调整;执行标准栏整个为空时,这两条都不报。 |
|
|
13
|
+
| 同一要素 `地表水` 登记了两次,一次水质、一次底泥,会怎样? | `EG-005` 报出重复的 `element` 值,并指出与哪一行重复,因为重复会让人无法判断该要素按哪一本导则评价。它只比对去掉空白后的字面值,且命中需要人工确认:同一要素分环境介质评价是常见情形,应在要素名称里写清子项,而不是简单删行。材料没有 `element` 栏时,本条报告无法执行,而不是静默通过。 |
|
|
14
|
+
| 表头没有项目名称,也没写环评文件类型,会怎样? | `EG-006` 报出表头缺少 `project`、`reportType`,因为环评文件类型(`报告书`/`报告表`/`登记表`)决定了适用哪一套要求。它只核对表头是否声明,不判断该类型划分是否正确。 |
|
|
15
|
+
|
|
16
|
+
## 依据的标准
|
|
17
|
+
|
|
18
|
+
| 文件 | 文号 | 引用它的规则 |
|
|
19
|
+
|---|---|---|
|
|
20
|
+
| 《环境影响评价技术导则》系列 | 各导则现行版本号本次未逐一核实 | EG-001, EG-002 |
|
|
21
|
+
| 本机构环评质量管理口径(本机构配置) | 无统一标准(本条依据为本机构配置的状态口径) | EG-003 |
|
|
22
|
+
| 《环境影响评价技术导则 总纲》 | HJ 2.1(现行版本号与条号本次未核实) | EG-004, EG-005, EG-007 |
|
|
23
|
+
| 《建设项目环境影响评价分类管理名录》 | 现行版本与条号本次未核实 | EG-006 |
|
|
2
24
|
|
|
3
25
|
**Boundary:** this plugin checks an **环评导则适用性核对表** for traceability — that each environmental element
|
|
4
26
|
names its applicable guideline, that the guideline number follows its published form, that the guideline's status
|
package/README.md
CHANGED
|
@@ -1,4 +1,26 @@
|
|
|
1
|
-
# dsh-eia-guide-check
|
|
1
|
+
# dsh-eia-guide-check — Environmental impact assessment guideline applicability sheet check
|
|
2
|
+
|
|
3
|
+
`dsh-eia-guide-check` reads one guideline-applicability sheet for an environmental impact assessment — the project header plus one row per assessed element — and checks that sheet's own traceability: that every element names its applicable guideline, that the guideline number follows the published form, that the guideline's status comes from the vocabulary you configure, that an assessment method or an applicable standard is recorded, that no element is registered twice, that the header declares the project and the report type, and that no unreplaced template placeholder survives in the standard column.
|
|
4
|
+
|
|
5
|
+
## What it answers
|
|
6
|
+
|
|
7
|
+
| You ask | What it answers |
|
|
8
|
+
|---|---|
|
|
9
|
+
| One element row leaves both the guideline name and the guideline number blank. Is that reported? | Yes. `EG-001` reports the row when `guideName` and `guideCode` are both empty, because the row has to name at least one of them. It checks only whether a guideline is named, never whether the named guideline is the right one for that element: the plugin holds no guideline catalogue and does not map an element onto a guideline. |
|
|
10
|
+
| The guideline number is written as `HJ 2.3`, with no year. Is that caught? | Yes. `EG-002` checks the form `HJ <number>—<four-digit year>`, as in `HJ 2.3—2018`, so a value without the four-digit year does not match and is reported row by row. It checks the form only: not whether the number exists, not whether it is current, and not whether it matches the name beside it. A blank `guideCode` cell is left alone — empty values stay outside this form check. |
|
|
11
|
+
| The status column says `现行`. Why was it never checked? | Because `EG-003`'s `values` list ships empty, meaning the status vocabulary is not configured yet: the rule reports itself in `skipped`, with the reason that this vocabulary is the institution's own, rather than passing silently. Once configured, it checks only whether the filled value is on that list — not whether the guideline is really in force. |
|
|
12
|
+
| The assessment method is filled in, but the standard column still reads `【待填】`. Is that caught? | `EG-004` requires only that one of `method` or `standard` is filled, so a filled method satisfies it; it does not judge whether the method applies or the standard is correct. The leftover placeholder is caught by `EG-007`, which reports the first configured term it finds in the standard column (`【`, `】`, `XXX`, `待填`, `TBD`, `示例` and similar). Those terms are adjustable, and a wholly empty standard cell is reported by neither rule. |
|
|
13
|
+
| `地表水` is registered twice, once for water quality and once for sediment. What happens? | `EG-005` reports the repeated `element` value and names the earlier row it matches, because a duplicate makes it impossible to tell which guideline governs that element. It compares the text with whitespace removed only, and the finding needs human confirmation: assessing one element by medium is normal, so write the sub-item into the element name instead of deleting the row. With no `element` column the rule reports that it could not run rather than passing silently. |
|
|
14
|
+
| The header carries no project name and no report type. What happens? | `EG-006` reports the header as missing `project` and `reportType`, because the report type (`报告书`/`报告表`/`登记表`) decides which set of requirements applies. It checks only that the header declares them; it does not judge whether the type was classified correctly. |
|
|
15
|
+
|
|
16
|
+
## Standards it follows
|
|
17
|
+
|
|
18
|
+
| Document | Number | Cited by rules |
|
|
19
|
+
|---|---|---|
|
|
20
|
+
| 《环境影响评价技术导则》系列 | 各导则现行版本号本次未逐一核实 | EG-001, EG-002 |
|
|
21
|
+
| 本机构环评质量管理口径(本机构配置) | 无统一标准(本条依据为本机构配置的状态口径) | EG-003 |
|
|
22
|
+
| 《环境影响评价技术导则 总纲》 | HJ 2.1(现行版本号与条号本次未核实) | EG-004, EG-005, EG-007 |
|
|
23
|
+
| 《建设项目环境影响评价分类管理名录》 | 现行版本与条号本次未核实 | EG-006 |
|
|
2
24
|
|
|
3
25
|
**Boundary:** this plugin checks an **环评导则适用性核对表** for traceability — that each environmental element
|
|
4
26
|
names its applicable guideline, that the guideline number follows its published form, that the guideline's status
|
package/SECURITY.md
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Security Policy
|
|
2
|
+
|
|
3
|
+
## Reporting a vulnerability
|
|
4
|
+
|
|
5
|
+
Please report security vulnerabilities **privately** through GitHub's private
|
|
6
|
+
vulnerability reporting:
|
|
7
|
+
|
|
8
|
+
**Security → Report a vulnerability** at
|
|
9
|
+
https://github.com/PerryLink/dsh-eia-guide-check/security/advisories/new
|
|
10
|
+
|
|
11
|
+
Do **not** open a public issue for security findings.
|
|
12
|
+
|
|
13
|
+
Before reporting, **sanitize everything you paste**: remove tokens, API keys,
|
|
14
|
+
credentials, authorization headers, session contents, and personal data. Logs
|
|
15
|
+
without secrets only.
|
|
16
|
+
|
|
17
|
+
## Scope note
|
|
18
|
+
|
|
19
|
+
This plugin is an offline checker. It reads the material you hand it and
|
|
20
|
+
compares it against a versioned rule pack; it makes no network calls and no
|
|
21
|
+
model calls, and it stores nothing.
|
|
22
|
+
|
|
23
|
+
## What to include
|
|
24
|
+
|
|
25
|
+
- affected package version (and DeepSeek Harness runtime version)
|
|
26
|
+
- a minimal reproduction
|
|
27
|
+
- your impact assessment
|
|
28
|
+
|
|
29
|
+
## Response expectations
|
|
30
|
+
|
|
31
|
+
- acknowledgement within **7 days**
|
|
32
|
+
- status updates at least every **14 days** until resolution
|
|
33
|
+
- coordinated disclosure: the fix and advisory are prepared first; the finding
|
|
34
|
+
is disclosed publicly after the fix ships
|
|
35
|
+
|
|
36
|
+
## Credits and disclosure
|
|
37
|
+
|
|
38
|
+
- reporters are credited in the advisory and CHANGELOG unless they ask to stay anonymous
|
|
39
|
+
- advisories follow GitHub's advisory workflow and are published together with the fix
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-eia-guide-check",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.2",
|
|
4
4
|
"description": "环评导则适用性核对(按要素、导则名称与执行标准核对台账自洽,仅提示差异,不作出定性结论)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.mjs",
|
|
@@ -23,7 +23,9 @@
|
|
|
23
23
|
"README-hi.md",
|
|
24
24
|
"locale/*.json",
|
|
25
25
|
"icon.svg",
|
|
26
|
-
"rules"
|
|
26
|
+
"rules",
|
|
27
|
+
"CHANGELOG.md",
|
|
28
|
+
"SECURITY.md"
|
|
27
29
|
],
|
|
28
30
|
"scripts": {
|
|
29
31
|
"build": "tsdown",
|
|
@@ -32,7 +34,7 @@
|
|
|
32
34
|
"verify:self-contained": "node scripts/verify-self-contained.mjs",
|
|
33
35
|
"check:lockfile": "node scripts/check-lockfile-drift.mjs",
|
|
34
36
|
"check:readmes": "node scripts/check-readme-sync.mjs",
|
|
35
|
-
"prepublishOnly": "pnpm run typecheck && pnpm test && pnpm run build && pnpm run verify:self-contained && pnpm run check:readmes && pnpm run check:citations",
|
|
37
|
+
"prepublishOnly": "pnpm run typecheck && pnpm test && pnpm run build && pnpm run verify:self-contained && pnpm run check:lockfile && pnpm run check:readmes && pnpm run check:citations",
|
|
36
38
|
"prepare": "tsdown",
|
|
37
39
|
"check:citations": "node scripts/check-citations.mjs"
|
|
38
40
|
},
|