WhyNotHugo

WhyNotHugo

π = 3

Member Since 11 years ago

Amsterdam, The Netherlands

Experience Points
149
follower
Lessons Completed
12
follow
Lessons Completed
608
stars
Best Reply Awards
106
repos

1514 contributions in the last year

Pinned
⚡ ✅ A simple, standards-based, cli todo (aka: task) manager.
⚡ 📇 Synchronize calendars and contacts.
⚡ ㊙️ Create standard barcodes with Python. No external dependencies. 100% Organic Python.
⚡ ⚖️ AFIP invoice integration for django.
⚡ 📄 A Django app to render django templates as PDF files.
⚡ Universal payment handling for Django.
Activity
May
21
8 hours ago
Activity icon
issue

WhyNotHugo issue comment WhyNotHugo/django-afip

WhyNotHugo
WhyNotHugo

Add discount field

A discount field should be added.

Activity icon
issue

WhyNotHugo issue comment WhyNotHugo/django-afip

WhyNotHugo
WhyNotHugo

DataError: value too long for type character varying(24) when trying to fetch point of sales

Hi, I recently came across an issue when trying to fetch point of sales from a given taxpayer. I'm using

django=3.2.13
python=3.10.4
postgresql=14

When I run taxpayer.fetch_point_of_sales() an exception occurs. The traceback is the following:

---------------------------------------------------------------------------
DoesNotExist                              Traceback (most recent call last)
File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:581, in QuerySet.get_or_create(self, defaults, **kwargs)
    580 try:
--> 581     return self.get(**kwargs), False
    582 except self.model.DoesNotExist:

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:435, in QuerySet.get(self, *args, **kwargs)
    434 if not num:
--> 435     raise self.model.DoesNotExist(
    436         "%s matching query does not exist." %
    437         self.model._meta.object_name
    438     )
    439 raise self.model.MultipleObjectsReturned(
    440     'get() returned more than one %s -- it returned %s!' % (
    441         self.model._meta.object_name,
    442         num if not limit or num < limit else 'more than %s' % (limit - 1),
    443     )
    444 )

DoesNotExist: PointOfSales matching query does not exist.

During handling of the above exception, another exception occurred:

StringDataRightTruncation                 Traceback (most recent call last)
File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:84, in CursorWrapper._execute(self, sql, params, *ignored_wrapper_args)
     83 else:
---> 84     return self.cursor.execute(sql, params)

StringDataRightTruncation: value too long for type character varying(24)


The above exception was the direct cause of the following exception:

DataError                                 Traceback (most recent call last)
Input In [34], in <cell line: 1>()
----> 1 tp.fetch_points_of_sales()

File /usr/local/lib/python3.10/site-packages/django_afip/models.py:468, in TaxPayer.fetch_points_of_sales(self, ticket)
    465 results = []
    466 for pos_data in response.ResultGet.PtoVenta:
    467     results.append(
--> 468         PointOfSales.objects.update_or_create(
    469             number=pos_data.Nro,
    470             owner=self,
    471             defaults={
    472                 "issuance_type": pos_data.EmisionTipo,
    473                 "blocked": pos_data.Bloqueado == "N",
    474                 "drop_date": parsers.parse_date(pos_data.FchBaja),
    475             },
    476         )
    477     )
    479 return results

File /usr/local/lib/python3.10/site-packages/django/db/models/manager.py:85, in BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_method(self, *args, **kwargs)
     84 def manager_method(self, *args, **kwargs):
---> 85     return getattr(self.get_queryset(), name)(*args, **kwargs)

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:608, in QuerySet.update_or_create(self, defaults, **kwargs)
    604 self._for_write = True
    605 with transaction.atomic(using=self.db):
    606     # Lock the row so that a concurrent update is blocked until
    607     # update_or_create() has performed its save.
--> 608     obj, created = self.select_for_update().get_or_create(defaults, **kwargs)
    609     if created:
    610         return obj, created

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:588, in QuerySet.get_or_create(self, defaults, **kwargs)
    586     with transaction.atomic(using=self.db):
    587         params = dict(resolve_callables(params))
--> 588         return self.create(**params), True
    589 except IntegrityError:
    590     try:

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:453, in QuerySet.create(self, **kwargs)
    451 obj = self.model(**kwargs)
    452 self._for_write = True
--> 453 obj.save(force_insert=True, using=self.db)
    454 return obj

File /usr/local/lib/python3.10/site-packages/django/db/models/base.py:739, in Model.save(self, force_insert, force_update, using, update_fields)
    736     if loaded_fields:
    737         update_fields = frozenset(loaded_fields)
