Skip to content

interpret return codes for users #991

Open
@mitzimorris

Description

@mitzimorris

Summary:

Improve error hadling by mapping stan::services::error_codes to messages that make sense to end-user.

Description:

Module stan::services adopted a small set of POSIX error codes following Unix conventions -
https://github.com/stan-dev/stan/blob/develop/src/stan/services/error_codes.hpp

Use of these codes is not consistent across the services, nor does command.hpp do a very good job of interpreting them for the user. Modify command.hpp to provide better feedback for common user mistakes, such as missing data inputs, etc.

All exceptions thrown from command.hpp are caught by main.cpp which uniformly returns error code 70 (stan::services::error_codes::SOFTWARE).

The stan::services error codes shouldn't be reported to end user in CmdStan. Instead, we should replace error code 70 et all with more generally accepted codes

Current Version:

v2.26.1

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions