forms – What is the best practise for a Search button state – should we always keep search button active or make it active after user inputs?

If a user can start search without any text input, they need to receive some meaningful results. It can actually be a feature: maybe your user doesn’t know what to type in, but you think you have something to offer them anyway. Show them your hot offers, suggest something based on your knowledge about user.

There was a conception of “zen search” when you don’t type anything, but get some random results after clicking [Search].

This is not a direct answer to your question, but maybe it can solve your problem. Your button can be always available and always working. No need to disable it. Just show people something good.

sound – Ubuntu 19.10 Intel Microphone Array Stuck in Suspended State

Fair warning this is a bit of a repost of another post I made a while back on some other account. I forgot about the question but with COVID-19 and working from home. The microphone itself works in Windows 10 (the OS my computer came shipped with); however, I don’t like working on Windows.

I had some suspicions that maybe Lenovo Vantage on Windows had some firmware settings to just disable the microphone persistently across reboots (that was the case for my camera); however, I disabled that and if it were disabled I wouldn’t be able to access it on Windows, so I’m lost there.

pavucontrol shows the microphone as being “unplugged” even though it’s internal.

Here’s a screenshot

The mic itself is not muted in ALSA.

Here’s another screenshot

pactl list sources shows the following output

Source #9
    State: SUSPENDED
    Name: alsa_input.pci-0000_00_1f.3.analog-stereo
    Description: Built-in Audio Analog Stereo
    Driver: module-alsa-card.c
    Sample Specification: s16le 2ch 44100Hz
    Channel Map: front-left,front-right
    Owner Module: 8
    Mute: no
    Volume: front-left: 65536 / 100% / 0.00 dB,   front-right: 65536 / 100% / 0.00 dB
            balance 0.00
    Base Volume: 6554 /  10% / -60.00 dB
    Monitor of Sink: n/a
    Latency: 0 usec, configured 0 usec
    Flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY 
    Properties:
        alsa.resolution_bits = "16"
        device.api = "alsa"
        device.class = "sound"
        alsa.class = "generic"
        alsa.subclass = "generic-mix"
        alsa.name = "ALC298 Analog"
        alsa.id = "ALC298 Analog"
        alsa.subdevice = "0"
        alsa.subdevice_name = "subdevice #0"
        alsa.device = "0"
        alsa.card = "0"
        alsa.card_name = "HDA Intel PCH"
        alsa.long_card_name = "HDA Intel PCH at 0x2ffb018000 irq 151"
        alsa.driver_name = "snd_hda_intel"
        device.bus_path = "pci-0000:00:1f.3"
        sysfs.path = "/devices/pci0000:00/0000:00:1f.3/sound/card0"
        device.bus = "pci"
        device.vendor.id = "8086"
        device.vendor.name = "Intel Corporation"
        device.product.id = "9d71"
        device.product.name = "Sunrise Point-LP HD Audio"
        device.form_factor = "internal"
        device.string = "front:0"
        device.buffering.buffer_size = "65536"
        device.buffering.fragment_size = "32768"
        device.access_mode = "mmap+timer"
        device.profile.name = "analog-stereo"
        device.profile.description = "Analog Stereo"
        device.description = "Built-in Audio Analog Stereo"
        alsa.mixer_name = "Realtek ALC298"
        alsa.components = "HDA:10ec0298,17aa3812,00100103 HDA:8086280b,80860101,00100000"
        module-udev-detect.discovered = "1"
        device.icon_name = "audio-card-pci"
    Ports:
        analog-input-mic: Microphone (priority: 8700, not available)
    Active Port: analog-input-mic
    Formats:
        pcm

at.algebraic topology – What is the current state of research in Chern-Simons theory?

I’m a PhD student in mathematical physics looking for some orientation. As asked in the title, I would like to know the current state of research in Chern-Simons theory. More specifically, what are some of the directions that people are currently pursuing in this field.

I did not ask for more general topological field theories, but this is largely due to personal interests. Of course, answers related to other TFTs are more than welcome.

I feel this question has been asked before. But since this is a question about the current state of research, I think it deserves an update.

Thank you very much.

formal languages – PDA with more than one initial state

PDAs that are allowed to have more than one initial state (let’s call them PDAIs) are computationally equivalent to conventional PDAs:

  • Trivially, every conventional PDA can be considered as a PDAI that happens to have one initial state.
  • Every PDAI can be converted to an equivalent PDA with the process you describe.

So yes, PDAIs accept exactly the context free languages.

malware – Why is the term “nation state” used to refer to a government-sponsored effort in infosec, and is it accurate?

I work in infosec and as such, have read many whitepapers and been to many conference talks. I hear all the time, especially in conversation and literature about malware, the term “nation state” used to refer to a government entity or government-sponsored activity. The term “state actor” is also used.

My question is, why? According to Wikipedia:

A nation state is a state in which a great majority shares the same culture and is conscious of it. The nation state is an ideal in which cultural boundaries match up with political boundaries.1 According to one definition, “a nation state is a sovereign state of which most of its subjects are united also by factors which defined a nation such as language or common descent.” It is a more precise concept than “country”, since a country does not need to have a predominant ethnic group.

According to Merriam-Webster, the definition is:

a form of political organization under which a relatively homogeneous people inhabits a sovereign state

Is there some inherent need for the government sponsor to be primarily of one ethnic background in infosec literature? I just don’t understand why this term in particular is so frequently used, when there are many forms of states, such as a federated state, multinational state, or even more general terms such as “government” or “country,” all of whom would likely be capable of and do participate in infosec activities.

reactjs – Using state in other components in React JS

I have three components.

export default class PermissionHandler extends React.Component {

    constructor(props) {
        super(props);
        this.state = {
            permission: true
        }
    }

}

export default class App extends React.Component {
    render() {
        return(
            <PermissionHandler />
            <Component1 />
        )     
    }
}

export default class Component1 extends React.Component {
    render() {
        return(
            <SomeComponent /* visible= true/false depends on permission */ />
        )     
    }
} 

I want PermissionHandler state to be used by any other components directly without using events or local state. Is it possible?

Can I use refs to achieve this goal?

export default class App extends React.Component {
    constructor(props) {
        super(props);
        this.permissionHandler = React.createRef();
    }

    render() {
        return(
            <PermissionHandler ref={this.permissionHandler} />
            <Component1 permissionHandler={this.permissionHandler}/>
            <Component2 permissionHandler={this.permissionHandler} />
        )     
    }
}

export default class Component1 extends React.Component {
    render() {
        return(
            <SomeComponent visible={this.props.permissionHandler.currenct.state.permission} />
        )     
    }
} 

But Component1 doesnt rerender when the state of PermissionHandler updates

unity – Animator State does not switch immediately through code, even tho all transitions have “Has Exit Time” checked off

first of all, this is my code, I’m prototyping a state machine using Unity Animator (First Time) and I’m stuck coding a simple burst of speed.

using UnityEngine;
using UnityEngine.AI;

(CreateAssetMenu(fileName = "Dash", menuName = "States/Dash"))
class Dash : State
{
    NavMeshAgent agent;
    (SerializeField) float Speed = 50;
    (SerializeField) float Distance = 1;
    float oldSpeed,counter, duration;



    public override void onStart(Animator animator, AnimatorStateInfo stateInfo)
    {
        agent = animator.GetComponent<NavMeshAgent>();
        duration = Distance / Speed;
        oldSpeed = agent.speed;
        agent.speed = Speed;
        counter = 0;
    }

    public override void onUpdate(Animator animator, AnimatorStateInfo stateInfo)
    {
        counter += Time.deltaTime;
        Debug.Log(counter + " of " + duration);
        if(counter > duration)
        {
            Debug.LogError("Dash is finished");
            agent.speed = oldSpeed;
            animator.SetBool("isDashing", false);
        }
    }

    public override void onExit(Animator animator, AnimatorStateInfo stateInfo)
    {

    }

}

The issue is that the player standstill for few second after dashing. So I’ve added some debug.log and this is the result.

enter image description here

As you can see, the state keeps updating even tho the timer has ran up. It even keeps updating after switching to “Idle” state, tho this ends at some point. I’ve made sure that all transitions have “Has Exit Time” checked off and the Interruption Source = “Current State”.

enter image description here

Note: this is just a prototype and the states have no animations still.

nodes – Schedule a current state of a content to be publish is not working

I’m having some issues with drupal/core 8.7.7, when i crate a new content or use a content already published , i want to schedule that content to be changed from one state to another. ex: enter image description here

But when i schedule that change to be made it doesn’t happen.
Does anyone have a idea how to fix that or another way to do that ?