--> 739 self.save_base(using=using, force_insert=force_insert,
    740                force_update=force_update, update_fields=update_fields)

File /usr/local/lib/python3.10/site-packages/django/db/models/base.py:776, in Model.save_base(self, raw, force_insert, force_update, using, update_fields)
    774     if not raw:
    775         parent_inserted = self._save_parents(cls, using, update_fields)
--> 776     updated = self._save_table(
    777         raw, cls, force_insert or parent_inserted,
    778         force_update, using, update_fields,
    779     )
    780 # Store the database on which the object was saved
    781 self._state.db = using

File /usr/local/lib/python3.10/site-packages/django/db/models/base.py:881, in Model._save_table(self, raw, cls, force_insert, force_update, using, update_fields)
    878     fields = [f for f in fields if f is not meta.auto_field]
    880 returning_fields = meta.db_returning_fields
--> 881 results = self._do_insert(cls._base_manager, using, fields, returning_fields, raw)
    882 if results:
    883     for value, field in zip(results[0], returning_fields):

File /usr/local/lib/python3.10/site-packages/django/db/models/base.py:919, in Model._do_insert(self, manager, using, fields, returning_fields, raw)
    914 def _do_insert(self, manager, using, fields, returning_fields, raw):
    915     """
    916     Do an INSERT. If returning_fields is defined then this method should
    917     return the newly created data for the model.
    918     """
--> 919     return manager._insert(
    920         [self], fields=fields, returning_fields=returning_fields,
    921         using=using, raw=raw,
    922     )

File /usr/local/lib/python3.10/site-packages/django/db/models/manager.py:85, in BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_method(self, *args, **kwargs)
     84 def manager_method(self, *args, **kwargs):
---> 85     return getattr(self.get_queryset(), name)(*args, **kwargs)

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:1270, in QuerySet._insert(self, objs, fields, returning_fields, raw, using, ignore_conflicts)
   1268 query = sql.InsertQuery(self.model, ignore_conflicts=ignore_conflicts)
   1269 query.insert_values(fields, objs, raw=raw)
-> 1270 return query.get_compiler(using=using).execute_sql(returning_fields)

File /usr/local/lib/python3.10/site-packages/django/db/models/sql/compiler.py:1416, in SQLInsertCompiler.execute_sql(self, returning_fields)
   1414 with self.connection.cursor() as cursor:
   1415     for sql, params in self.as_sql():
-> 1416         cursor.execute(sql, params)
   1417     if not self.returning_fields:
   1418         return []

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:98, in CursorDebugWrapper.execute(self, sql, params)
     96 def execute(self, sql, params=None):
     97     with self.debug_sql(sql, params, use_last_executed_query=True):
---> 98         return super().execute(sql, params)

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:66, in CursorWrapper.execute(self, sql, params)
     65 def execute(self, sql, params=None):
---> 66     return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:75, in CursorWrapper._execute_with_wrappers(self, sql, params, many, executor)
     73 for wrapper in reversed(self.db.execute_wrappers):
     74     executor = functools.partial(wrapper, executor)
---> 75 return executor(sql, params, many, context)

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:79, in CursorWrapper._execute(self, sql, params, *ignored_wrapper_args)
     77 def _execute(self, sql, params, *ignored_wrapper_args):
     78     self.db.validate_no_broken_transaction()
---> 79     with self.db.wrap_database_errors:
     80         if params is None:
     81             # params default might be backend specific.
     82             return self.cursor.execute(sql)

File /usr/local/lib/python3.10/site-packages/django/db/utils.py:90, in DatabaseErrorWrapper.__exit__(self, exc_type, exc_value, traceback)
     88 if dj_exc_type not in (DataError, IntegrityError):
     89     self.wrapper.errors_occurred = True
---> 90 raise dj_exc_value.with_traceback(traceback) from exc_value

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:84, in CursorWrapper._execute(self, sql, params, *ignored_wrapper_args)
     82     return self.cursor.execute(sql)
     83 else:
---> 84     return self.cursor.execute(sql, params)

DataError: value too long for type character varying(24)

For context:

https://github.com/WhyNotHugo/django-afip/blob/ef2e3c8bc6f100193dced99ec230194afbb19c8e/django_afip/models.py#L460-L462 The response in the line above is:

{
    'ResultGet': {
        'PtoVenta': [
            {
                'Nro': 7,
                'EmisionTipo': 'CAEA - Ri Iva CONTINGENCIA',
                'Bloqueado': 'N',
                'FchBaja': 'NULL'
            }
        ]
    },
    'Errors': None,
    'Events': None
}

This results in a length of 26 characters for EmisionTipo, which is too long for the issuance_type field defined in PointOfSales model.

WhyNotHugo
WhyNotHugo

Thanks. If we don't get a reply in a couple of days, we can push this to just 32.

Activity icon
issue

WhyNotHugo issue comment WhyNotHugo/django-afip

WhyNotHugo
WhyNotHugo

DataError: value too long for type character varying(24) when trying to fetch point of sales

Hi, I recently came across an issue when trying to fetch point of sales from a given taxpayer. I'm using

django=3.2.13
python=3.10.4
postgresql=14

When I run taxpayer.fetch_point_of_sales() an exception occurs. The traceback is the following:

---------------------------------------------------------------------------
DoesNotExist                              Traceback (most recent call last)
File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:581, in QuerySet.get_or_create(self, defaults, **kwargs)
    580 try:
--> 581     return self.get(**kwargs), False
    582 except self.model.DoesNotExist:

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:435, in QuerySet.get(self, *args, **kwargs)
    434 if not num:
--> 435     raise self.model.DoesNotExist(
    436         "%s matching query does not exist." %
    437         self.model._meta.object_name
    438     )
    439 raise self.model.MultipleObjectsReturned(
    440     'get() returned more than one %s -- it returned %s!' % (
    441         self.model._meta.object_name,
    442         num if not limit or num < limit else 'more than %s' % (limit - 1),
    443     )
    444 )

DoesNotExist: PointOfSales matching query does not exist.

During handling of the above exception, another exception occurred:

StringDataRightTruncation                 Traceback (most recent call last)
File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:84, in CursorWrapper._execute(self, sql, params, *ignored_wrapper_args)
     83 else:
---> 84     return self.cursor.execute(sql, params)

StringDataRightTruncation: value too long for type character varying(24)


The above exception was the direct cause of the following exception:

DataError                                 Traceback (most recent call last)
Input In [34], in <cell line: 1>()
----> 1 tp.fetch_points_of_sales()

File /usr/local/lib/python3.10/site-packages/django_afip/models.py:468, in TaxPayer.fetch_points_of_sales(self, ticket)
    465 results = []
    466 for pos_data in response.ResultGet.PtoVenta:
    467     results.append(
--> 468         PointOfSales.objects.update_or_create(
    469             number=pos_data.Nro,
    470             owner=self,
    471             defaults={
    472                 "issuance_type": pos_data.EmisionTipo,
    473                 "blocked": pos_data.Bloqueado == "N",
    474                 "drop_date": parsers.parse_date(pos_data.FchBaja),
    475             },
    476         )
    477     )
    479 return results

File /usr/local/lib/python3.10/site-packages/django/db/models/manager.py:85, in BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_method(self, *args, **kwargs)
     84 def manager_method(self, *args, **kwargs):
---> 85     return getattr(self.get_queryset(), name)(*args, **kwargs)

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:608, in QuerySet.update_or_create(self, defaults, **kwargs)
    604 self._for_write = True
    605 with transaction.atomic(using=self.db):
    606     # Lock the row so that a concurrent update is blocked until
    607     # update_or_create() has performed its save.
--> 608     obj, created = self.select_for_update().get_or_create(defaults, **kwargs)
    609     if created:
    610         return obj, created

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:588, in QuerySet.get_or_create(self, defaults, **kwargs)
    586     with transaction.atomic(using=self.db):
    587         params = dict(resolve_callables(params))
--> 588         return self.create(**params), True
    589 except IntegrityError:
    590     try:

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:453, in QuerySet.create(self, **kwargs)
    451 obj = self.model(**kwargs)
    452 self._for_write = True
--> 453 obj.save(force_insert=True, using=self.db)
    454 return obj

File /usr/local/lib/python3.10/site-packages/django/db/models/base.py:739, in Model.save(self, force_insert, force_update, using, update_fields)
    736     if loaded_fields:
    737         update_fields = frozenset(loaded_fields)
--> 739 self.save_base(using=using, force_insert=force_insert,
    740                force_update=force_update, update_fields=update_fields)

File /usr/local/lib/python3.10/site-packages/django/db/models/base.py:776, in Model.save_base(self, raw, force_insert, force_update, using, update_fields)
    774     if not raw:
    775         parent_inserted = self._save_parents(cls, using, update_fields)
--> 776     updated = self._save_table(
    777         raw, cls, force_insert or parent_inserted,
    778         force_update, using, update_fields,
    779     )
    780 # Store the database on which the object was saved
    781 self._state.db = using

