AtmoOrb fix numLeds

The AtmoOrb platform works greath, but unfortinately the "numLeds" configuration parmeter does not work.
If you set "numLeds = 1" you get messages like: "\0xC0\0xFF\0xEE\0x04\0x01\0xRR\0xGG\0xBB", the first 3 bytes (\0xC0\0xFF\0xEE) are identification, the 4th byte (0x04) is command type (smoothing on/off), the 5th byte (0x01) is OrbId and the 6th to 8th byte are the collor of the first hyperion grabbing area (ledindex=0)
If you set "numLeds = 2" you get messages like: "\0xC0\0xFF\0xEE\0x04\0x01\0xRR\0xGG\0xBB\0x00\0x00\0x00", the extra last 3 bytes are always 0, no mather how many leds you define in hyperion config.
If you set "numLeds = 3" you get messages like: "\0xC0\0xFF\0xEE\0x04\0x01\0xRR\0xGG\0xBB\0x00\0x00\0x00\0x00\0x00\0x00", again all aditional bytes are just 0 and so on if you keep increasing numLeds.
The "orbIds" configuration parameter does work, if you specify "orbIds=[1,2]" you will get 2 subsequent messages on the MCAST group at each analysed hyperion picture:
"\0xC0\0xFF\0xEE\0x04\0x01\0xRR1\0xGG1\0xBB1" and
"\0xC0\0xFF\0xEE\0x04\0x02\0xRR2\0xGG2\0xBB2"
where the first message contains the collor (RR1,GG1,BB1) from the first hyperion grabbing area (ledindex=0), and the second message contains the collor (RR2,GG2,BB2) from the second hyperion grabbing area (ledindex=1)
What I perpose is the following:
use "numLeds" to fill the collors in one message and then continue whith the same "numLeds" for the following orbId.
So if "numLeds = 3" and "orbIds=[1,2]" the following messages would be sent:
"\0xC0\0xFF\0xEE\0x04\0x01\0xRR1\0xGG1\0xBB1\0xRR2\0xGG2\0xBB2\0xRR3\0xGG3\0xBB3" and
"\0xC0\0xFF\0xEE\0x04\0x02\0xRR4\0xGG4\0xBB4\0xRR5\0xGG5\0xBB5\0xRR6\0xGG6\0xBB6"
where (RR1,GG1,BB1) is the color from area ledindex=0, (RR2,GG2,BB2) is the color from area ledindex=1, (RR3,GG3,BB3) is the color from area ledindex=2 etc...

The file hyperion/libsrc/leddevice/LedDeviceAtmoOrb.cpp needs to be edited to make this work.
specifically the int LedDeviceAtmoOrb::write(const std::vector <ColorRgb> &ledValues) (line 38) and void LedDeviceAtmoOrb::setColor(unsigned int orbId, const ColorRgb &color, int commandType) (line 99) functions need to be edited.
LedDeviceAtmoOrb::setColor just needs to accept an list of color values instead of a single value and line 116 to 118 needs to change to a loop over the colors in this list.
The for loop over all ledindexes on line 61 needs to be addapted a bit in order to supply lists of lenght numLeds to the setColor function on line 74 and 82.
@RickDB I know you are active on the hyperion github and you have helpt me a couple of times before, thank you so much for that!
Would you maybe be willing to code the sugestion I made in this issue and fix this?
It is pretty simple and a small PR, but I have never coded in C++, I only know Python, C and Matlab. I am sure this would be much easier for you.

Could you create a pull request ?
Sounds like you’ve done the hard work.
I’m guessing Hyperion.ng has the same bug too

Could you create a pull request ?
Sounds like you’ve done the hard work.
I’m guessing Hyperion.ng has the same bug too

Been a while since I touched this code as originally wrote it, what I'm wondering if this will break any existing setup but don't think so by your code suggestion :)
If you want can make a PR and if not will get my rusty C++ skills out and give it a go.

@penfold42 Well that's the problem, I know what code needs to change and globally how it needs to be changed, but I have never programmed in C++.
Therefore I do not know the syntax, I am looking for someone who understands Hyperion and knows C++ to do the coding...

@RickDB would be awesome if you could make a PR.
Then I can look at your code and learn a bit of C++ in the meantime :)

@starkillerOG No worries will make a PR and let the team review it afterwards just in case 👍

Just one question:

The for loop over all ledindexes on line 61 needs to be addapted a bit in order to supply lists of lenght numLeds to the setColor function on line 74 and 82.

