Skip to content

Conversation

@jona159
Copy link
Contributor

@jona159 jona159 commented Dec 10, 2025

Type of Change

  • Dependency upgrade
  • Bug fix (non-breaking change)
  • Breaking change
    • e.g. a fixed bug or new feature that may break something else
  • New feature
  • Code quality improvements
    • e.g. refactoring, documentation, tests, tooling, ...

Implementation

Checklist

  • I gave this pull request a meaningful title
  • My pull request is targeting the dev branch
  • I have added documentation to my code
  • I have deleted code that I have commented out

Additional Information

  • This PR closes #

@socket-security
Copy link

socket-security bot commented Dec 10, 2025

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Added@​types/​pg@​8.15.61001007392100

View full report

@jona159 jona159 linked an issue Dec 10, 2025 that may be closed by this pull request
@jona159 jona159 marked this pull request as ready for review December 17, 2025 08:52
Copy link
Collaborator

@scheidtdav scheidtdav left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you check the two lint alerts @jona159

Comment on lines 16 to 17
return `opensensemap_org-${action}-${encodeURI(
encodeURI(params.join('-')),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that is really strange. Do we really want to keep that?

If the first encoding pass would result in invalid characters, wouldn't the second pass also potentially produce invalid characters and both should be avoided entirely?

Vice-versa, if the first one already takes care of encoding, why bother doing it again? It just makes the result longer and less readable.

Maybe this was added by mistake by @ubergesundheit or there is something we don't know :-)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since it is just creating a filename i just removed the first encoding for now...

try {
const collected = collectParameters(request, params)
if (collected instanceof Response) return collected
// eslint-disable-next-line @typescript-eslint/no-unused-vars
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a reason to disable the warning rather than just not unpacking the vars from collected?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm i dont think i made changes to this file (other than formatting). I removed the deviceId from the destructured object and the comment here as deviceId was unused


const normalizedParams = {
phenomenon: getParam(['phenomenon']),
boxId: getParam(['boxId', 'boxid']), // boxId in docs, but effectively boxid was used, so support both?
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd say we should either support all fallbacks of the original implementation or just stick to boxId in the correct spelling. If we do add case-insenstivness here, we would also have to do it elsewhere, don't you think?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I adjusted to use only boxid as this is what the old app used (docs were falsly stating boxId here). I would agree we should stick with one case and not add case-insensitivness everywhere now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

migrate /boxes/data

3 participants