Commit Graph

694 Commits

Author SHA1 Message Date
Louis Gesbert
edd6dce0d8 Disable recursive tests reset for now; remove rel paths in test out 2023-08-04 12:08:18 +02:00
Louis Gesbert
378669b09e Implement reversing the dependencies for tests
This works for the `--reset` option, but I have some doubts about it.
2023-08-04 12:08:18 +02:00
Aminata-Dev
94f8eac858 Better indications for the user :
- We're able to say from the parser what the user could have written. It may not be complete due to the acceptable function of Menhir : it is only an indication given to the user (and not intended to be an adaptive documentation)
- .mli file added : module interface for suggestions
- Add a test that provides a typographical or a logical error.
- Documentation and type / name changes for suggestions
2023-07-12 16:32:55 +02:00
Aminata-Dev
af9c708960 Better help for the user
- Clearer (more detailed) error messages (see parser.messages, parser_driver.ml ->)
	--> Parser_driver.ml : we're more precise and show all possible instructions to the user.
- Suggestions.ml : unimportant display changes + renaming
2023-07-12 11:55:11 +02:00
Aminata-Dev
b0d16c1a58 Tests updated 2023-07-12 11:55:11 +02:00
Aminata-Dev
b087ca4f47 Improve suggestions
- Improved implementation of suggestions (suggestion_minimum_levenshtein_distance_association > suggestions.ml)
- Magnifying glass emoji added for suggestions
- Improve display by...
	- Fixing "Pos.ml" (pretty-printing box not closed)
	- Remove unnecessary spaces
- compiler/surface/parserdriver.ml
	- Optionnal suggestions added when raising a parser error
	- Function "levenshtein_distance" removed and replaced by "Suggestions.levenshtein_distance"
- Tests updated (mostly line breaks and spacing changes)
- Variable names renamed for greater clarity
- (Based on commit 0813f5c36e)
2023-07-12 11:55:11 +02:00
Aminata-Dev
75b6251b43 Match the compiler code to the new type of error message content 2023-07-12 11:55:11 +02:00
Denis Merigoux
50113586e3 With @aminata-dev update Messages.Content 2023-07-12 11:55:11 +02:00
Louis Gesbert
89e90271c1 Implement an additional localised, user-facing value printer 2023-07-03 16:42:54 +02:00
Louis Gesbert
0f9ee2c72e Refacter the main Driver module
- Use separate functions for successive passes in module `Driver.Passes`
- Use other functions for end results printing in module `Driver.Commands`

As a consequence, it is much more flexible to use by plugins or libs and we no
longer need the complex polymorphic variant parameter.

This patch leverages previous changes to use Cmdliner subcommands and
effectively specialises the flags of each Catala subcommand.

Other changes include:

- an attempt to normalise the generic options and reduce the number of global
  references. Some are ok, like `debug` ; some would better be further cleaned up,
  e.g. the ones used by Proof backend were moved to a `Proof.globals` module and
  need discussion. The printer no longer relies on the global languages and prints
  money amounts in an agnostic way.
- the plugin directory is automatically guessed and loaded even in dev setups.
  Plugins are shown by the main `catala` command and listed in `catala --help`
- exception catching at the toplevel has been refactored a bit as well; return
  codes are normalised to follow the manpage and avoid codes >= 128 that are
  generally reserved for shells.