ledValues contains all the colors for each led index and orb IDs so we can't parse the whole list and is typically just one color.
As Orb ID 1 = index 0 | Orb ID 2 = index 2, and numLeds is used as the buffer size on the AtmoOrb (photon device) sketch as well.
Could you give a me Python example by any chance (doesn't need to be detailed)?
WIP progress C++ sketch is here if you want to take a peek which loops thru the led values already:
https://gist.github.com/RickDB/512e0d6c030321a59a08f0a232d965c9

This is a working python script that does what I propose, I made it look like the C++ script as much as I could, only the lastColorxxxxMap has been commented out because I did not quite understand where that map is first set.
The ColorRgb list is of course supplyed by hyperion from the grabbed screen image and sendCommand schould of course truly sent the data over UDP.
def sendCommand(bytes):
    print(bytes)
    bytes_hex = []
    for byte in bytes:
        bytes_hex.append(format(byte, '#04X'))
    print(bytes_hex)

def LedDeviceAtmoOrb_write(ColorRgb):
    # If not in multicast group return
    if (not joinedMulticastgroup):
        return 0

    # Command options:
    #
    # 1 = force off
    # 2 = use lamp smoothing and validate by Orb ID
    # 4 = validate by Orb ID

    # When setting useOrbSmoothing = true it's recommended to disable Hyperion's own smoothing as it will conflict (double smoothing)
    commandType = 0x04
    if(useOrbSmoothing):
        commandType = 0x02

    # Iterate through colors and set Orb color
    # Start off with idx 1 as 0 is reserved for controlling all orbs at once
    idx = 1;

    for orbid in orbIds:
        # Retrieve last send colors
        #lastRed = lastColorRedMap[idx];
        #lastGreen = lastColorGreenMap[idx];
        #lastBlue = lastColorBlueMap[idx];
        lastRed = 0
        lastGreen = 0
        lastBlue = 0

        # put together the list of colors needed for that particular orbID
        start_idx = (idx-1)*NumLeds
        end_idx = idx*NumLeds
        ledValues = ColorRgb[start_idx:end_idx]

        # If color difference is higher than skipSmoothingDiff than we skip Orb smoothing (if enabled) and send it right away
        if ((skipSmoothingDiff != 0 and useOrbSmoothing) and (abs(color['red'] - lastRed) >= skipSmoothingDiff or abs(color['blue'] - lastBlue) >= skipSmoothingDiff or abs(color['green'] - lastGreen) >= skipSmoothingDiff)):
            # Skip Orb smoothing when using  (command type 4)
            for orbid in orbIds:
                if (orbid == idx):
                    LedDeviceAtmoOrb_setColor(orbid, ledValues, 0x04)
        else:
            # Send color
            for orbid in orbIds:
                if (orbid == idx):
                    LedDeviceAtmoOrb_setColor(orbid, ledValues, commandType)

        # Store last colors send for light id
        #lastColorRedMap[idx] = color['red']
        #lastColorGreenMap[idx] = color['green']
        #lastColorBlueMap[idx] = color['blue']

        # Next light id.
        idx = idx + 1
    return 0;

def LedDeviceAtmoOrb_setColor(orbId, ColorRgb, commandType):
    ledLength = len(ColorRgb)

    bytes = []
    for i in range(0, 5 + ledLength*3):
        bytes.append(0x00)    # construct the original list of rgb colors.

    #Command identifier: C0FFEE
    bytes[0] = 0xC0
    bytes[1] = 0xFF
    bytes[2] = 0xEE

    #Command type
    bytes[3] = commandType

    #Orb ID
    bytes[4] = orbId

    # RED / GREEN / BLUE
    for i in range(0, ledLength):
        bytes[5+i*3] = ColorRgb[i]['red']
        bytes[6+i*3] = ColorRgb[i]['green']
        bytes[7+i*3] = ColorRgb[i]['blue']

    sendCommand(bytes)

#configuration
NumLeds = 3
orbIds = [1,2]
ColorRgb = [{'red':255,'green':1,'blue':1},{'red':255,'green':2,'blue':2},{'red':255,'green':3,'blue':3},{'red':255,'green':4,'blue':4},{'red':255,'green':5,'blue':5},{'red':255,'green':6,'blue':6}]
useOrbSmoothing = 0
skipSmoothingDiff = 0

#call function
joinedMulticastgroup = 1
LedDeviceAtmoOrb_write(ColorRgb)

If you run this in Python 3.7.1 you get the output:
[192, 255, 238, 4, 1, 255, 1, 1, 255, 2, 2, 255, 3, 3]
['0XC0', '0XFF', '0XEE', '0X04', '0X01', '0XFF', '0X01', '0X01', '0XFF', '0X02', '0X02', '0XFF', '0X03', '0X03']
[192, 255, 238, 4, 2, 255, 4, 4, 255, 5, 5, 255, 6, 6]
['0XC0', '0XFF', '0XEE', '0X04', '0X02', '0XFF', '0X04', '0X04', '0XFF', '0X05', '0X05', '0XFF', '0X06', '0X06']

Thanks, taking a look now.

@RickDB did my script make sence to you?

Yeah, work got in the way this weekend but will get something together early next week :)

@RickDB did you already have time to take a look at my python code?

@RickDB Could you see if you can convert my python code to C++ in order to fix the AtmoOrb numLeds?


upload-blobs does nothing

$ tree blobs
blobs
├── golang
│   └── go1.8.linux-amd64.tar.gz
└── jq
    └── jq-linux64-1.5 -> /Users/drnic/Projects/bosh_releases/etcd-cf-service-broker-boshrelease/.blobs/d8e36831c3c94bb58be34dd544f44a6c6cb88568

When I run upload-blobs it drops out quickly with Succeeded but didn't do anything.
$ bosh2 upload-blobs
Succeeded
$ tree blobs
blobs
├── golang
│   └── go1.8.linux-amd64.tar.gz
└── jq
    └── jq-linux64-1.5 -> /Users/drnic/Projects/bosh_releases/etcd-cf-service-broker-boshrelease/.blobs/d8e36831c3c94bb58be34dd544f44a6c6cb88568

But bosh upload blobs works as expected (well, I'm actually getting a Aws::S3::MultipartUploadError error on the 80M golang tarball; which is why I tried bosh2 upload-blobs)

@drnic bosh upload-blobs does not work with old style blobs directory that uses symlinks. it expects that all files in there are actual files and not symlinks. you can run bosh reset-release (equivalent to rm -rf blobs), then add necessary blob files via bosh add-blob and finally run bosh upload-blobs (or see bosh blobs).

To clarify: if I use bosh2 add-blobs then my release is no longer supported by bosh1 release commands?
On Mon, Feb 27, 2017 at 10:33 AM +1000, "Dmitriy Kalinin"<EMAIL_ADDRESS>wrote:
@drnic bosh upload-blobs does not work with old style blobs directory that uses symlinks. it expects that all files in there are actual files and not symlinks. you can run bosh reset-release (equivalent to rm -rf blobs), then add necessary blob files via bosh add-blob and finally run bosh upload-blobs (or see bosh blobs).
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

its supported, you just cant use both clis pointed at the same local release directory.
Sent from my iPhone

On Feb 26, 2017, at 4:37 PM, Dr Nic Williams<EMAIL_ADDRESS>wrote:
To clarify: if I use bosh2 add-blobs then my release is no longer supported by bosh1 release commands?
On Mon, Feb 27, 2017 at 10:33 AM +1000, "Dmitriy Kalinin"<EMAIL_ADDRESS>wrote:
@drnic bosh upload-blobs does not work with old style blobs directory that uses symlinks. it expects that all files in there are actual files and not symlinks. you can run bosh reset-release (equivalent to rm -rf blobs), then add necessary blob files via bosh add-blob and finally run bosh upload-blobs (or see bosh blobs).
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.

Closing - use bosh reset-release when switching between go/ruby cli.

Related to #145


Some problem with mujoco data downloading

Hello!
It's really an exciting work and we really appreciate your released codes ! But we found some errors when we tried to download the mujoco training data you provided. Maybe something wrong with the authentication and vertification codes of gdrive api but we still cannot solve it after a few days' trying. If it is convenient for you, could you provide the direct link for us please to download the data via google drive instead of gdrive which occurs some bugs for us?
We really appreciate your time and help! Best wishes!

This should be an easy fix. I'll take a look this weekend!

In the meantime, here is the link to the drive: https://drive.google.com/drive/folders/1Vdf8rjPXabfMaCouNfqUYf0ifDW3qAU2?usp=sharing

It's really helpful! Thanks for your time and help!


Doom info stopped working

What did you expect to happen?
doom/info works.
What actually happened?
Error:
Debugger entered--Lisp error: (wrong-number-of-arguments ((t) nil "Collects some debug information about your Emacs s..." (interactive "P") (save-current-buffer (set-buffer (pop-to-buffer "*doom info*")) (setq buffer-read-only t) (let* ((modified (buffer-modified-p)) (buffer-undo-list t) (inhibit-read-only t) (inhibit-modification-hooks t)) (unwind-protect (progn (erase-buffer) (save-excursion (let ... ...))) (if modified nil (restore-buffer-modified-p nil)))) (kill-new (buffer-string)) (if (y-or-n-p "Your doom-info was copied to the clipboard.\n\nOpen ...") (progn (browse-url "https://pastebin.com"))))) 1)

Describe your attempts to resolve the issue
The error was introduced by this commit:
https://github.com/hlissner/doom-emacs/commit/dcae7187b4e3d67e10d7955dc6eb4577c3d6e285
Steps to reproduce

Open Emacs.
doom/info.

System Information
I cannot do that :).

System Information

I cannot do that :).

10/10

My bad! This issue should now be resolved. Let me know if that isn't the case and I'll reopen it. Thanks for bringing it to my attention!


Display author of the changes in the Workflow tab

Is your feature request related to a problem? Please describe.
Say you're working on the same file as a team mate of yours. You both have pending changes on that file. Both changes appear under the Workflow.
How do you know which one is yours?
You would need to click and search for your changes to make sure.
Describe the solution you'd like
A small line like {avatar} {name} or really just {name} below the collection name inside the change card would do just fine.
Describe alternatives you've considered
None
Additional context
A quick mockup:

Hi! i would like to work on this issue

I would need some help, as i am new here, Please guide me for what needs to be be done and where. This will make it easier for me to contribute next  time😄

Hi @himanshu007-creator, thank you for looking into this.
The code for rendering the workflow card is here:
https://github.com/netlify/netlify-cms/blob/444f30689b366f2479a0039414a314a809b2b980/packages/netlify-cms-core/src/components/Workflow/WorkflowCard.js
You'll need to propagate that information from each backend, for example from here:
https://github.com/netlify/netlify-cms/blob/444f30689b366f2479a0039414a314a809b2b980/packages/netlify-cms-backend-github/src/API.ts#L583
Also see https://github.com/netlify/netlify-cms/blob/master/CONTRIBUTING.md

hi @erezrokah! sorry i was on vacations. I am unable to understand the changes. Can you pinpoitn the chanegs needed.
P.S ( i will be better prepared for next time)

Hi @himanshu007-creator, the end result should be adding the post author in workflow tab:

to each post as seen in the issue description.
The UI code to change is here https://github.com/netlify/netlify-cms/blob/444f30689b366f2479a0039414a314a809b2b980/packages/netlify-cms-core/src/components/Workflow/WorkflowCard.js#L136
but you'll need to get that information from each backend as I mentioned in my previous comment.

Hello @erezrokah I would like to work on this feature please! Post author here refers to the author of the PR right? So for the GitHub backend for exampIe, I would need to propagate the value of pullRequest.user.login I guess? Please correct me if I am mistaken.

Thanks @pr0grammm! I think you're correct with all you questions/answers

Thanks, please check out the PR 🙂


Use custom hover for activity bar tooltip

I think one of the areas that could benefit from quicker tooltips/custom hovers is the activity bar as it is a frequently used area and the native tooltip takes too long to load. We've seen this in user studies where new users are not sure what these items are and don't click on them.
cc @bpasero @alexr00

Love the direction. I could not if browser tooltips had UX revisions; and most web-based apps I use replaced tooltips with custom tooltips to make them feel well integrated.
It should probably hook into the theming colors; which I think your mockup considers. The result will
To make it feel snappier, a common pattern that can be found in the wild is to not fade the tooltip in/out when moving between buttons that are aligned next to each other (horizontal & vertical). Figma as an example:

Since they will be HTML, it's an opportunity to think about a multi-line layout that breaks out the shortcut on a new line and maybe even leaves room for an additional one-liner that explains the feature.

Right, I think we've discussed this approach as Chrome does this on tabs as well, the first tooltip fades in and then as you move around the rest are instantly shown. I think @alexr00 looked into this?

This was a more agreed upon idea when last brought up at a UX sync, instead of having labels under activity bar icons: https://github.com/microsoft/vscode/issues/104452#issuecomment-677451408

The first tooltip fades in and then as you move around the rest are instantly shown.

Right, Chrome tab hover cards even transitioning from one to the next tab.

There are some animation best practices out there about this, but not sure if this one is too distracting, delightful, or actually a cognitive benefit. I personally am a fan of delightful animations that encourage exploration and don't get in the way of productivity.

Right, I think we've discussed this approach as Chrome does this on tabs as well, the first tooltip fades in and then as you move around the rest are instantly shown.

Isn't that pretty much standard hover behaviour even with native ones? When the hover appears and I move my mouse to another location with a hover, the hover should appear instantly and not require another delay. The delay is only useful to not bring up the hover too quickly when the user moves the mouse.

@bpasero yes that is standard native behavior but our custom hover does not behave this way.

@sandy081 thoughts on moving this to April?

I am ready to help run this as experiment to learn how improving UI affordance enhances the experience for new users.

Sure, will look at this in April.

Created the PR implementing this

@sandy081 not sure if you're using it already, but there is a setting for the hover delay that should probably be used for the hovers you are changing workbench.hover.delay.

I think the quick hover was intentional here.
I love the activity bar but not so much the panel ones as it's mostly repeating information and getting in the way.

@alexr00 Thanks for mentioning about it. I have seen its usage but went without using it for quick hover as @Tyriar mentioned.
Re using hover delay in panel, went with consistency in activity bar and panels.

Thoughts on using this to potentially rename the gear icon from "Manage" to "Settings" or "Preferences"? This is generally more common in apps like Edge, Slack, and Chrome as well.

There is an ask to make this as an experiment and check and measure if this improves the experience. Any thoughts about making this default or change it to an experiment before making it default?

Since we saw many users in the getting started user studies often hovering icons and clicking through menus, I think it could be useful to roll this out as an experiment to measure how much more engagement with the activity bar we see, and if it improves the new user experience specifically.

Re using hover delay in panel, went with consistency in activity bar and panels.

Imo we should consistently show the hover near instantly for textless actions, and consistently use the workbench delay for actions with text.

+1 on only showing the hover on a delay that is configurable.

Imo we should consistently show the hover near instantly for textless actions, and consistently use the workbench delay for actions with text.

I mostly agree though I might make an exception for the panel headers because of the shortcut key visibility.
Makes me also want this for all actionbar icons too.

Here is how it behaves when uses default workbench hover delay

I prefer instant hover than this. Let me know others opinions and I can change accordingly.
Also please let me know if you want custom hovers as default or behind the experiment?

I like the instant hover.

Reopening it for discussion as it seems some of us does not like it

For me there are two problems with the custom hover

it shows to quickly
it always shows at the same position, doesn't respect my relative mouse position and that makes it very alien

From https://github.com/microsoft/vscode/issues/121354:

it should not use the custom hover unless there is a good reason (e.g. do we show markdown in there?)
it should have a configurable color so that I have a way to disable it if I don't like it

The native hover seems to work well so far:

I really like the new hovers, though I would recommend a very short delay -- just to avoid them showing up while the mouse is moving, but still very quickly. Similar to Slack's workspace bar.
I also really like that those hover go along with the theme now. Are we using a new theme color for the hover feedback? As I would like to theme that to look better.

Also it would be great if we could render the shortcut keys better now, again maybe similar to Slack's

It seems like there is some unwanted flicker on the activity bar

it shows to quickly

Will introduce or reuse the delay setting.

it always shows at the same position, doesn't respect my relative mouse position, and that makes it very alien

Right. We can make them position like native hovers. Personally I liked how it is currently and is also suggested as req. I will collect more feedback before getting to this.

it should not use the custom hover unless there is a good reason

Reason is mentioned in the summary of the issue - just mentioning it again here
I think one of the areas that could benefit from quicker tooltips/custom hovers is the activity bar as it is a frequently used area and the native tooltip takes too long to load. We've seen this in user studies where new users are not sure what these items are and don't click on them.

it should have a configurable color so that I have a way to disable it if I don't like it

I do not know if hovers can be theme-able - @Tyriar ?

Also it would be great if we could render the shortcut keys better now, again maybe similar to Slack's

Right. We can make them position like native hovers. Personally I liked how it is currently and is also suggested as req. I will collect more feedback before getting to this.

Now that someone has mentioned slack: I think they do better job because their "button-hover" is so different from the native hover that you don't get the confused feeling that the "native, not-native hover" is wrong.

Introduced slight delay for showing custom hovers on activity bar/panel.

Trying this out after being gone for a week, I definitely like the hover feedback. However, it seems like there are a few things that could be improved for all hovers and not specific to the activity bar:

The hover text is really large, especially when there's extra text in the title

It can be hard to tell where the hover is coming from when there is no "arrow" that is common in tooltips like

Since this hover is inheriting the default styles from the editor hover, I'd like to propose a different styling for non-editor hovers (we can also move this feedback into a separate issue):

A similar "flicker" also happens in the explorer.

Now that someone has mentioned slack: I think they do better job because their "button-hover" is so different from the native hover that you don't get the confused feeling that the "native, not-native hover" is wrong.

I do not know if hovers can be theme-able

Not yet, though I think we should have 2 different styles, maybe with a little arrow and/or the fade in animation to differentiate it. Then center the hover and for the panel put them on the top like this:

As requested by @digitarald and @sana-ajani I moved custom hovers behind an experimental flag. So they are off by default and you can enable it using the setting workbench.experimental.useCustomHover.
I liked the suggestions provided by @misolori  and @Tyriar - will try to implement that in this milestone.

@sandy081 the animation in https://github.com/microsoft/vscode/issues/118077#issuecomment-790194019 (which also applies to native tooltips) does not fade in and out while hovering between aligned buttons:

Would it be possible to not drop this affordance with custom tooltips, as we see a lot of users hovering across toolbars to quickly scan for specific features?

@sandy081 I have noticed this blue line in the left when mouse down only in file icon and this doesn't shows in the other icons. (0310f02)

@pixieaka  Can you please file a separate issue for it?

@pixieaka posting here as well, but the blue line is the focus state in the activity bar. If you tab into the activity bar you'll see the same thing so this by design.

Did some improvements based on received feedback

Closing this issue and will track any feedback in separate issues.


Country Capital Webpage

🛠 Fixes Issue #622

👨💻 Changes proposed

I have added the Country Capital Webpage
✅ Check List (Check all the applicable boxes)

[x] My code doesn't break any part of the project (Zero Octave-Javascript-Projects).
[x] This PR does not contain plagiarized content.
[x] My Addition/Changes works properly and matches the overall repo pattern.
[x] The title of my pull request is a short description of the requested changes.

📄 Note to reviewers

I am a GSSoC'22 contributor. Please review this PR. @Astrodevil
Screenshots

Videos
https://user-images.githubusercontent.com/93239528/165343232-0341c3ca-9c90-40ae-ab35-51099701fce0.mp4

Please add files in respective folders. Don't create one.

Please add files in respective folders. Don't create one.

I have made the required changes. Please review.

Also add your project in cards.json in alphabetical order and README after updating fork.

Also add your project in cards.json in alphabetical order and README after updating fork.

I have made the required changes. Please review.


Lack of semi colon creates problems when transpiling

We are using stylis as a part of styled-components in a react-library. However, when we package our library the transpiler (babel 6.26.0, ES5) screws up the regex because for some reason the lack of semicolon and missing /g at the end of some regular expressions means that some lines are concatenated, so for instance instead of
var cursorptn = /zoo|gra/
var transformptn = /([,: ])(transform)/g

The regex looks like this:
var cursorptn = /zoo|gra/var transformptn = /([,: ])(transform)/g

Which then creates an error in our application that uses our packaged library.
Using semicolon for instance makes this problem go away.

it seems like when using styled-components, their shipped code isn´t used, but instead stylus´ code is used, we will ask them how come.


Question about --dpo_ftx Parameter Setting

Reminder

[X] I have read the README and searched the existing issues.

Reproduction
The --dpo_ftx parameter introduces sftloss. Based on experience, what would be a good setting for --dpo_ftx? Should it generally scale sftloss to a level similar in magnitude to dpoloss, or is there a specific fixed --dpo_ftx setting that consistently yields good results?
Expected behavior
No response
System Info
No response
Others
No response

We do not have optimal values, try dpo_ftx from 0.1 to 10


Ruby 2.4.4 Alpine 3.7 missing file error

What version of gRPC and what language are you using?
grpc (1.12.0)
ruby 2.4.4
What operating system (Linux, Windows, …) and version?
alpine 3.7
What runtime / compiler are you using (e.g. python version or version of gcc)
In dockerfile we RUN apk --update ... add ... gcc ...
(full dockerfile below)
What did you do?
Spinning up a kubernetes cluster and the rails app within a pod is crashing on startup:
/usr/local/bundle/gems/grpc-1.12.0-x86_64-linux/src/ruby/lib/grpc/grpc.rb:20:in `require_relative': Error loading shared library ld-linux-x86-64.so.2: No such file or directory (needed by /usr/local/bundle/gems/grpc-1.12.0-x86_64-linux/src/ruby/lib/grpc/2.4/grpc_c.so) - /usr/local/bundle/gems/grpc-1.12.0-x86_64-linux/src/ruby/lib/grpc/2.4/grpc_c.so (LoadError)
from /usr/local/bundle/gems/grpc-1.12.0-x86_64-linux/src/ruby/lib/grpc/grpc.rb:20:in `<top (required)>'
from /usr/local/bundle/gems/grpc-1.12.0-x86_64-linux/src/ruby/lib/grpc/errors.rb:15:in `require_relative'
from /usr/local/bundle/gems/grpc-1.12.0-x86_64-linux/src/ruby/lib/grpc/errors.rb:15:in `<top (required)>'
from /usr/local/bundle/gems/grpc-1.12.0-x86_64-linux/src/ruby/lib/grpc.rb:17:in `require_relative'

There was an old fix I found on google that said to add the libc6-compat to the dockerfile, that ended up throwing a seg fault for protobuff:
/usr/local/bundle/gems/google-protobuf-<IP_ADDRESS>-x86_64-linux/lib/google/protobuf/any_pb.rb:15: [BUG] Segmentation fault at 0x0000000000016e16
ruby 2.4.4p296 (2018-03-28 revision 63013) [x86_64-linux-musl]
c:0137 p:---- s:0671 e:000670 CFUNC :msgclass
c:0136 p:0026 s:0667 e:000666 CLASS /usr/local/bundle/gems/google-protobuf-<IP_ADDRESS>-x86_64-linux/lib/google/protobuf/any_pb.rb:15
c:0136 p:0026 s:0667 e:000666 CLASS /usr/local/bundle/gems/google-protobuf-<IP_ADDRESS>-x86_64-linux/lib/google/protobuf/any_pb.rb:14
c:0134 p:0039 s:0661 E:001800 TOP /usr/local/bundle/gems/google-protobuf-<IP_ADDRESS>-x86_64-linux/lib/google/protobuf/any_pb.rb:13 [FINISH]
c:0133 p:---- s:0658 e:000657 CFUNC :require
c:0132 p:0012 s:0653 e:000652 BLOCK /usr/local/bundle/gems/activesupport-5.0.7/lib/active_support/dependencies.rb:293

What did you expect to see?
No errors
What did you see instead?
See above
Anything else we should know about your project / environment?
GRPC is a requirement of google-cloud-pubsub (0.30.2).  As well as a whole bunch of other similar sounding gems.  I assume the issue is in the Alpine build but Im not sure what else to install/try.  We have google-cloud-pubsub working with the same app in production environments on a cloud ubuntu VM and we have the app working in production in a kubernetes cluster with the google-cloud-pubsub gem installed but not called.  Im a lot out of my league with this stuff, any help is appreciated!
Here is the full dockerfile:
FROM ruby:2.4.4-alpine3.7

ENV RAILS_ROOT /rails/prism
ENV PAGER=/usr/bin/less
RUN mkdir -p $RAILS_ROOT/tmp/pids
WORKDIR $RAILS_ROOT
ADD Gemfile* ./

RUN apk --update --no-cache add bash mysql-dev mysql-client nodejs libxslt-dev libxml2-dev gcc g++ libcurl curl-dev pdftk poppler-utils
RUN apk --update add --virtual build-dependencies build-base build-dependencies gcc git less \
    && bundle install --jobs `expr $(cat /proc/cpuinfo | grep -c "cpu cores") - 1` --retry 3 --without test development\
    && apk del build-dependencies

COPY . $RAILS_ROOT

EXPOSE 3000

CMD ["bin/rails", "server", "-b", "<IP_ADDRESS>"]

This one seems to be on protobuf, not grpc.
@haberman ?

Same as #4460


Drawer doesn't open after fast double click. Primarily because the drawer and its state are out of sync

###Project
https://github.com/jainniket/drawer-issue

Current Behavior
There is a Hamburger Menu on whose click DrawerOpen action is triggered.
But when, that menu is tapped twice very fast, the drawer opens and closes back, but the state is still set as Open.
So the error is, once the menu is clicked, it opens the drawer, but in the transition phase, when the drawer is opening, another tap happens which eventually happens to be on the View being presented by Drawer. This tap forces the menu to close back but the action DrawerClose doesn't get registered.
Whereas the redux state says the current route as DrawerOpen even though the drawer is clossed. So any further taps on the menu icon becomes un-responsive.
Reason - The drawer presented and drawer state are out of sync.
Expected Behavior
The double tap should be disabled.
The presenting view of drawer shouldn't take any touch event.
Your Environment

software
version

react-navigation
^1.0.0-beta.11

react-native
0.45.1

node
v7.6.0

npm or yarn
v4.1.2

Agreed!
The button becomes unresponsive upon double tapping and won't work till the drawer is pulled from the edge of the screen. This makes up to a very bad user experience!

@d3fkon exactly.. and this is specifically there on Android. unable to think of any hack to resolve this temporarily.

I think that if we handle the double tap with what's in here,
https://gist.github.com/mrzmyr/9ac94ca4622c1602a2a3 we can work it out
On 4 Jul 2017 3:13 p.m., "Niket Jain"<EMAIL_ADDRESS>wrote:

@d3fkon https://github.com/d3fkon exactly.. and this is specifically
there on Android. unable to think of any hack to resolve this temporarily.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/react-community/react-navigation/issues/1960#issuecomment-312833976,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AV8P1ht1s2S7-5FMuLTePEY7d5xnvIuqks5sKglMgaJpZM4OB-GT
.

@d3fkon so this was my first step towards fixing this issue.
unfortunately, the double tap action isn't captured by the button but rather the presenting view of the drawer on which i have no control!!

I'll check it out and report back what happens
On 5 Jul 2017 4:44 p.m., "Niket Jain"<EMAIL_ADDRESS>wrote:

@d3fkon https://github.com/d3fkon so this was my first step towards
fixing this issue.
unfortunately, the double tap action isn't captured by the button but
rather the presenting view of the drawer on which i have no control!!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/react-community/react-navigation/issues/1960#issuecomment-313074035,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AV8P1rYQapRoNm5TZHOwk-Z5pqqVD4Nsks5sK3AhgaJpZM4OB-GT
.

Okay. I  think I found a solution. Borrowing the idea from this, I could write my Navbar to handle double taps for drawer events.
        lastLeftPress: 0,
    };

    DOUBLE_TAP_DURATION = 500;

    _handleLeftClick = (action, resetAction) => {
        const currentTime = parseInt(new Date().getTime());
        let duration = currentTime - parseInt(this.state.lastLeftPress);
        console.log(duration);
        this.setState({lastLeftPress: currentTime});
        if (parseInt(duration) <= this.DOUBLE_TAP_DURATION) {
            //Handle Double Tap
            console.log("Double");
            return resetAction? resetAction(): false;
        } else {
            //Handle Single Tap
            console.log("Single");
            return action();
        }
    };

As my NavBar is a separate component, I'm passing

navigation.navigate('DrawerOpen') as the `action' param
navigation.navigate('DrawerClose') as the resetAction param
to the event handling function.
According to the very simple logic here, If the user double taps,
The drawer will open as a result of the first tap.
And if a double tap is recognized, the drawer will close, thus syncing the state of navigation.

I feel like 500 ms is quite good with the limited testing I could do. Feel free to report back lesser values which seem to work more effectively too.
I'm not sure how reliable this solution is, but it sure as hell is better than not having a solution

@d3fkon thank you for the help.
unfortunately that doesn't work. It is because the double tap action isn't captured by the button but the presenting view of the drawer by DrawerNavigation.
I've updated the sample project for this issue with the above mentioned suggestion.
https://github.com/jainniket/drawer-issue

I'm not quite sure about what you implemented there. I did not see my solution in your code,
However, I have made a pull request to your repo with the fix. Do check it out.
I strongly suggest you close the issue and also rename it to something more concise so that people who actually face this issue can come across with the solution more easily.

@d3fkon My bad.. My code didn't get pushed..
Here's a PR
https://github.com/jainniket/drawer-issue/pull/2
Moreover i just checked your PR. The issue isn't resolved in that.
When you double tap on the button very fast as shown in the gif, the drawer doesn't open after that.

This fast-click is a separate issue. But this one which i've reported is definitely a different one.
This has something to do with the presented view of drawer and not the button being clicked.

We just merged a PR that adds a DrawerToggle option so you don't have to track the state of the drawer yourself. Will that fix this issue?

Pinging OP @jainniket since this issue has not been active for a while, and it's related to an old version of the lib.
Please let me know if you want this to remain open; if I get no answer in the next 7 days I will close it.

I have same issue..

Hi there @jainniket,
In an effort to cleanup this project and prioritize a bit, since this issue had no follow up since my last comment I'm going to close it.
@axsann if you are still having the issue with the latest version please open a new one that uses the new Issue Template to provide some more details to help us solve it.

This is still an issue, I've upgraded to the latest. Using key flag fixes it, but it breaks if you do it really fast :(

I was able to fix it with:
props.navigation.navigate('DrawerClose'); setTimeout(() => props.navigation.navigate('DrawerOpen') ), 0}
when calling onPress to open the menu

should be resolved on master


Add support for multiple licence files

Codecov Report

Merging #351 (f8c3744) into main (9c3242e) will increase coverage by 0.40%.
The diff coverage is 92.93%.

@@            Coverage Diff             @@
##             main     #351      +/-   ##
==========================================
+ Coverage   91.30%   91.71%   +0.40%
==========================================
  Files          17       16       -1
  Lines        1576     1557      -19
==========================================
- Hits         1439     1428      -11
+ Misses        137      129       -8

Flag
Coverage Δ

unittests
91.71% <92.93%> (+0.40%)
:arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

setup.py
0.00% <0.00%> (ø)

grayskull/license/discovery.py
94.84% <76.66%> (-2.30%)
:arrow_down:

grayskull/strategy/abstract_strategy.py
83.33% <83.33%> (ø)

grayskull/utils.py
91.01% <88.18%> (-8.99%)
:arrow_down:

grayskull/__main__.py
95.34% <92.30%> (-2.80%)
:arrow_down:

grayskull/base/factory.py
91.17% <93.33%> (+1.17%)
:arrow_up:

grayskull/base/github.py
93.44% <93.44%> (ø)

grayskull/strategy/py_base.py
95.40% <95.40%> (ø)

grayskull/config.py
96.72% <96.72%> (ø)

grayskull/strategy/pypi.py
98.00% <98.00%> (ø)

... and 7 more


Cordova 7 compatibility

Hi everyone,
Please update the plugin.xml for cordova 7 compatibility
<!-- An existing config.xml -->
<edit-config file="AndroidManifest.xml" target="/manifest/application" mode="merge">
<!-- needs to change to -->
<edit-config file="app/src/main/AndroidManifest.xml" target="/manifest/application" mode="merge">
source : https://cordova.apache.org/announcements/2017/12/04/cordova-android-7.0.0.html
Thanks in advance

You can use Cordova's camera plugin for an image picker by choosing the phone's gallery as a source type.

I think also another think must be taken care of here:
Saved plugin info for "cordova-plugin-telerik-imagepicker" to config.xml cp: copyFileSync: could not write to dest file (code=ENOENT):<project directory>\platforms\android\res\xml\config.xml
when building app using ionic/cordova for android, res/xml folder does not exists at all, so as config.xml file there.