File /usr/local/lib/python3.10/site-packages/django/db/models/base.py:881, in Model._save_table(self, raw, cls, force_insert, force_update, using, update_fields)
    878     fields = [f for f in fields if f is not meta.auto_field]
    880 returning_fields = meta.db_returning_fields
--> 881 results = self._do_insert(cls._base_manager, using, fields, returning_fields, raw)
    882 if results:
    883     for value, field in zip(results[0], returning_fields):

File /usr/local/lib/python3.10/site-packages/django/db/models/base.py:919, in Model._do_insert(self, manager, using, fields, returning_fields, raw)
    914 def _do_insert(self, manager, using, fields, returning_fields, raw):
    915     """
    916     Do an INSERT. If returning_fields is defined then this method should
    917     return the newly created data for the model.
    918     """
--> 919     return manager._insert(
    920         [self], fields=fields, returning_fields=returning_fields,
    921         using=using, raw=raw,
    922     )

File /usr/local/lib/python3.10/site-packages/django/db/models/manager.py:85, in BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_method(self, *args, **kwargs)
     84 def manager_method(self, *args, **kwargs):
---> 85     return getattr(self.get_queryset(), name)(*args, **kwargs)

File /usr/local/lib/python3.10/site-packages/django/db/models/query.py:1270, in QuerySet._insert(self, objs, fields, returning_fields, raw, using, ignore_conflicts)
   1268 query = sql.InsertQuery(self.model, ignore_conflicts=ignore_conflicts)
   1269 query.insert_values(fields, objs, raw=raw)
-> 1270 return query.get_compiler(using=using).execute_sql(returning_fields)

File /usr/local/lib/python3.10/site-packages/django/db/models/sql/compiler.py:1416, in SQLInsertCompiler.execute_sql(self, returning_fields)
   1414 with self.connection.cursor() as cursor:
   1415     for sql, params in self.as_sql():
-> 1416         cursor.execute(sql, params)
   1417     if not self.returning_fields:
   1418         return []

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:98, in CursorDebugWrapper.execute(self, sql, params)
     96 def execute(self, sql, params=None):
     97     with self.debug_sql(sql, params, use_last_executed_query=True):
---> 98         return super().execute(sql, params)

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:66, in CursorWrapper.execute(self, sql, params)
     65 def execute(self, sql, params=None):
---> 66     return self._execute_with_wrappers(sql, params, many=False, executor=self._execute)

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:75, in CursorWrapper._execute_with_wrappers(self, sql, params, many, executor)
     73 for wrapper in reversed(self.db.execute_wrappers):
     74     executor = functools.partial(wrapper, executor)
---> 75 return executor(sql, params, many, context)

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:79, in CursorWrapper._execute(self, sql, params, *ignored_wrapper_args)
     77 def _execute(self, sql, params, *ignored_wrapper_args):
     78     self.db.validate_no_broken_transaction()
---> 79     with self.db.wrap_database_errors:
     80         if params is None:
     81             # params default might be backend specific.
     82             return self.cursor.execute(sql)

File /usr/local/lib/python3.10/site-packages/django/db/utils.py:90, in DatabaseErrorWrapper.__exit__(self, exc_type, exc_value, traceback)
     88 if dj_exc_type not in (DataError, IntegrityError):
     89     self.wrapper.errors_occurred = True
---> 90 raise dj_exc_value.with_traceback(traceback) from exc_value

File /usr/local/lib/python3.10/site-packages/django/db/backends/utils.py:84, in CursorWrapper._execute(self, sql, params, *ignored_wrapper_args)
     82     return self.cursor.execute(sql)
     83 else:
---> 84     return self.cursor.execute(sql, params)

DataError: value too long for type character varying(24)

For context:

https://github.com/WhyNotHugo/django-afip/blob/ef2e3c8bc6f100193dced99ec230194afbb19c8e/django_afip/models.py#L460-L462 The response in the line above is:

{
    'ResultGet': {
        'PtoVenta': [
            {
                'Nro': 7,
                'EmisionTipo': 'CAEA - Ri Iva CONTINGENCIA',
                'Bloqueado': 'N',
                'FchBaja': 'NULL'
            }
        ]
    },
    'Errors': None,
    'Events': None
}

This results in a length of 26 characters for EmisionTipo, which is too long for the issuance_type field defined in PointOfSales model.

WhyNotHugo
WhyNotHugo

