u/mfaassen
-
17points
mfaassen
mfaassen
On a lark I tried running the whole AppImage as root. Now the upgrade process works correctly!
I really don't like running things as root, but clearly Bazcor isn't getting quite the right set of permissions on my machine nor does it ask for it when ran as a user.
mfaassen
The title to this post is a bit triggering for me. It's certainly not the end of the firmware updating problems for me. It's never once worked for me on Linux, and it still doesn't.
Under Fedora Linux, it just flashes blue forever. When trying again, it tells me to release the key right away. The firmware is not updated.
mfaassen
[I hadn't checked reddit for a while]
IMHO, a framework's main purpose is to provide some sort of overall structure to an application, typically by providing some sort of abstraction.
I agree with you. I should have been more clear about it in my article, but I do say this:
A framework helps structure the way you write code, making it more declarative
And I agree that the discussion of library versus framework itself is not fundamentally interesting, and that indeed some (micro) frameworks may only help organize a very minor part of your applications. The scope of the term "framework" is a bit too wide, which is why I like to use the terms "micro framework", "mega framework", or possibly "full stack framework".
I think it's cute to think of Array.map as a nano framework, and I think it helps people gain insights in frameworks to do so (is map + filter + reduce a framework for array transformation?), but I realize that it's pushing the concept rather far.
mfaassen
I don't like to bicker about nomenclature either, but I think thinking about why people argue React is a library is nonetheless interesting. A framework is a special case of a library, so in the broad sense React is definitely a library.
If the reason why people argue React is (just) a library is that React is small and focused on the UI portion: I understand the reason, and even though React has grown slightly larger over time, it's still focused.
But since React helps you write declarative components that React decides when to re-render, has pluggable backends, and it even includes an addition to the programming language itself (JSX) I want to call it a framework.
I understand that "framework" to many implies something that covers a broad range of aspects of application construction, and React does not. So I get why people push back against the term framework. That's why I like the term "micro framework" to describe something like React.
Is Express a framework or a library? It's focused on handling HTTP requests and responses. It's a lot less code than React. It calls your code, like React does. I consider Express a micro framework, too, not just a library.
mfaassen
My post at least argues that React is a framework, not a library, and I don't really talk about dependency injection.
mfaassen
Agreed, "super" is very commonly used on Linux for what's the Windows key on Windows. Example from the Gnome documentation:
https://help.gnome.org/users/gnome-help/stable/keyboard-key-super.html.en
And from the Ubuntu docs:
https://help.ubuntu.com/stable/ubuntu-help/keyboard-key-super.html.en
I already found myself in difficulty describing a situation where I wanted to use the tap dance key as a way that involved the super key.
mfaassen
I'm a programmer. I don't have wrist pain but I do have some back issues. I've noticed the Dygma Raise does seem to help my posture: I keep my upper back more straight. So I'm hoping that has the desired long term effect.
Concerning software development: I haven't tried automating anything specific around programming with the Raise. I may get to that eventually, but it's more likely going to be making a few IDE specific keys more convenient, not typing itself.
mfaassen
I've done that too and it works well. I wasn't using the left shift, ctrl, super or fn key anyway so they're now arrow keys.
mfaassen
I ordered mine a few weeks ago. I'm in the EU. I received mine 2 days after ordering.
The warehouse is in the EU, in Spain as far as I know. There are no import taxes if you're in the EU.
mfaassen
I'm a big fan of test-driven development (TDD) and encourage adopting it, but I want to throw in some comments. It's likely your developer already knows much about this, so in which case I apologize to them for saying things they already know.
For complete UIs TTD can make less sense; tests tend to be slow and harder to maintain. That doesn't mean you can't use test-driven development for parts of the UI though but perhaps not the integrated whole.
The trick is that you organize your architecture into modules and layers, trying to focus on data-driven modules with clear boundaries. Those are easy to test using test-driven development.
So for Bazecor that could be a module for the UI that tracks the mapping between keys and keyboard events, or a module that manages keyboard event itself, ensuring that if you use super keys the other aspects of the key event are updated accordingly. You could use some sort of state management library for it (in React-land Redux is popular. I recommend MobX myself), and those can have tests.
Regression testing is useful too. It can help catch problems, but helps less during develompent as it doesn't positively influence the structure of your code like TDD can do when used well.
mfaassen
I've noticed a few small UI misbehaviors when naming layers:
When you click on a layer to name it, the number disappears. This is confusing as I initially thought the number wouldn't be retained. Only when I managed to get out of the naming mode did the number reappear. It would be nicer if the number continues to be displayed in front of the input box.
When I edit a layer name, it's rather difficult to actually leave the naming UI again. Enter doesn't do it. Tab doesn't do it either. Clicking outside doesn't do it either. Only if I click on another layer do I exit this system (which then doesn't select this layer for editing, which requires another click).
When I enter a layer name that is too long (i.e. it becomes a multi-line edit input), the layer is indented into the UI compared to the other layers and generally looks ugly. Are multi-line layers supposed to be supported? The UI lets you enter long layer names, but in this case they don't really display well. It's be fine with only single line layers myself and have enter leave this system.
Are the layer names supposed to be stored in the keyboard? Because the save icon remains grayed out when I just edit layer names. This makes me look for a manual way to trigger a backup.
mfaassen
I have the same problem in Fedora Linux. Blue pulsing mode for Neuron, no matter how long I press the key. When I restart Bazecore, the same too: cannot talk to keyboard (with the {{path}} string that never gets interpolated). In Windows I can flash it, but this time it continues to report I'm on beta9 even after completion - I read elsewhere that's another bug.
This same updating misbehavior has persisted throughout recent updates, except that I'm not even 100% sure I'm on firmware version 10 now. :)
mfaassen
For now, we have both because we're in a transition period. My point is that it currently misleadingly implies you can restore from a backup too, but that doesn't actually work.
I could imagine people would want to exchange individual layers too, but perhaps that will become possible when loading someone else's backup.
mfaassen
Thanks for this explanation! My scenario indeed only involves modifier keys, and I do want a hold there.
mfaassen
I tried that in the upgrade to beta7 but it wouldn't work as it lost the ability to connect to the keyboard at all, so I couldn't even initiate the process.
I haven't tried it this time around and I'm wary of downgrading my firmware to try. I'll try it again with the next beta.
mfaassen
Another piece of feedback about super keys. I tried to make a thumb key be OS (Linux) when held, but when tapped be the space character.
This works if I hold the thumb key by itself, and then immediately press the shift key afterwards. The opposite order, first shift, then hold thumb, also works.
But if I press both space and super thumb key simultaneously, and hold down the super key, I still get space characters (and after a while they repeat). Since I often combine shift with that key, it makes it unreliable so I turned it off again.
The info says that tap doesn't work with modifiers, which I don't quite understand, but this is hold.
Should this work?
mfaassen
As another note: the backtick was set to escape even in my latest backup, so I restored to escape instead of backtick. I don't really see how to easily prevent this problem from happening as it's a consequence of failures during firmware flashing.
mfaassen
I just went to Windows to update the firmware. The first time again Bazecor's UI turned black so I couldn't see any progress bar. The second time it did work, but it hung forever at the "release the key" stage. When I restarted Bazecor the update had been successful, but my backup wasn't restored.
Then I had a keyboard with a default keyboard layout and no colors.
I rebooted to Windows and had a heart-stopping moment as I tried to use the arrow "restore layer/backup" with a backup, but it told me it wasn't a valid file. Finally I found the real restore from backup in the settings screen and everything is fine again with the world. So I suggest you either make the button also restore from backup or just say "layer".
I am really enjoying this keyboard but the firmware updating process isn't ideal yet.
mfaassen
I still have the same problem updating in Linux, this time from firmware version beta7 to version beta9 (using beta9): I hold down the key, the neuron starts growing in blue, and the progress bar never updates. Disconnecting the neuron is the only way to make it stop.
I've remapped escape to backtick but currently it's behaving like escape again, probably because it temporarily set it to escape but then never had a chance to set it back again.
mfaassen
Thanks! A bit more feedback:
I can see the keyboard in Linux and manipulate it just fine on two separate machines.
The udev rule install message that appeared must have worked just fine.
It's just when I do a firmware update that it doesn't work (it just hangs forever until I kill bazecor), then loses the connection and shows a {{path}} visual bug. I think the visual bug shouldn't even appear for me as the keyboard is actually available, but I only get it again if I plug it in again, restarting bazecor doesn't work. And whatever I did, I couldn't get the firmware update to work in Linux.
mfaassen
I found another issue with Layer & Key: it doesn't actually show the layer colors when pressed too. Shift to another layer does update the colors.
mfaassen
I just got the Raise and I like it, but I had some issues with Bazecor so here's my feedback.
I tried 0.3.3 first but couldn't update the firmware on Linux (Fedora 34) properly. It stays flashing blue in bootloader mode indefinitely. Afterwards it's impossible to restart flashing (including after restarting bazecor) because it doesn't find the keyboard anymore. The troubleshooting instructions wouldn't work because of that. I tried it in 1.0b7 but I had the same behavior. Finally I succeeded in Windows, though I had to restart Bazecor there as well. It did lose connection to the keyboard after successfully flashing.
Incidentally on Linux when it fails to find my keyboard (until I plug it into another USB port or disconnect the neuron) then the error message talks about insufficient access (which is incorrect) and puts in a template that hasn't run, as I see {{path}} literally.
The Layer & Key UI needs a thorough debugging:
On the layout editor the layer count starts at layer 1, but visually on the key for a dual layer key (for instance L#1/ENTER) it refers to layer 2 as 1, so there's an off by one error.
It doesn't actually ever highlight the selected key on the keyboard at the bottom, unlike for other keys. It also says NO.KEY in the input.
I select a "dual layer 2" from the dropdown first, the key in the main overview is updated to a long number (for instance #51474).
If I instead first select the key it does update, but the UI immediately disappears and when I select layers again the information is not shown anymore: it says NO.KEY and None selected.
The tab behavior in general is confusing, it switches from layers to superkeys sometimes as well.
mfaassen
Funny how something can go to "outdated and eclectic" in such a short space of its existence.
I think the TurboGears team has been doing good work in updating/rewriting TurboGears to version 2, but the gap between 1 and 2 must've hurt the community a bit.
Note that with Grok you can integrate SQLAlchemy as well, as you can with TurboGears. I've done so for a number of my projects. Modern Zope is pretty good at integrating with ORMs like SQLAlchemy, though the documentation at this point is still lacking.
I had the same experience. I wrote https://docs.rs/xot/latest/xot/ as I really needed a DOM-like API that was read/write for my particular use case, and I couldn't find anything that was both reliable and feature-complete. The one drawback to Xot is that it uses an arena approach so you end up passing a Xot instance everywhere, but overall I think it works well.
I'm working on a lot more in the Rust XML space, but that's still far from done or in public yet.