Update tests
2023-07-03 16:42:54 +02:00
Denis Merigoux
26dd6012b1
Better French wording 2023-06-27 10:48:58 +02:00
Siggy Scott
b034613499 Correct a variable name in the French-language tutorial. 2023-06-23 13:22:58 -04:00
Siggy Scott
20aa04eb96 Tweak tutorial language in response to #273. 2023-06-23 08:33:47 -04:00
Denis Merigoux
5f48e5dac1
Merge branch 'master' into closure_conversion 2023-06-20 11:02:13 +02:00
Denis Merigoux
615ad54f08
Remove unmaintained examples (fix #468) (#480) 2023-06-20 10:25:43 +02:00
Denis Merigoux
71ead0c6fa
Remove all mentions 2023-06-19 12:01:06 +02:00
Denis Merigoux
0ca42cbcf9
Fix headings 2023-06-19 11:37:58 +02:00
Denis Merigoux
147e70feed
Remove unmaintained examples (fix #468) 2023-06-19 11:21:00 +02:00
Denis Merigoux
420348beda Added a last TODO and put big example under CI 2023-06-18 21:38:00 +02:00
Louis Gesbert
691d81ba72 Makefiles: fix catala arguments order
the command name now needs to be first
2023-06-18 18:35:39 +02:00
Louis Gesbert
fcadd9808e Update tests with whitespace changes 2023-06-08 14:03:08 +02:00
Denis Merigoux
6bc4cbd066
New SMIC value: Update assets 2023-05-25 18:48:23 +02:00
Denis Merigoux
38081245b8
Really fix #466 2023-05-23 16:39:21 +02:00
Denis Merigoux
a00501fffa
Fix typo causing bad parsing 2023-05-23 15:39:41 +02:00
Denis Merigoux
e092679b75
Fixing #466 by reversing exception precedence 2023-05-23 14:12:26 +02:00
Denis Merigoux
d70886431d
Fix false positive found by proof mode with an assertion clearly stating the impossible situations 2023-04-28 10:39:19 +02:00
Denis Merigoux
e6bccd716d
Fix a Catala program bug thanks to Proof mode! 2023-04-27 18:03:27 +02:00
Denis Merigoux
a954942fd9
Bug in the law found with proof mode? 2023-04-27 16:58:40 +02:00
Denis Merigoux
9b056f3ca1
Update assets and fix errors after rebase 2023-04-27 12:18:50 +02:00
Denis Merigoux
14dd879cc5
Restore tests, update assets 2023-04-27 12:14:27 +02:00
Denis Merigoux
e920529fad
Fix with informations by @JusBanuls 2023-04-27 12:14:16 +02:00
Denis Merigoux
9b06bb66db
Fix tests and restore CI 2023-04-27 12:14:16 +02:00
Denis Merigoux
1b35d6f064
Update allocations_familiales to correct legislative wording 2023-04-27 12:13:50 +02:00
Denis Merigoux
3e61bd633c
Update BMAF 2023-04-27 12:13:50 +02:00
Denis Merigoux
26078d2882
Plus d'informations 2023-04-27 12:13:50 +02:00
Denis Merigoux
7451516ba2
Beginning to incorporate remarks by DHUP 2023-04-27 12:13:50 +02:00
Denis Merigoux
ada8e4941a
Delete variable EVERYWHERE 2023-04-27 12:13:50 +02:00
Denis Merigoux
e7f56b4310
Removed useless variable 2023-04-27 12:13:19 +02:00
Denis Merigoux
28577c7a5e
Fix tests with @JusBanuls 2023-04-27 12:10:47 +02:00
Denis Merigoux
25d6178d42
Add training lines 2023-04-27 12:10:47 +02:00
JusBanuls
537acd320d
Ajouts de plusieurs tests et correction de bugs 2023-04-27 12:10:14 +02:00
Denis Merigoux
75c2a24b98
Changed position formatting 2023-04-27 12:09:22 +02:00
Denis Merigoux
ea4d6dcafe
Fixes by Justine 2023-04-27 12:09:22 +02:00
Denis Merigoux
19b33eaa96
Add lint and fix bugs related 2023-04-27 12:09:22 +02:00
Denis Merigoux
b2beec0bcc
Fixing #444 and #445 2023-04-27 12:09:22 +02:00
Denis Merigoux
dd3965c639
Fix typo 2023-04-27 12:08:00 +02:00
Denis Merigoux
3f1ed227d5
Fix small heading issues 2023-04-27 12:08:00 +02:00
JusBanuls
891ebbddff
Ajout d'un test AL locatif pour Saint-Pierre-et-Miquelon 2023-04-27 12:08:00 +02:00
Denis Merigoux
f877544368
Remove optimizations for big tests 2023-04-18 15:56:04 +02:00
Denis Merigoux
0ec75ad589
Merge branch 'master' into adelaett-withoutexceptionsfix 2023-04-18 14:37:02 +02:00