Huh, I've never seen this value before. Do you know if there is a list of all possible values? If so we can check the longest possible value. Otherwise, we can just extend it to 32.

May
20
1 day ago
Activity icon
issue

WhyNotHugo issue comment keepassxreboot/keepassxc

WhyNotHugo
WhyNotHugo

Browser access request prompt is not a real popup

Overview

When using a tiling compositor, the "Browser Access Request" prompt is not treated as a popup / dialog window, but rather as a normal window.

This makes it get tiled as other top-level windows. E.g.: If I have my browser taking up all the screen, the Browser Access Request opens up as a huge window taking up half the screen.

Steps to Reproduce

I can reproduce this on swaywm. I expect that the same issue is reproducible on i3wm, but don't have an X11 setup to confirm this.

  1. Run KeePassXC and a browser with the plugin installed
  2. Attempt to auto-fill somewhere (make sure the entry has not been previously authorised).

Expected Behavior

A reasonably sized prompt should show up.

Actual Behavior

The prompt shows up as a regular window which gets tiled to occupy a huge part of the screen.

Context

KeePassXC - 2.7.1

Operating System: Linux Desktop Env: swaywm Windowing System: Wayland

Extra notes

The popup shown with the "Show OTP" menu option works fine. It would seem the properties used to declare that one as a "small floating popup" work fine, so should work okay for this other popup too.

WhyNotHugo
WhyNotHugo

When KeePassXC is locked, if I click on the browser plugin button, and click "Reopen database" I get a popup to provide credentials. That one works properly.

Does the Auto-Type selection dialog do the same?

Does this work on Linux/Wayland? I can't find how to trigger this.

The TOTP dialog

This one works perfect.

The only difference I can spot between the TOTP compared to the others is that the others are set to be "Always on Top".

AFAIK, the concept of "always on top" is not supported on Wayland... the concept does not exist at a protocol level. Not sure what Qt does in this case.

Activity icon
issue

WhyNotHugo issue darkreader/darkreader

WhyNotHugo
WhyNotHugo

[Broken Website] Colours are inverted for https://containertoolbx.org/

Broken Website Report

https://containertoolbx.org/ has a light background when Dark Reader is enabled for that domain, but the background turns black when Dark Reader is off.

Website Address

https://containertoolbx.org/

Steps To Reproduce

  1. Visit https://containertoolbx.org/
  2. Make sure Dark Reader is enabled
  3. Background looks very bright and light.
  4. In Dark Reader settings, toggle "Enabled for this website".
  5. The background is now dark.

Problematic Observation

See steps to repro.

See screenshots.

Screenshots

image

image

System Information

  • OS: Linux 5.17.7-arch1-2 GNU/Linux
  • Browser:

Firefox 100

  • Dark Reader Version: 4.9.50

Additional Context

Activity icon
issue

WhyNotHugo issue comment syncthing/syncthing-android

WhyNotHugo
WhyNotHugo

App manifest allowBackup="false" reasoning?

