Skip to content

chore: bump ahbicht min-version (reduces number of invalid expressions) #128

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 16, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ sqlmodels = [
"sqlalchemy[mypy]>=2.0.37"
]
ahbicht = [
"ahbicht>=0.13.2"
"ahbicht>=0.14.0"
]
coverage = [
"coverage==7.8.0"
Expand Down
141 changes: 2 additions & 139 deletions unittests/__snapshots__/test_sqlmodels_expressions_view.ambr
Original file line number Diff line number Diff line change
Expand Up @@ -596,30 +596,12 @@
# ---
# name: test_create_expressions_table_from_submodule_with_validity
list([
dict({
'ahbicht_error_message': '''
ahb expression: X ([950] [509] ∧ ([64] V [70])) V ([960] [522] ∧ [71] ∧ [53]) Please make sure that the ahb_expression starts with a requirement indicator (i.e Muss/M, Soll/S, Kann/K, X, O, U) and the condition expressions consist of only the following characters: [ ] ( ) U ∧ O ∨ X ⊻ and digits.
condition expression: X ([950] [509] ∧ ([64] V [70])) V ([960] [522] ∧ [71] ∧ [53])
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
* no conditions are empty
* all compositions are combined by operators 'U'/'O'/'X' or without an operator
* all open brackets are closed again and vice versa

''',
'edifact_format_version': 'FV2410',
'expression': 'X ([950] [509] ∧ ([64] V [70])) V ([960] [522] ∧ [71] ∧ [53])',
'format': 'INVOIC',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
Error trying to process rule "CONDITION_EXPRESSION":


condition expression: ([446] ∧ ([465] ∨ [466]) ∧ [467] ∧ ([468] ⊻ ([469] ∧ [470])) ⊻ [448]

condition expression: ([446] ∧ ([465] ∨ [466]) ∧ [467] ∧ ([468] ⊻ ([469] ∧ [470])) ⊻ [448]
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
Expand All @@ -636,29 +618,12 @@
'format': 'UTILMD',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
ahb expression: X ([950] [509] ∧ ([64] V [70])) V ([960] [522] ∧ [71] ∧ [53]) Please make sure that the ahb_expression starts with a requirement indicator (i.e Muss/M, Soll/S, Kann/K, X, O, U) and the condition expressions consist of only the following characters: [ ] ( ) U ∧ O ∨ X ⊻ and digits.
condition expression: X ([950] [509] ∧ ([64] V [70])) V ([960] [522] ∧ [71] ∧ [53])
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
* no conditions are empty
* all compositions are combined by operators 'U'/'O'/'X' or without an operator
* all open brackets are closed again and vice versa

''',
'edifact_format_version': 'FV2504',
'expression': 'X ([950] [509] ∧ ([64] V [70])) V ([960] [522] ∧ [71] ∧ [53])',
'format': 'INVOIC',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
Error trying to process rule "CONDITION_EXPRESSION":


condition expression: ([62] ∧ [108]) ⊻ ([148] ∨ ([149] ∧ [150])
condition expression: ([62] ∧ [108]) ⊻ ([148] ∨ ([149] ∧ [150])
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
Expand All @@ -672,107 +637,5 @@
'format': 'UTILMD',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
ahb expression: X [1P0..n] Please make sure that the ahb_expression starts with a requirement indicator (i.e Muss/M, Soll/S, Kann/K, X, O, U) and the condition expressions consist of only the following characters: [ ] ( ) U ∧ O ∨ X ⊻ and digits.
condition expression: X [1P0..n]
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
* no conditions are empty
* all compositions are combined by operators 'U'/'O'/'X' or without an operator
* all open brackets are closed again and vice versa

''',
'edifact_format_version': 'FV2504',
'expression': 'X [1P0..n]',
'format': 'UTILMD',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
ahb expression: X [1P1..n] Please make sure that the ahb_expression starts with a requirement indicator (i.e Muss/M, Soll/S, Kann/K, X, O, U) and the condition expressions consist of only the following characters: [ ] ( ) U ∧ O ∨ X ⊻ and digits.
condition expression: X [1P1..n]
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
* no conditions are empty
* all compositions are combined by operators 'U'/'O'/'X' or without an operator
* all open brackets are closed again and vice versa

''',
'edifact_format_version': 'FV2504',
'expression': 'X [1P1..n]',
'format': 'UTILMD',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
ahb expression: X [2P0..n] Please make sure that the ahb_expression starts with a requirement indicator (i.e Muss/M, Soll/S, Kann/K, X, O, U) and the condition expressions consist of only the following characters: [ ] ( ) U ∧ O ∨ X ⊻ and digits.
condition expression: X [2P0..n]
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
* no conditions are empty
* all compositions are combined by operators 'U'/'O'/'X' or without an operator
* all open brackets are closed again and vice versa

''',
'edifact_format_version': 'FV2504',
'expression': 'X [2P0..n]',
'format': 'UTILMD',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
ahb expression: X [3P0..n] Please make sure that the ahb_expression starts with a requirement indicator (i.e Muss/M, Soll/S, Kann/K, X, O, U) and the condition expressions consist of only the following characters: [ ] ( ) U ∧ O ∨ X ⊻ and digits.
condition expression: X [3P0..n]
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
* no conditions are empty
* all compositions are combined by operators 'U'/'O'/'X' or without an operator
* all open brackets are closed again and vice versa

''',
'edifact_format_version': 'FV2504',
'expression': 'X [3P0..n]',
'format': 'UTILMD',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
ahb expression: X [4P0..n] Please make sure that the ahb_expression starts with a requirement indicator (i.e Muss/M, Soll/S, Kann/K, X, O, U) and the condition expressions consist of only the following characters: [ ] ( ) U ∧ O ∨ X ⊻ and digits.
condition expression: X [4P0..n]
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
* no conditions are empty
* all compositions are combined by operators 'U'/'O'/'X' or without an operator
* all open brackets are closed again and vice versa

''',
'edifact_format_version': 'FV2504',
'expression': 'X [4P0..n]',
'format': 'UTILMD',
'node_texts': '',
}),
dict({
'ahbicht_error_message': '''
ahb expression: X [5P0..n] Please make sure that the ahb_expression starts with a requirement indicator (i.e Muss/M, Soll/S, Kann/K, X, O, U) and the condition expressions consist of only the following characters: [ ] ( ) U ∧ O ∨ X ⊻ and digits.
condition expression: X [5P0..n]
Please make sure that:
* all conditions have the form [INT]
* all packages have the form [INTPn..m]
* no conditions are empty
* all compositions are combined by operators 'U'/'O'/'X' or without an operator
* all open brackets are closed again and vice versa

''',
'edifact_format_version': 'FV2504',
'expression': 'X [5P0..n]',
'format': 'UTILMD',
'node_texts': '',
}),
])
# ---