export-login --expires silently ignores dates given in ISO 8601 format

Bug #1928756 reported by Björn Tillenius
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Snapcraft
Triaged
Medium
Unassigned

Bug Description

If you pass the data in ISO 8601 format to export-login --expires:

  snapcraft export-login --expires 2022-01-01 --snaps maas --acls package_release macaroon

You get a macaroon with expiry of None:

  Login successfully exported to 'macroon'. This can now be used with

      snapcraft login --with macaroon

  to log in to this account with no password and have these capabilities:
  snaps: ['maas']
  channels: No restriction
  permissions: ['package_release']
  expires: None

If I pass the date, including the time, it works. But the documentation for export-login says that a date should be enough.

Tags: craft-215
Revision history for this message
Sergio Schvezov (sergiusens) wrote :

We should probably at least error on dates that could not be parsed

Changed in snapcraft:
status: New → Triaged
importance: Undecided → Medium
tags: added: craft-215
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.