Hi all, I was making a (long overdue) backup solution for my phone in case anything were to happen (using LineageOS's SeedVault utility) and noticed Syncthing was in the list of apps that do not allow Application data to be backed up. As per the manifest android:allowBackup="false" is present, so this is definitely the case. Just wondering why this decision was made and was wondering if there was a way to make it so syncthing could be backed up using the default android utilities. I ask this because I am aware you can backup and restore configurations from within the app, however that requires both manual intervention and the exported configuration is unencrypted, unlike SeedVault's. I'm not familiar with android app development so if there was a reason behind this I wouldn't be aware of it, unfortunately.

Thanks for any information!

Version Information

App Version: 1.20.1
Syncthing Version: v1.20.1
Android Version: LineageOS 19.1 (Android 12)
WhyNotHugo
WhyNotHugo

It's because of https://github.com/syncthing/syncthing-android/commit/95c2f7d98af2783bef2b9b42751ad6e1938b9753.

Data folder contains private key, so one could imitate this node with the backed up key.

The same thing that is seen as a risk (one could imitate the note with data from the backup) is also a feature (one can restore the node from the backup). Personally, I keep backups so I can recreate my device from those backups, so having the key there is a feature.

There seems to be an API for applications to indicate that they should only be backed up if the backup is encrypted (I've no idea why anyone would do an unencrypted backup, but whatever). There's a pretty thorough explanation here: https://community.signalusers.org/t/support-native-android-backupagent-based-client-side-encrypted-backups-and-device-to-device-transfers/19135

Maybe allowing backups only if the backup is encrypted is a reasonable compromise?

Activity icon
issue

WhyNotHugo issue comment ONLYOFFICE/DesktopEditors

WhyNotHugo
WhyNotHugo

Blurry appearance when running on Wayland

Running 6.1.0.90, on Manjaro KDE with Wayland With fractional scaling at 2x on HiDPI screen

Screenshot_20210201_114757

WhyNotHugo
WhyNotHugo

Since CEF seems to be the blocker, probably using something like Tauri could be a good approach, but that's a lot of work.

Activity icon
issue

WhyNotHugo issue comment seedvault-app/seedvault

WhyNotHugo
WhyNotHugo

USBC SSD not being recognised

I'm trying to use an external SSD for backups, but it seems it's not considered a valid option:

image

The UI does say "USB flash drive", which I guess refers to a thumb drive and not an actual disk, but I don't think there's a technical different in how they communicate with the host. Shouldn't this work?

The drive is a Samsung Portable SSD T5 and I'm using LineageOS 18.

WhyNotHugo
WhyNotHugo

Do you see the drive in the "Files" app?

Nowhere obvious: not on the main screen nor on the hamburger menu.

Perhaps it needs more power than the phone can provide over USB,

The disk LED does turn on, but that doesn't imply anything. I suspect that this might be the issue; any ideas on how to figure out if this is the case? I'm using a OnePlus 9.

or it has a filesystem that's not supported by the phone.

It's a regular ext4 partition. Nothing fancy, no LUKS or anything alike.

Activity icon
issue

WhyNotHugo issue comment librespot-org/librespot

WhyNotHugo
WhyNotHugo

Why do you cross-compile on CI rather than just have a workflow run on ARM natively?

Activity icon
delete

WhyNotHugo in WhyNotHugo/librespot delete branch bump-msrv

deleted time in 22 hours ago
Activity icon
issue

WhyNotHugo issue comment flathub/rest.insomnia.Insomnia

WhyNotHugo
WhyNotHugo

Any chance of arm64?

Thanks for the work on the flatpak!

I see it the build was locked down to x86_64 a little way back. Is there any possibility of an arm64 build?

WhyNotHugo
WhyNotHugo

This package currently uses upstream binaries, and upstream only provides amd64 binaries. There's two ways to get arm64 support here:

  • Nag upstream about providing amd64 binaries.
  • Rewrite this flatpak to build from source (this sounds like the cleanest approach).
Activity icon
issue

WhyNotHugo issue flathub/rest.insomnia.Insomnia

WhyNotHugo
WhyNotHugo

I am not able to import collections from a file

I'm trying to import a collection from a file but Insomnia can't access any folder and consequently I can't import the collection using the file.

Screenshot from 2021-12-16 13-27-06

Activity icon
issue

WhyNotHugo issue comment flathub/rest.insomnia.Insomnia

WhyNotHugo
WhyNotHugo

I am not able to import collections from a file

I'm trying to import a collection from a file but Insomnia can't access any folder and consequently I can't import the collection using the file.

Screenshot from 2021-12-16 13-27-06

WhyNotHugo
WhyNotHugo

Closing, but pinning since this will be a recurring question.

Activity icon
issue

WhyNotHugo issue comment flathub/rest.insomnia.Insomnia

WhyNotHugo
WhyNotHugo

I am not able to import collections from a file

I'm trying to import a collection from a file but Insomnia can't access any folder and consequently I can't import the collection using the file.

Screenshot from 2021-12-16 13-27-06

WhyNotHugo
WhyNotHugo

Editing the desktop file is a bad idea; it'll be overwritten on the next update. Generally, editing package-provided files is a great way for breakage.

The right approach is to configure a local override, and give Insomnia permissions to access the directory where you keep your insomnia files.

It seems like the flatpak exec command should include the additional argument --filesystem=home.

Be warned that this grants Insomnia access to your entire filesystem. It pretty much negates the point of a sandbox entirely; Insomnia can read any files, and slip in the right files to highjack your session entirely. Some Flatpak applications do this, and they sacrifice security for the sake of convenience. This will be fixed definitely once Electron uses the FileChooser portal, and Insomnia updates to a compatible Electron version.

Activity icon
delete

WhyNotHugo in WhyNotHugo/librespot delete branch avoid-unwrap-disco

deleted time in 22 hours ago
Activity icon
issue

WhyNotHugo issue comment librespot-org/librespot

WhyNotHugo
WhyNotHugo

Oh, CI failures are already present in master, so not caused by this PR.

Activity icon
issue

WhyNotHugo issue seedvault-app/seedvault

WhyNotHugo
WhyNotHugo

USBC SSD not being recognised

I'm trying to use an external SSD for backups, but it seems it's not considered a valid option:

image

The UI does say "USB flash drive", which I guess refers to a thumb drive and not an actual disk, but I don't think there's a technical different in how they communicate with the host. Shouldn't this work?

The drive is a Samsung Portable SSD T5 and I'm using LineageOS 18.

push

WhyNotHugo push WhyNotHugo/librespot

WhyNotHugo
WhyNotHugo

Use libmdns 0.7 to avoid packet 47 error

WhyNotHugo
WhyNotHugo

Merge pull request #1000 from Gnarflord/dev

Bump libmdns to 0.7

WhyNotHugo
WhyNotHugo

Remove the volume sample iteration (#986)

Move volume calculations out of their own separate samples iteration and into the normalisation iteration

commit sha: 4fd7ac24ce637a9668bcd69718aa899d7ca00480

push time in 1 day ago
Activity icon
issue

WhyNotHugo issue comment pimutils/khal

WhyNotHugo
WhyNotHugo

RuntimeError: You need Click 5.0.

I have recently installed python 3.10.4 and upgraded all packages.

khal list

is giving following error :

Traceback (most recent call last):
  File "/home/murali/.local/bin/khal", line 5, in <module>
    from khal.cli import main_khal
  File "/home/murali/.local/lib/python3.10/site-packages/khal/cli.py", line 31, in <module>
    import click_log
  File "/home/murali/.local/lib/python3.10/site-packages/click_log/__init__.py", line 10, in <module>
    raise RuntimeError('You need Click 5.0.')
RuntimeError: You need Click 5.0.

click version is : 8.1.3

WhyNotHugo
WhyNotHugo

Odd. The versions all seem correct, and it doesn't look like different environments are being mixed up.

If you run a python shell and then run import click; print(click.__version__), does that match? What does hasattr(click, 'get_current_context') show?

push

WhyNotHugo push WhyNotHugo/librespot

WhyNotHugo
WhyNotHugo

Use libmdns 0.7 to avoid packet 47 error

WhyNotHugo
WhyNotHugo

Merge pull request #1000 from Gnarflord/dev

Bump libmdns to 0.7

WhyNotHugo
WhyNotHugo

Remove the volume sample iteration (#986)

Move volume calculations out of their own separate samples iteration and into the normalisation iteration

WhyNotHugo
WhyNotHugo

Avoid crashing when Avahi is not available

When librespot is built with Avahi turned on, it will crash if Avahi is later not available at runtime.

This change avoids it crashing hard when Avahi is not available; librespot will merely warn of the issue.

This affects some distribution packages too, where the maintainer might prefer leaving Avahi support enabled, but many setups don't (or can't) run Avahi.

Co-authored-by: Nick Steel [email protected]

commit sha: c4af90f5febaa99b80e1ae9fbed8f638150728f5

push time in 1 day ago
Activity icon
issue

WhyNotHugo issue comment InfiniTimeOrg/InfiniTime

WhyNotHugo
WhyNotHugo

"Find My Phone" functionality with Gadgetbridge

I used that feature quite a bit when i was daily driving my Miband. Not sure about what the best place to put it would be though. It doesn't justify being a full watchapp, but the quick settings are full.

WhyNotHugo
WhyNotHugo

There's actually a Bluetooth profile for this: https://www.bluetooth.org/docman/handlers/downloaddoc.ashx?doc_id=239389

I think it would be wise to implement the standard, so rather than require phones to have specific Infinitime support for this, they just need to support the standard.

Also relevant: https://www.bluetooth.com/specifications/specs/find-me-profile-1-0/

Activity icon
issue

WhyNotHugo issue comment InfiniTimeOrg/InfiniTime

WhyNotHugo
WhyNotHugo

Find my phone

Verification

  • I searched for similar feature request and found none was relevant.

Pitch us your idea!

Implement "Find my phone": make my phone ring so I can find it.

Description

I often leave my phone lying around in random places. It's usually the same 2-3 spots, but sometimes it's some super weird location and it takes me a long time to find it.

I'd like to tap a button on my watch and make my phone ring so I can find it. There's actually a Bluetooth profile for this: https://www.bluetooth.org/docman/handlers/downloaddoc.ashx?doc_id=239389

I think it would be wise to implement the standard, so rather than require phones to have specific Infinitime support for this, they just need to support the standard.

Also relevant: https://www.bluetooth.com/specifications/specs/find-me-profile-1-0/

WhyNotHugo
WhyNotHugo

Oh, I must have made a typo in my search, because that did definitely not show up in the three results I had when searching. :sweat_smile:

May
19
2 days ago
Activity icon
issue

WhyNotHugo issue InfiniTimeOrg/InfiniTime

WhyNotHugo
WhyNotHugo

Find my phone

Verification

  • I searched for similar feature request and found none was relevant.

Pitch us your idea!

Implement "Find my phone": make my phone ring so I can find it.

Description

I often leave my phone lying around in random places. It's usually the same 2-3 spots, but sometimes it's some super weird location and it takes me a long time to find it.

I'd like to tap a button on my watch and make my phone ring so I can find it. There's actually a Bluetooth profile for this: https://www.bluetooth.org/docman/handlers/downloaddoc.ashx?doc_id=239389

I think it would be wise to implement the standard, so rather than require phones to have specific Infinitime support for this, they just need to support the standard.

Also relevant: https://www.bluetooth.com/specifications/specs/find-me-profile-1-0/

Activity icon
issue

WhyNotHugo issue comment pimutils/khal

WhyNotHugo
WhyNotHugo

RuntimeError: You need Click 5.0.

I have recently installed python 3.10.4 and upgraded all packages.

khal list

is giving following error :

Traceback (most recent call last):
  File "/home/murali/.local/bin/khal", line 5, in <module>
    from khal.cli import main_khal
  File "/home/murali/.local/lib/python3.10/site-packages/khal/cli.py", line 31, in <module>
    import click_log
  File "/home/murali/.local/lib/python3.10/site-packages/click_log/__init__.py", line 10, in <module>
    raise RuntimeError('You need Click 5.0.')
RuntimeError: You need Click 5.0.

click version is : 8.1.3

WhyNotHugo
WhyNotHugo

Not an issue for me with click 8.1.3.

Just to confirm you don't have multiple pythons/clicks, can you check the following:

  • pip --version points to /home/murali/.local/lib/python3.10/site-packages/pip
  • pip freeze | grep click shows 8.1.3
Activity icon
issue

WhyNotHugo issue comment signalapp/Signal-Android

WhyNotHugo
WhyNotHugo

Multi-character emojis in names render the wrong character on profile pictures


Bug description

I have a contact name Bob 🇨🇿 (I know a few people with the same name, so an emoji in the contact's name is super handy. Name if fictitious in this example).

Note that this flag (and all flags, actually) is actually a two-part unicode glyph, which is 🇨 and 🇳 one after the other.

Steps to reproduce

  • Name a contact with a second name starting with a flag emoji, or another emoji which is multiple characters.
  • Click new message.

Make sure you pick a contact with no actual profile picture.

Actual result: Signal renders profile pictures for contacts based on the first letter of their first and last name, which in this case, should be considered B🇨🇿.

Expected result: It seems signal doesn't parse unicode correctly somehow, but the contact's profile pic actually contains B🇨, which is incorrect (and confusing).

Device info

Device: OnePlus 9 Android version: LineageOS 18 Signal version: 5.35.3

May
18
3 days ago
Activity icon
issue

WhyNotHugo issue comment npm/cli

WhyNotHugo
WhyNotHugo

[BUG] Extra .npm directory created in user's home while npm_config_cache set

Is there an existing issue for this?

  • I have searched the existing issues

This issue exists in the latest npm version

  • I am using the latest npm

Current Behavior

A ~/.npm directory gets created on npm install along with the correct directory specified in npm_config_cache. On a fresh install without a cache created yet, the size of the extra ~/.npm directory is 2.1 MiB and the size of the specified ~/.cache/npm directory is 89.1 MiB.

Expected Behavior

Obey the npm_config_cache without creating the extra directory in home.

Steps To Reproduce

npm install a package while having npm_config_cache set to a location other than default. The extra directory is created at the end of install.

Environment

  • npm: 8.5.5
  • node: v18.1.0
  • OS Name: Linux 5.17.7-arch1-2 GNU/Linux
  • System Model Name: n/a
  • npm config: -
WhyNotHugo
WhyNotHugo

no idea why you’d think that’s a bot.

The message ends with "Closing: This is an automated message.".

This issue has no title set, so i doubt it will get proper attention. Can you give it a proper title?

My bad, fixed.

Activity icon
delete

WhyNotHugo in WhyNotHugo/neomutt.github.io delete branch update-bootstrap-and-header

deleted time in 2 days ago
Activity icon
created branch

WhyNotHugo in WhyNotHugo/cobra create branch replace-all

createdAt 2 days ago
Previous