Skip to content

Conversation

@joente
Copy link
Member

@joente joente commented Nov 29, 2024

Description

This pull request fixes an incorrect error when using a function where a user or token is not found. Both a token and user do not honor the naming rules but when not found, the error message is generated by a function which is build for names which must apply to the naming rule.

Example:

del_user('123');  // user 123 does not exist

The code above returns with a ValueError (naming rule) but 123 is valid for a user.

Expected:
A LookupError is expected (the same applies for a token not found).

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

  • Test thingsdb functions

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • New and existing unit tests pass locally with my changes

@joente joente added the bug label Nov 29, 2024
@joente joente self-assigned this Nov 29, 2024
@joente joente merged commit ce46600 into main Nov 29, 2024
1 check passed
@joente joente deleted the usererr branch February 7, 2025 09:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants