this was marked as a duplicate of this issue, which has unfortunately been around since 2017
If you use the enhanced flow (GetCredentialsForIdentity) a scope down policy is applied to all guest identities which doesn't include Bedrock.
In order to allow guest identities to access Bedrock, you need to use the classic flow (GetOpenIdToken and STS AssumeRoleWithWebIdentity) that doesn't apply the scope down policy.
With that said, I would not recommend giving guest users access to Bedrock, bad actors can create any number of guests and run up your Bedrock bill.
Edge and Chrome may render font-weight differently due to their font engines. Use specific font weights (e.g., 400
, 700
) and test across browsers for consistency.
How To Use Black Apps Script — quick tip for global search.
It took me a second to figure out how to search across files after installing the extension. It’s not true global search in one view, but it gets the job done. Super handy once you know how to use it:
1. Press Ctrl + F while in the Apps Script IDE to open the legacy search bar (this is the normal/standard way)
2. Search for a term (e.g., "folder"). It will show results on the current file.
3. On the legacy search bar, click the magnifying glass just to the left of the search term box — this reveals a second row.
4. Use the left/right arrows on that second row to jump between files and continue the keyword search in each file.
{</>play hacker the blockman go / (% if request.path == '/contact/' %}
\<p\>You are in Contact\</p\>
{% elif request.path == '/shop/' %}
\<p\>You are in Shop\</p\>
{% endif %}go play .+
Google Cloud Source Repository doesn't seem to link the HEAD to a non-master default branch from the mirrored GitHub repo. I was working with ArgoCD and it does a ls-remote to HEAD branch for the testing before establishing the connection successfully.
I have cut out a master branch from my default branch and pushed in the origin and that solved my issue.
Just add the folowing
And Change the SD to SDFS. then it will work
#include "sdfs.h"
server.on("/getdata", HTTP_GET, [](AsyncWebServerRequest *request){
request->send(SDFS, "/subj1_1.txt", "text/plain");
});
A example you can find at the folowing location https://github.com/EmileSpecialProducts/portable-Async-disk-drive
from PIL import Image
import numpy as np
# Let's check the folder to see what files are available
import os
files = os.listdir("/mnt/data")
files
The command on the ubuntu website is for linux, not for windows.
This article explains the command (sha256)https://www.shellhacks.com/windows-md5-sha256-checksum-built-in-utility/
If the result matches with the part after "echo", your file should be ok.
I have create an issue 17513 for this request in Bicep repo, so I am marking this as complete for now.
But as @developer said in the comments, it could be possible via DevOps pipeline or something similar, but not fully as Bicep.
Here's a simple Python example of an interview bot for nursing scholarship preparation. It asks common questions and collects the user's answers:
def nursing_scholarship_interview():
print("Welcome to the Nursing Scholarship Interview Practice Bot!")
questions = [
"Tell me about yourself and why you want to pursue nursing.",
"What are your greatest strengths as a nursing student?",
"Describe a challenging situation and how you handled it.",
"Why do you deserve this scholarship?",
"Where do you see yourself in five years as a nurse?"
]
answers = {}
for q in questions:
print("\n" + q)
answer = input("Your answer: ")
answers[q] = answer
print("\nThank you for practicing! Here's a summary of your answers:")
for q, a in answers.items():
print(f"\nQ: {q}\nA: {a}")
if __name__ == "__main__":
nursing_scholarship_interview()
You can run this script in any Python environment. It simulates an interview by asking questions and letting the user type answers. Would you like me to help you expand it with features like timed answers or feedback?
# self_learning_ea_system.py
import spacy
import numpy as np
import networkx as nx
import pickle
import os
import json
from sklearn.model_selection import train_test_split
from sklearn.metrics import accuracy_score
from tensorflow import keras
from tensorflow.keras import layers
from sentence_transformers import SentenceTransformer
# --- 1. Knowledge Graph using triples + networkx
class KnowledgeGraph:
def __init__(self):
self.triples = [] # (s, r, o)
self.graph = nx.DiGraph()
def update(self, s, r, o):
if (s, r, o) not in self.triples:
self.triples.append((s, r, o))
self.graph.add_edge(s, o, label=r)
def query(self, s=None, r=None, o=None):
return [
(s0, r0, o0) for (s0, r0, o0) in self.triples
if (s is None or s0 == s) and (r is None or r0 == r) and (o is None or o0 == o)
]
def __str__(self):
return "\n".join([f"{s} -[{r}]-> {o}" for s, r, o in self.triples])
# --- 2. NLP extractor with spaCy
nlp = spacy.load("en_core_web_sm")
embedder = SentenceTransformer('all-MiniLM-L6-v2')
def extract_triples(text):
doc = nlp(text)
triples = []
for token in doc:
if token.dep_ == "ROOT":
subjects = [w for w in token.lefts if w.dep_ in ("nsubj", "nsubjpass")]
objects = [w for w in token.rights if w.dep_ in ("dobj", "attr", "prep", "pobj")]
for s in subjects:
for o in objects:
triples.append((s.text, token.lemma_, o.text))
if not triples:
parts = text.split()
for rel in ("is", "has", "part"):
if rel in parts:
i = parts.index(rel)
if i >= 1 and i < len(parts) - 1:
triples.append((parts[i - 1], rel, parts[i + 1]))
return triples
def triple_to_vec(s, r, o):
return embedder.encode(f"{s} {r} {o}")
# --- 3. Relation prediction model
def build_model(input_dim):
model = keras.Sequential([
layers.Dense(64, activation="relu", input_shape=(input_dim,)),
layers.Dense(32, activation="relu"),
layers.Dense(1, activation="sigmoid"),
])
model.compile(optimizer="adam", loss="binary_crossentropy")
return model
# --- 4. Evolutionary algorithm
class EvolutionaryAlgorithm:
def __init__(self, system, base_rate=0.02):
self.system = system
self.base_rate = base_rate
self.mutation_rate = base_rate
def update_mutation_rate(self, accuracy):
self.mutation_rate = max(0.005, self.base_rate * (1 - accuracy))
def evolve(self):
model = self.system["model"]
weights = model.get_weights()
mutated = [w + self.mutation_rate * np.random.randn(*w.shape) for w in weights]
model.set_weights(mutated)
print(f"🔁 Mutated model weights with rate {self.mutation_rate:.4f}.")
# --- 5. Learning Module
class LearningModule:
def __init__(self, kg, system):
self.kg = kg
self.system = system
self.training_data = []
def add_training_example(self, s, r, o, label):
self.training_data.append((s, r, o, label))
acc = self.train()
self.system["ea"].update_mutation_rate(acc)
def train(self, epochs=10, batch_size=16):
if not self.training_data:
print("No training data available.")
return 0.0
X, y = [], []
for s, r, o, label in self.training_data:
vec = triple_to_vec(s, r, o)
X.append(vec)
y.append(label)
X = np.vstack(X)
y = np.array(y)
X_train, X_val, y_train, y_val = train_test_split(X, y, test_size=0.2, random_state=42)
model = self.system["model"]
model.fit(X_train, y_train, epochs=epochs, batch_size=batch_size, verbose=0)
preds = (model.predict(X_val) > 0.5).astype(int).flatten()
acc = accuracy_score(y_val, preds)
print(f"🧪 Trained model — validation accuracy: {acc:.2f}")
return acc
# --- 6. Reasoning Engine
class ReasoningEngine:
def __init__(self, kg, system):
self.kg = kg
self.system = system
def reason(self, query):
doc = nlp(query)
for ent in doc.ents:
facts = self.kg.query(s=ent.text)
if facts:
return "Known: " + "; ".join(f"{s} {r} {o}" for s, r, o in facts)
s, r, o = self.extract_subject_relation_object(query)
if s and r and o:
prob = self.predict_relation(s, r, o)
if prob > 0.7:
return f"Predicted with confidence {prob:.2f}: {s} {r} {o}"
return "Unknown — please provide feedback to improve me!"
def extract_subject_relation_object(self, text):
parts = text.split()
if len(parts) >= 3:
return parts[0], parts[1], " ".join(parts[2:])
return None, None, None
def predict_relation(self, s, r, o):
vec = triple_to_vec(s, r, o)
prob = self.system["model"].predict(vec.reshape(1, -1))[0, 0]
return prob
# --- 7. Save/Load System State
def save_system(path="system_state.pkl"):
with open(path, "wb") as f:
pickle.dump({
"triples": SYSTEM["kg"].triples,
"training_data": SYSTEM["learner"].training_data,
"model_weights": SYSTEM["model"].get_weights(),
}, f)
def load_system(path="system_state.pkl"):
if os.path.exists(path):
with open(path, "rb") as f:
data = pickle.load(f)
for s, r, o in data["triples"]:
SYSTEM["kg"].update(s, r, o)
SYSTEM["learner"].training_data = data["training_data"]
SYSTEM["model"].set_weights(data["model_weights"])
print("✅ System state loaded.")
else:
print("⚠️ No saved system state found.")
# --- 8. Main EA system assembly
input_dim = 384
SYSTEM = {
"kg": KnowledgeGraph(),
"input_dim": input_dim,
"model": build_model(input_dim),
}
SYSTEM["ea"] = EvolutionaryAlgorithm(SYSTEM)
SYSTEM["learner"] = LearningModule(SYSTEM["kg"], SYSTEM)
SYSTEM["reasoner"] = ReasoningEngine(SYSTEM["kg"], SYSTEM)
# --- 9. User interaction
def interact(query):
resp = SYSTEM["reasoner"].reason(query)
print("🤖:", resp)
if resp.startswith("Unknown"):
feedback = input("✅ Please provide correct answer (S R O, pipe-separated): ")
try:
s, r, o = feedback.split("|")
SYSTEM["kg"].update(s.strip(), r.strip(), o.strip())
SYSTEM["learner"].add_training_example(s, r, o, label=1)
SYSTEM["ea"].evolve()
except ValueError:
print("⚠️ Invalid format. Skipping update.")
return resp
# --- 10. Command-line interface
def cli():
print("🤖 Welcome to the Evolving AI System. Type 'quit' to exit.")
while True:
q = input("\nAsk a question or type a command ('save', 'load'): ")
if q.lower() == "quit":
save_system()
print("🛑 Goodbye!")
break
elif q.lower() == "save":
save_system()
print("💾 System saved.")
elif q.lower() == "load":
load_system()
else:
interact(q)
# --- 11. Main
if __name__ == "__main__":
load_system()
cli()
replace with actual path of the extension or just comment it out should fix it.
extensions:
- '/path/to/sqlite-digest/digest.so'
Everything used to be done at the command line. "Windows busted out the crib." Out the box there are rules and conventions to which the Normal people must abide. Windows is very customizable. I can remember the computer command line was an amazing place where if you knew what to type you could make it do most anything. You can still write your own .com file from the CMD or create any file just type 'copy con testfile.txt' then type what you want then CTRL-Z and poof you made a file. There are so many programs running now on a pc that seems to be doing nothing but they are all like alligators laying around for something to step into the pool. Click a link on a web page and you might download install and run a base36 string of characters if your antivirus or settings do not protect you. When you power up a PC your no longer alone but subject to the will of anyone in the world who managed to contribute.
Just to fine tune @kerrek sb's very nice answer above, the equality comparison for it->first
should be using the collection's key_comp()
. It should probably be something more like !m.key_comp()(key, it->first)
. (given the other answers' guidance around using upper_bound
vs. lower_bound
, which comparison needs to be done should be tuned accordingly.)
You are asking 3 questions which makes answering difficult:
Question 1: Are these two VHDL processes synchronous?
Processes can't be synchronous, they are a construct of VHDL, only electrical signals can be synchronous.
Question 2: How should I create a slow clock derived from a (possibly much) faster clock without creating a gated clock, and while maintaining 50% duty cycle on slow_clk?
You should work with a clock enable signal: This means all flipflops should be connected to the same clock, in your case to the 12 MHz clock. The flipflops which must be clocked slower should be additional connected to a clock enable signal, which is active at each 12th clock edge of the 12 MHz clock (of course this solution has no signal with a 50% duty cycle).
Question 3: Do I create a new clock domain by using slow_clk_q in the sensitivity list of sm_proc, or are the two processes actually synchronous to clk?
A new clock domain is not created by a sensitivity list, a new clock domain is created by checking the data signal slow_clk_q for a rising edge. This will connect slow_clk_q to a clock input of a flipflop at synthesis and is a not recommended design practise especially for FPGAs but also for ASICs. Nevertheless this new clock domain will be synchronous to your 12 MHz domain, but exchanging data signals between this 2 clock domains is difficult, as the edge of your slow clock will not happen at the same time as an edge of our 12 MHz clock, but a short time later.
Your questions concentrates on the Item "synchronous". As long as you have only 1 clock source (in your case the 12 MHz clock) all derived signals (for example your slow_clk_q) are synchronous to this clock, because they only can change their value after a rising edge of your single clock source. Only if you have a second independent clock signal (not created by your 12 MHz clock but somewhere else), then you will get a second clock domain which is asynchronous, this means by observing one clock you cannot predict at what time the other clock will have a rising edge.
from datetime import datetime
def YYMMDD0FtoYYYYMMDD(date):
return datetime.strptime(date[:6], "%y%m%d").strftime("%Y-%m-%d")
Example usage:
print(YYMMDD0FtoYYYYMMDD('1403110F')) # Output: '2014-03-11'
I think all you need to do is just make sure the little dropdown at the bottom on the error list has either of the IntelliSense selections selected and you're good to go on live error listings..
For now dividing the original (large image) coords by 3 seems to make it kind of like that, thanks
According to https://docs.spring.io/spring-boot/appendix/application-properties/index.html, the name of the property is enabled-protocols
not protocols
.
This is confirmed by How to enable multiple ssl protocol versions in Spring Boot?.
I have a similar issue - queries are suspended randomly, sometimes they are fast and sometimes suddenly suspended.
My case is:
- console app1 reading from database.
- console app2 which calls app1 to get and use data received from database.
Observations:
- query is fast when call directly in SSMS;
- query is fast when run app1 separately;
- query is suspended sometimes when app2 calls app1.
I asked GitHub Copilot if VPN can be the reason. Here is the response:
Yes, the VPN can absolutely be a factor—even if your database is local.
Why VPN Can Affect Local Database Performance
• Network Routing: When connected to a VPN, all your network traffic (sometimes including local traffic) may be routed through the VPN tunnel. This can introduce latency, packet loss, or even block certain local network connections, depending on VPN configuration.
• DNS Resolution: VPNs can change your DNS settings, which might affect how "localhost" or your machine's name resolves.
• Firewall/Policy Changes: Some VPNs enforce strict firewall rules or network isolation, which can interfere with local connections.
• Split Tunneling: If your VPN does not use split tunneling, even local traffic may be forced through the VPN, slowing down access to local resources.
Why It Might Seem Random
• VPN routing and policies can change dynamically.
• Some VPN clients intermittently enforce different rules or routes.
• If your database connection string uses a hostname instead of localhost or 127.0.0.1, DNS or routing issues may be more likely.
What To Check
• Connection String: Ensure you are using localhost or 127.0.0.1 for local databases.
• VPN Settings: Check if your VPN client has options for split tunneling or local network access.
• Network Interfaces: When VPN is connected, run ipconfig (Windows) or ifconfig (Linux/Mac) to see if your local network interface is still active and prioritized.
Summary
Even for a local database, a VPN can introduce delays or connection issues. If your queries are fast when not using VPN, it's very likely the VPN was causing the problem.
Recommendation:
If you must use VPN, configure it to allow local network access or use split tunneling. Otherwise, disconnect from VPN when working with local resources for best performance.
Finally enabling split tunneling resolved the issue.
Set the '#step' value to "any".
July 2025: Actually, you can record audio off your iPhone. I did it with two new apps: dubnote, a recording app which I got for free for a limited time (but you may have to pay now): and I recorded the audio from Free Vibe, a vibrophone app that plays a simple vibe sound with a virtual vibraphone instrument. Start the dubnote recording, switch over to the instrument app, play it, then switch back to dubnote, stop recording and it's done. I imported the sample into my DAW (Ableton Live) and processed it. It was really easy. I have several iPhone instruments that I want to record, especially the Chinese Guzheng.
Using BLE scanners apps (in my Android mobile phone) like LightBlue and nRF Connect acting as central device to scan and connect with my SoC Arduino UNO R4 WiFi acting as a peripheral device, it's device name are truncated down to 20 chars.
So, I'd use 20 chars at maximum size.
This might be related to the expected way Auth handles errors when Email Enumeration Protection is enabled
.
Additionally, it likely is (and likely should remain) enabled in your project: "If you created your project on or after September 15, 2023, email enumeration protection is enabled by default. "
Have a look to https://patrol.leancode.co/documentation/native/feature-parity. I fixed my problem regarding camera permission
The problem was that I was using an old version of argosd? namely version 2.12.2
enter image description here
The function toYamlPretty requires version helm 3.17, and its support in argoсd was presented only in version v3.0.11.
In my case, the solution was to update the version of my argoсd
https://github.com/argoproj/argo-cd/blob/v3.0.11/hack/tool-versions.sh
In my case, the issue was caused by @property being wrapped inside an @layer. Moving the @property declaration to the top level of the stylesheet solved the crash.
Before:
@layer base {
@property --my-color {
syntax: "<color>";
initial-value: #fff;
inherits: true;
}
/* others */
}
After:
@property --my-color {
syntax: "<color>";
initial-value: #fff;
inherits: true;
}
@layer base {
/* others */
}
Also check that the block's index.js function registerBlockType has right category, not only block.json.
category: 'my-block-category'
For Credit Unions, the accountStatus
will always be "unknown"
.
Why not follow the official Secondary Display API Documentation?
I was having a similar issue and I ended up doing it this way: https://stackoverflow.com/a/79696868/6155941
Let me know if it works for you as well.
If it returns -2146233054, you need to convert to hexa 0x80131522 and then in the documentation you can find what it means. In this case it is https://learn.microsoft.com/en-us/dotnet/api/system.typeloadexception?view=net-9.0 (TypeLoadException).
You are probably passing wrong value of:
dotnet_type.c_str()
You can call Windows binaries from within WSL, so the simplest solution that works out of the box is
import os
os.system('echo hello world | clip.exe')
More complicated data will need to use quoting, an f-string and possibly escaping quotes within the data.
if you press 'i' you will enter INSERT MODE then you should press ESC to get out from INSERT MODE,
then use ':q' + ENTER to quit.
A chatbot is a software application designed to simulate conversation with human users, typically over the internet. Chatbots can be simple (responding to specific commands or keywords) or advanced (using AI to understand and generate natural language Rsoft Technologies.
Probably better suited for server fault, but anyways:
Create a service. If you're using systemd, the suse documentation has a really good writeup on how to create it.
This will both make sure that there is only one instance running per service, as well as run it indefinitely if the service has no exit points.
With `react-native-branch` (including v6.7.1), you cannot reliably retry initialization after a failed first attempt within the same app session.
The only robust solution is to ensure the network is available before the first initialization, or to restart the app if initialization fails.
If you need to support retry logic, consider implementing a user prompt to restart the app after a failed Branch initialization, or delay initialization until you confirm the device is online.
I had the same problem in a project which contained a "token" folder. I renamed that folder and it fixed the problem.
Hmm...
Are you using ProGuard in release but not in debug? That, combined with the fact that the input composable is wrapped in an if
statement, might mean that compose "thinks" there's a view there (and reserves a bit of space).
Maybe instead of
if (isItemChecked) {
CustomInputText()
}
try
AnimatedVisibility(visible = isItemChecked) {
CustomInputText()
}
Hope this works!
Disclaimer: I'm a QuickNode employee.
This marketplace add-on returns block number(s) by timestamp or range of timestamps for Bitcoin. So, you can call qn_getBlockFromTimestamp
with a timestamp, and get the corresponding block number. Then, you can fetch transactions with a regular method. marketplace.quicknode.com/add-on/block-timestamp-lookup
After some more research, it seems that the problem ist the Ktor development mode which I set in my main method with System.setProperty("io.ktor.development", "true")
Sorry, was not visible in my initial question.
When I set this mode to false, the problem disappear.
Here is a similar problem description.
.flex-container {
min-height: 0;
overflow: visible;
}
Also, ensure the grid item doesn't have a fixed height that restricts content. Use align-items and justify-content properly inside the flex container.
This has been reported in https://bugs.launchpad.net/ubuntu/+source/git/+bug/2116251 and reverted in 2.34.1-1ubuntu1.14
For anyone facing this, my issue is that i had a comma in the variable implementation... yeah I know.
Work flow everyone keep it going market is going amazing couldn't do it without you. Even though I did the calculations I new it would work. Now save save save
I got an error like this on Node v20, and was able to fix it by upgrading to Node v22.
Thanks! it's worked for me. Thanks a lot. @adam440
The command is indeed now just named arrows
Unfortunately, Google does not see fit to allow this. It causes a ton of duplication between scripts, tons of "wrapper functions" and generally leads to a lot of needless spaghetti code.
They really need to fix calling functions from a library with the UI.
I recently had to implement something similar, so I put together a basic demo that handles most of these features:
Auto focus
Backspace navigation
Paste support
Input restrictions
Simple UI customization
it is built using SwiftUI along with a use of UIKit to handle backspace navigation and paste support.
Link - https://github.com/jeetrajput01/PinEntrySwiftUI
If you form a string from the set, you could use concat() to check whether the variable value is included.
<xsl:if test="contains('7 8 9', $k)">
<!-- Do something -->
</xsl:if>
I also guess it could be caused by a server certificate which is signed by a CA.
Many OPC UA servers send only the leaf certificate, but the client must be able to resolve the full certificate chain.
All certificates of the chain must be either in the trusted (at least one) or in the issuer list.
Haha you installed my computer software everyone good job but it only listen to those in processing and can't block my command eye retina connect
for 0
value i need to use if val is None else
structure, so added filter ifnone
:
def ifnone(val, default):
if val is None:
return default
return val
...
env.filters["ifnone"] = ifnone
Useage in template: {{val|ifnone('--')}}
After a bit more searching, it turns out that while I can't have a wildcard, but I can have other defined values. As a result, this works:
| init xs == [head xs, head xs, head xs, head xs] = 0
And I just needed to make the inspector window wider, but I spent 2 days looking for the problem in everything else
Nevermind.
sourceforge.net/p/gnuplot/bugs/2634
This is a two-year-old known bug in gnuplot on Ubuntu. Why that specific? Who knows? But the solution is to invoke the gnuplot script in an environment where GDK_BACKEND=x11
That is the solution to allow the gnuplot process's wxt terminal to actually update with every new plot command.
This question is closed.
Found the response by digging into each part of the documentation. The driver's default mechanisms are not capable of detecting I/O, locks or Thread.sleep blocking calls, hence, something extra needs to be done described here: https://docs.datastax.com/en/developer/java-driver/4.14/manual/core/non_blocking/index.html#using-the-driver-with-reactor-block-hound
I encountered similar issues with Pandas TA and have now switched to a fork that's compatible with NumPy 2:
pandas-ta-openbb
Link: https://pypi.org/project/pandas-ta-openbb/
Maybe that's an idea for you as well.
In case someone comes here whose problem is not dashes:)
I had a silly one, directive (remote-cert-tls server) after the embedded data. I had some commented directive there, and thought they can occur anywhere in the config file. They can not, embedded keys must come last.
Solved by adding postup to the action in mobile_navigation.xml
<fragment
android:id="@+id/nav_home"
android:name="com.navtest.ui.home.HomeFragment"
android:label="fragment_home"
tools:layout="@layout/fragment_home" >
<action
android:id="@+id/action_nav_home_to_nav_gallery"
app:destination="@id/nav_gallery"
app:launchSingleTop="true"
app:popUpTo="@id/nav_home"
app:popUpToInclusive="true" />
</fragment>
I share it because I was not able to find the solution anywhere.
Give a image of database my personal library for returning
Use book ID, use yes no for returning ,author name and book name
Can you share the component where you use the BuildProvider
? It's probably in your App.js
or a similar root component.
Ideally, it should be structured like this:
<BuildProvider>
<BrowserRouter>
<App />
</BrowserRouter>
</BuildProvider>
If your BuildProvider
is placed inside the BrowserRouter
or even inside individual route components, it might be getting unmounted and remounted during navigation. That would cause your context to reset and potentially overwrite the localStorage
with empty or default values, which are then reloaded as the new state.
Also, considering you're managing a lot of independent state values inside the provider, it might be worth looking into a more scalable state management solution like Zustand.
The solution for me was reinstalling watchman: brew uninstall watchman && brew install watchman
Verify the app in test flight build. And it will be considered as Sandbox only.
It wil be exactly like testing on production environment.
Easy and Scalable Solution.
If you have limited variables then answer of @tyg (link) is enough.
My solution handles scalability, if you have 1000+ variables? and also type Text() composable inside column 1000+ times? No.
It is based on Observable Lists i.e MutableStateList (official codelab by google check) and lazy column instead of simple column.
Simple steps:
get all data into list
convert it into MutableStateList using list.toMutableStateList() extension
show lazycolumn using this MutableStateList items
update it based on it's indexes on buttonclick
**
100% working code:**
@Preview(showBackground = true)
@Composable
fun MinimalMutableStateComposable(modifier: Modifier = Modifier) {
val dataList = getMyData() //first get complete data
val mutableDataListState =
remember { dataList.toMutableStateList() } //and then turn it into state_list, don't build MutableStateList item by item here to avoid weird recompositions
LazyColumn(modifier = modifier.padding(16.dp)) {
items(mutableDataListState) {
Text(text = it.toString())
}
item {
Button(
onClick = {
mutableDataListState[0] = 100 //updating 0th value, you can update any value at index
}
) {
Text("Change some value")
}
}
}
}
//method that returns you data which can be any length
fun getMyData(): List<Int> =
listOf(1, 2, 3, 4, 5, 6) // which is a,b,c,d,e,f,g change this data
@Preview
@Composable
fun PreviewMinimalMutableStateComposable() {
MinimalMutableStateComposable()
}
If you want to change every value and need buttons for every item then you will use some Row which groups Text and Button and use itemsIndexed instead items inside lazycolumn, somewhat like below:
itemsIndexed(mutableDataListState) { index, value ->
ItemRowTextWithButton(
index = index,
value = value,
onUpdate = { i -> mutableDataListState[i] = value + 1 } //lambda to update
)
}
Initially, chat moderation looks like a huge cost when considering purely human moderators. Manual moderation is hiring and training staff, time-consuming, and expensive-the bigger the volume over text, images, and voice chats-another dimension.
With the age of AI-powered moderation tools, the cost has become realizable and scalable. Visualize content monitoring 24/7 and with no labour costs; imagine massive amounts of data being filtered in real time. These are things that human moderators cannot achieve with efficiency.
Maybe the smartest and most budget-friendly way is the hybrid: allow AI systems to do bulk filtering, while actual humans assess the less-obvious cases. Keeping costs down ensures the right level of moderation: protecting the brand, staying compliant, and providing a safe user environment.
To conclude, there is an expense involved in chat moderation, but those expenses sit so much lower than the damage costs that come with unmoderated chats-taking legal risks, user drop-off, or loss of brand reputation for instance. It is not simply an expense, but an investment in digital safety and trust.
There is the one I developed :
Take a look at vcstool (python module) and it's forks.
I am using it as a replacement for both the SVN externals and git modules.
Status of vcstool: https://github.com/dirk-thomas/vcstool/issues/242
Investigation for SVN replacement:
Git modules experience
: https://gist.github.com/andry81/b0000d2ddfa890f7ac68f1cabb6c1978
To use react-native-dotenv
with different .env
files in your web development or mobile project, you can set up environment-specific files like .env.dev
, .env.prod
, etc. Then, configure Babel with a plugin like module:react-native-dotenv
and pass the correct file path using the envFile
option. Finally, run your project with a script that points to the desired environment file.
✅ It helps keep secrets organized and your app environment-specific!
It turned out that, since I installed everything via VSCode the python version used is located in the PlatformIO folder under '~/.platformio/penv/' and the distutils are available in the setuptools pkg.
Therfore I installed it there with
source .platformio/penv/bin/activate
pip install setuptools
now it works
We had similar issue, but as our enums have named keys we could find out which are problematic. Found the solution by adding WrapperType to them at all dto-s where they were used
WrapperType described here https://docs.nestjs.com/recipes/swc#common-pitfalls
I'm in here seeking help myself, but on a slightly different topic. I was able to get the IRQ for IO working. I am using 2024.2, if you are as well, do not use IDs but rather base addresses. Base Address for all of your AXI IP Blocks are defined in xparameters.h. Hope this helps.
Well, as usual the error was on my side. I did check the position of the SD-card and saw, that it was misplaced. After attaching it correctly, the device shows up and can be mounted as usual.
Sorry for bothering you!
KR, Christof
Take a look at vcstool (python module) and it's forks.
I am using it as a replacement for both the SVN externals and git modules.
Status of vcstool: https://github.com/dirk-thomas/vcstool/issues/242
Investigation for SVN replacement:
Git modules experience
: https://gist.github.com/andry81/b0000d2ddfa890f7ac68f1cabb6c1978
For this you need to store(in shared prefs) count of steps when user first opens the app after reboot (call it Int initialStepsAfterReboot). And the total steps count since reboot will also be fetched from sensorEvent.values[0] (call it Int totalStepsSinceReboot). Whenever you want to get total steps user has walked today(since he opened the app) you will subtract initial steps count from total steps count.
you will use following formula:
Int totalStepsCountToday = totalStepsSinceReboot - initialStepsAfterReboot //totalStepsSinceReboot was fetched using sensorEvent.values[0] as you said
then next day you will reset initialStepsAfterReboot based on a value you will store to know when was this initial steps recorded , was it today or yesterday? call it Date initialStepsAfterRebootRecordedDate . And you will update initialStepsAfterReboot to whatever value you get when user opened app using sensorEvent.values[0] and use same formula again and again after verifying that date of today is same as initialStepsAfterRebootRecordedDate i.e it should be valid for today not outdated.
variables to store | description |
---|---|
initialStepsAfterRebootcount | count of steps when user first time launch app after reboot. |
initialStepsAfterRebootRecordedDatedate | count of the day when you stored initialStepsAfterReboot to check if it's valid for today or outdated. |
for example, if user opened your app and sensorEvent.values[0] returns 100 steps, which means today you have extra 100 steps, now when user walked 300 steps, sensorEvent.values[0] will show you 400 steps, so you subtract initialSteps=100 from totalSteps=400 so you will get 100, and this is correct. Next day you will check if the initialStepsRecordedDate is today or yesterday, if it's today, use it, otherwise update it to sensorEvent.values[0].
Make sure you don't update initialStepsAfterReboot again and again when user opens the app, rather you update it only if it's null/empty or outdated. this will make sure that you update it once a day only.
PS: pls share more snippets so I can help more.
Another way to save all output to a file using ob_start() (before any output) with callback function:
ob_start(function ($buffer) {
file_put_contents('file.txt', $buffer, FILE_APPEND);
return $buffer; // remove this line if you dont want to show the output
});
facing the same issue. were you able to solve it?
It works perfectly, thanks Aswin
The one I developed :
same problem for me!
have you solved? Mostafa ALZOUBI
你好,请问你解决了该问题吗?我是在iOS18.5出现的这个问题
You should use now RouterTestingHarness ( https://angular.dev/api/router/testing/RouterTestingHarness ) since Angular 15.2 as RouterTestingModule is deprecated ( https://angular.dev/api/router/testing/RouterTestingModule )
see the video made by Rainer Hahnekamp (12 minutes) : https://www.youtube.com/watch?v=DsOxW9TKroo ( from https://www.rainerhahnekamp.com/en/how-do-i-test-using-the-routertestingharness/ )
The production code (you need to test the ngOnInit() method) :
ngOnInit(): void {
if (this.router.url.endsWith('admin/user-list')) {
this.activeLinkIndex = 1;
} else if (this.router.url.endsWith('admin/group-list')) {
this.activeLinkIndex = 2;
}
}
The test code :
import { RouterTestingHarness } from '@angular/router/testing';
describe('MyComponent', () => {
...
const routes: Routes = [
{ path: 'admin/user-list', component: UserListComponent },
{ path: 'admin/group-list', component: GroupListComponent },
];
beforeEach(async () => {
await TestBed.configureTestingModule({
imports: [MyComponent, ... ],
providers: [provideRouter(routes)],
}).compileComponents();
fixture = TestBed.createComponent(MyComponent);
component = fixture.componentInstance;
fixture.detectChanges();
});
...
it('should set activeLinkIndex to 2 when targetted URL is admin/group-list', async () => {
await RouterTestingHarness.create('admin/group-list');
component.ngOnInit();
expect(component.activeLinkIndex).toBe(2);
});
...
Good question...those particular consonant combinations that are not just combination of two letter shapes. I think there are 15 of them in Nepali. Those 15 shapes do not appear among the unicode shapes.
The issue was related to the permissions of rooms and the service account that is used in the MS Graph API. However, the error message is confusing because it refers to invalid parameters and "ErrorItemNotFound." It would be better to receive a message about permission issues.
you need to either assign the values while creating the array or specify the size of the array MyStruct array[10]
The compiler needs to know how many elements you will have
I have written a misc function that seems to work:
function getJdbcCurrency(result, col) {
let amntStr = result.getString(col);
if (result.wasNull())
{
return null;
}
if (amntStr.length == 0) {
return null;
}
return Number.parseFloat(amntStr);
}
Usage
row.push(getJdbcCurrency(results, col+1));
Parsing from string protects me from rounding issues, even if the number is still parsed as float.
I have suffered from this issue as well after upgrading flutter.
What solved the issue for me was adding to main.dart:
import 'dart:io' as io;
if (kDebugMode) {
io.HttpClient.enableTimelineLogging = true;
}
Before the runApp method.
İstanbul gibi büyük ve yoğun bir şehirde yaşıyorsanız, zamanın ne kadar değerli olduğunu çok iyi bilirsiniz. Özellikle iş çıkış saatlerinde, etkinlik alanlarında trafik yoğunluğu pek de iyi olmaz ancak, acil vale hizmeti bu sorunu ortadan kaldırıyor. Belirlediğiniz konuma trafiğe takılmada hızlı ve güvenli şekilde ulaştırmaktadır. İstanbul motor vale hizmetimiz, şehrin dört bir yanına ulaşabilen, motorlu ve profesyonel ekibimiz trafiğe takılmadan konuma ulaşır, aracınız yada aracımız ile sizler hiç yorulamadan ulaştırıyoruz. Acil vale sistemimiz, aynı zamanda araç teslimde yapmaktadır. İstediğiniz yerden arabanızı alıp, istediğiniz zamanda belirlenen konuma götürmektedir.
It does not work, please can someone help.
import random
num = []
attempts = 0
def makeNum():
for i in range(4):
x = random.randrange(0, 9)
num.append(x)
if len(num) > len(set(num)):
num.clear()
makeNum()
def playGame():
global attempts
attempts = attempts + 1
cows = 0
bulls = 0
print(num)
try:
choice = int(input("Please enter a 4 digit number: "))
guess = []
except ValueError:
print("invalid input try again, enter only digits.")
playGame()
for i in range (4):
guess.append(int(choice[i]))
for i in range (4):
for j in range(4):
if(guess[i] == num[j]):
cows = cows + 1
for x in range (4):
if guess[x] == num[x]:
bulls = bulls + 1
print("Bulls: ", bulls)
print("Cows: ", cows)
if(bulls == 4):
print("You won after " ,attempts, "attempts.")
if(bulls != 4):
playGame()
makeNum()
playGame()
print("You won the game.")
This worked well for me too. However, i would also like to include the legend with color codes but im struggling to do so, anyone know a workaround?
Documentation (see the highlighted Note block) states that auto-generated columns are rendered after explicit columns. I assume that if there was a built-in way to change this behavior it would be stated there.
I suggest trying to generate the columns in code-behind so you can have full control of the order they are rendered in.
I found a shortcut for changing icon information. Simply open your project's .dproj file in an editor and rename the icons in the <Icon_MainIcon> sections.
For example:
<Icon_MainIcon>old.ico</Icon_MainIcon>
<Icon_MainIcon>new.ico</Icon_MainIcon>
Inspired by @maxhb answer,
# package.json
{
"scripts": {
"cy:run:ci": "cypress run --headless --config-file cypress-ci.js --browser chromium | sed -n -e '/Run Finished/,$p'"
}
}
After upgrading from Expo SDK 51 to SDK 52, you're correct — the expo-barcode-scanner
module has been deprecated and is no longer maintained as a standalone package. Expo now recommends using expo-camera
to implement barcode scanning functionality. However, proper integration requires a few key changes.
If you're encountering issues using expo-camera
for barcode scanning, follow the steps below to troubleshoot and implement it correctly.
expo-camera
in SDK 52:1. Install expo-camera
:
bash
npx expo install expo-camera
2. Request Camera Permissions:
js
import{ Camera } from 'expo-camera'; const [permission, requestPermission] = Camera.useCameraPermissions(); useEffect(() => { requestPermission(); }, []);
3. Implement Barcode Scanner Using onBarCodeScanned
:
jsx
<Camera style={{ flex: 1 }} onBarCodeScanned={({ type, data }) => { console.log(`Scanned ${type}: ${data}`); }} barCodeScannerSettings={{ barCodeTypes: [ Camera.Constants.BarCodeType.qr, Camera.Constants.BarCodeType.code128, ], }} />
Ensure your expo-camera
version is compatible with SDK 52.
Wrap the Camera
component in a properly styled View
container.
If the onBarCodeScanned
callback isn't firing, make sure the camera has proper focus and is visible on the screen.
At Technource, a leading mobile app development company, we recently encountered this transition challenge during a client project. Switching entirely to expo-camera
—with correct permission handling and barcode settings—resolved the issue effectively.
If problems persist, check the official Expo SDK 52 changelog or community threads on GitHub for additional fixes and updates.
Use Concat option :
@concat('SELECT * FROM table WHERE author =', item().author)
Assuming you dont need quotes within the values
you have to configure SQL Server to accept TCP/IP connections (it is disabled by default) and you need to set the port number.
1- Go to SQL Server Configuration Manager
2- Open SQL server Network Configuration/Protocols for SQLEXPRESS
3- Set TCP/IP to Enabled
4- Right click on TCP/IP Properties and set the port number
All the answers did not work for me with Mui 5.X.
What actually worked to change the background color of the sticky header is the following
<Table stickyHeader sx={{'& th': {backgroundColor: 'blue'}}}>
and as theme override
MuiTable: {
styleOverrides: {
stickyHeader: {
'& th': {
backgroundColor: 'transparent',
},
},
},
},
X-Robots-Tag: noindex
to instruct Google to non-HTML content, as well as JSON files