Manipulating database using chatgpt

System Info
Is there any way to manipulate the data in database like update, insert, delete through chatgpt chatbot with openai and langchain?
Who can help?
No response
Information

[ ] The official example notebooks/scripts
[ ] My own modified scripts

Related Components

[ ] LLMs/Chat Models
[ ] Embedding Models
[ ] Prompts / Prompt Templates / Prompt Selectors
[ ] Output Parsers
[ ] Document Loaders
[ ] Vector Stores / Retrievers
[ ] Memory
[ ] Agents / Agent Executors
[ ] Tools / Toolkits
[ ] Chains
[ ] Callbacks/Tracing
[ ] Async

Reproduction
Is there any way to manipulate the data in database like update, insert, delete through chatgpt chatbot with openai and langchain?
Expected behavior
possibility of  manipulate the data in database like update, insert, delete through chatgpt chatbot with openai and langchain?

Here you go, I have construct a Agent who have a tool that can execute DML queries on your underlying SQL database.

from langchain.sql_database import SQLDatabase
from langchain.prompts import ChatPromptTemplate, MessagesPlaceholder,PromptTemplate
from langchain.tools import BaseTool
from langchain.tools.render import format_tool_to_openai_function
from langchain.schema.runnable import Runnable,RunnableLambda,RunnableParallel
from langchain.chat_models import ChatOpenAI
from langchain.agents.format_scratchpad import format_to_openai_function_messages
from langchain.agents.output_parsers import OpenAIFunctionsAgentOutputParser
from langchain.agents import AgentExecutor
from pydantic import BaseModel, Field
import os

os.environ['OPENAI_API_KEY'] = 'sk-xxxxxxxxxxxx'
SQL_DML_CHAIN_PROMPT = """You are expert in SQLITE. Your main objective is to construct Data manipulation SQLITE query give the
user question: {user_question}.

You need to construct the Data manipulation SQLITE query for the following Database Schema:
{table_info}

Only Output the final SQL-Query and nothing else.

SQL-Query:"""

prompt = PromptTemplate(template = SQL_DML_CHAIN_PROMPT,input_variables = ['user_question','table_info'])
db =  SQLDatabase.from_uri("sqlite:///chinook.db")
sql_dml_chain = RunnableParallel ({"user_question":lambda x:x["user_question"],
                 "table_info":lambda _: db.get_table_info()}) |\
                prompt |\
                ChatOpenAI().bind(stop='SQL-Query:') |\
                RunnableLambda(lambda x:x.content.strip().replace('```sql',''))
agent_prompt = ChatPromptTemplate.from_messages(
    [
        ("system", """
        You are expert in SQL whose main objective is to mainpulate the Chinook Database for which you have
        been given access. You can use the tool `sql_db_manipulation` to interact with  Chinook Database and
        mainpulate the database as per the user requirement.
"""),
        ("user", "{input}"),
        MessagesPlaceholder(variable_name="agent_scratchpad"),
    ]
)

class SQLDBMANIPULATION(BaseModel):
    user_query: str = Field(description='User question which will be translated to a Data Manipulation SQL Query and will be executed on the underlying database')

class SQLDBMANIPULATIONTool(BaseTool):
    name = "sql_db_manipulation"
    description = "Use this tool to convert and execute DML queries given the user question"
    args_schema: type[SQLDBMANIPULATION] = SQLDBMANIPULATION
    sql_dml_chain: Runnable
    def _run(
        self, user_query: str
    ) -> str:
        """Use the tool."""
        query = sql_dml_chain.invoke({"user_question":user_query})
        db._execute(query)

tools = [SQLDBMANIPULATIONTool(sql_dml_chain = sql_dml_chain)]
llm_with_tools = ChatOpenAI().bind(functions=[format_tool_to_openai_function(t) for t in tools])
agent = (
    {
        "input": lambda x: x["input"],
        "agent_scratchpad": lambda x: format_to_openai_function_messages(
            x["intermediate_steps"]
        ),
    }
    | agent_prompt
    | llm_with_tools
    | OpenAIFunctionsAgentOutputParser()
)

agent_executor = AgentExecutor(agent=agent, tools=tools, verbose=True)
agent_executor.invoke({"input":"CREATE the invoices table with columns id,values"})

Hi MD Mohtashim,
thank you for the code, i see its specifically for modifying the DB, but i
have created a chatbot for interacting with the DB, so can i integrate this
code with it?
On Fri, 29 Dec 2023 at 02:01, Mohammad Mohtashim @.***>
wrote:

Here you go, I have construct a Agent who have a tool that can execute DML
queries on your underlying SQL database.
from langchain.sql_database import SQLDatabasefrom langchain.prompts import ChatPromptTemplate, MessagesPlaceholder,PromptTemplatefrom langchain.tools import BaseToolfrom langchain.tools.render import format_tool_to_openai_functionfrom langchain.schema.runnable import Runnable,RunnableLambda,RunnableParallelfrom langchain.chat_models import ChatOpenAIfrom langchain.agents.format_scratchpad import format_to_openai_function_messagesfrom langchain.agents.output_parsers import OpenAIFunctionsAgentOutputParserfrom langchain.agents import AgentExecutorfrom pydantic import BaseModel, Fieldimport os
os.environ['OPENAI_API_KEY'] = 'sk-xxxxxxxxxxxx'SQL_DML_CHAIN_PROMPT = """You are expert in SQLITE. Your main objective is to construct Data manipulation SQLITE query give theuser question: {user_question}.You need to construct the Data manipulation SQLITE query for the following Database Schema:{table_info}Only Output the final SQL-Query and nothing else.SQL-Query:"""
prompt = PromptTemplate(template = SQL_DML_CHAIN_PROMPT,input_variables = ['user_question','table_info'])db =  SQLDatabase.from_uri("sqlite:///chinook.db")sql_dml_chain = RunnableParallel ({"user_question":lambda x:x["user_question"],
"table_info":lambda _: db.get_table_info()}) |
prompt |
ChatOpenAI().bind(stop='SQL-Query:') |
RunnableLambda(lambda x:x.content.strip().replace('```sql',''))agent_prompt = ChatPromptTemplate.from_messages(
[
("system", """        You are expert in SQL whose main objective is to mainpulate the Chinook Database for which you have        been given access. You can use the tool sql_db_manipulation to interact with  Chinook Database and        mainpulate the database as per the user requirement."""),
("user", "{input}"),
MessagesPlaceholder(variable_name="agent_scratchpad"),
]
)
class SQLDBMANIPULATION(BaseModel):
user_query: str = Field(description='User question which will be translated to a Data Manipulation SQL Query and will be executed on the underlying database')
class SQLDBMANIPULATIONTool(BaseTool):
name = "sql_db_manipulation"
description = "Use this tool to convert and execute DML queries given the user question"
args_schema: type[SQLDBMANIPULATION] = SQLDBMANIPULATION
sql_dml_chain: Runnable
def _run(
self, user_query: str
) -> str:
"""Use the tool."""
query = sql_dml_chain.invoke({"user_question":user_query})
db._execute(query)
tools = [SQLDBMANIPULATIONTool(sql_dml_chain = sql_dml_chain)]llm_with_tools = ChatOpenAI().bind(functions=[format_tool_to_openai_function(t) for t in tools])agent = (
{
"input": lambda x: x["input"],
"agent_scratchpad": lambda x: format_to_openai_function_messages(
x["intermediate_steps"]
),
}
| agent_prompt
| llm_with_tools
| OpenAIFunctionsAgentOutputParser()
)
agent_executor = AgentExecutor(agent=agent, tools=tools, verbose=True)agent_executor.invoke({"input":"CREATE the invoices table with columns id,values"})
—
Reply to this email directly, view it on GitHub
https://github.com/langchain-ai/langchain/issues/15266#issuecomment-1871471646,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/A2DGDSKSIVYZNEBNJ3ZXYZLYLXJJBAVCNFSM6AAAAABBFOIF56VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNZRGQ3TCNRUGY
.
You are receiving this because you were mentioned.Message ID:
@.***>

Yes you can but be careful since this chatbot can manipulate records in your DB.

Hi @dosubot,
I'm able to modify the code with AgentExecutor but not with the SQLDatabaseChain
AgentExectore code
def chat(question):
llm = OpenAI(temperature=0)
tools = load_tools(["llm-math"], llm=llm)

agent = initialize_agent(tools, llm, agent=AgentType.ZERO_SHOT_REACT_DESCRIPTION)

db = SQLDatabase(engine, view_support=True, include_tables=['HRMSGPTAutomation'])
llm = ChatOpenAI(model_name="gpt-3.5-turbo",
                temperature=0,
                max_tokens=1000)

# toolkit = SQLDatabaseToolkit(db=db)
toolkit = SQLDatabaseToolkit(db=db, llm=llm)
agent_executor = create_sql_agent(
    llm=llm,
    toolkit=toolkit,
    verbose=True,
    reduce_k_below_max_tokens=True,
)

mrkl = initialize_agent(
    tools,
    ChatOpenAI(temperature=0),
    agent=AgentType.CHAT_ZERO_SHOT_REACT_DESCRIPTION,
    verbose=True,
    handle_parsing_errors=True,
)

return agent_executor.run(question)

answer= chat("modify shilpi deshmukh  name as Shilpi")
answer= chat(" add a row with employee name Preeti, employee id AD2302011, contact number 959100712")
answer= chat(" add designation of Preeti as software eng bngl")
answer= chat(" delete the row with employee name preeti")
answer= chat("what are Rathakrishnan Ganesan designation")
print(answer)
QLDatabaseChain code
def chat(question, sql_format):
# Initialize variables
model_name="gpt-3.5-turbo-16k"
db = SQLDatabase(engine, view_support=True, include_tables=['EGV_emp_departments_ChatGPT', 'emp_attendance_query'])
# db = SQLDatabase(engine, include_tables=[ 'emp_attendance_query'])
llm = ChatOpenAI(temperature=0, verbose=False, model=model_name)
answer = None
# Check if the input is in SQL format or not
if sql_format == False:
    # If not in SQL format, create a database chain and run the question
    db_chain = SQLDatabaseChain.from_llm(llm, db, verbose=True)
    answer = db_chain.run(question)
else:
    # If in SQL format, create a database chain and get the SQL query
    db_chain = SQLDatabaseChain.from_llm(llm, db, verbose=True, return_sql=True)
    sql_query = db_chain.run(question)
    print("SQLQuery: " + str(sql_query))

    # Execute the SQL query and store the results in a DataFrame
    result_df = pd.read_sql(sql_query, engine)

    # Check if the DataFrame is empty and return a message if no results are found
    if result_df.empty:
        return "No results found"

    # Convert the DataFrame to a dictionary
    answer = result_df.to_dict()
    # result_df.plot(kind='bar', x='category', y='count')
    # result_df.plot(kind='bar')
    # # plt.pie(result_df)
    # plt.show()

return answer

Define a function named chain1 that uses the chat function without SQL format
def chain1(question):
text = chat(question, False)
return text
Define a function named chain2 that uses the chat function with SQL format
def chain2(question):
query = chat(question, True)
return query
chain2("give a count of employess joined in 2023 in each month")
print(chain2)
chain1("add a row with employee name Preeti, employee id AD2302011, contact number 959100712")
print(chain1)
can we be able to integrate the agentExecutor or the one shared by [keenborder786] and SQLDatabaseChain, to obtain the output with chain and modify with agent?

hi @dosubot,
here i'm trying to create plots using langchain, below is the code
import dotenv
import pandas as pd
from langchain import LLMChain, OpenAI, SQLDatabase
from langchain_experimental.sql import SQLDatabaseChain
from langchain.agents import (AgentExecutor, Tool, ZeroShotAgent,
initialize_agent, load_tools)
dotenv.load_dotenv(override=False)
from langchain.chat_models import ChatOpenAI
from secret_key import openapi_key
import os
os.environ['OPENAI_API_KEY'] = openapi_key
from urllib.parse import quote_plus
server_name = "########"
database_name = "#####"
username = "#####"
password = "######"
encoded_password = quote_plus(password)
connection_uri = f"mssql+pyodbc://{username}:{encoded_password}@{server_name}/{database_name}?driver=ODBC+Driver+17+for+SQL+Server"
import pandas as pd
import sqlalchemy as sal
from sqlalchemy import create_engine
engine = create_engine(connection_uri)
model_name="gpt-3.5-turbo-16k"
db = SQLDatabase(engine, view_support=True, include_tables=['EGV_emp_departments_ChatGPT'])
llm = ChatOpenAI(temperature=0, verbose=False, model=model_name)
db_chain = SQLDatabaseChain.from_llm(llm, db, verbose=True, return_direct=True)
from langchain_experimental.utilities import PythonREPL
Add python_repl to our list of tools
tools = load_tools(["python_repl"])
tools = []  # Create an empty list for tools
Instantiate PythonREPL tool
python_repl_tool = PythonREPL()
Define our voter_data tool
Set a description to help the LLM know when and how to use it.
description = (
"Useful for when you need to answer questions about voters. "
"You must not input SQL. Use this more than the Python tool if the question "
"is about voter data, like 'how many DEM voters are there?' or 'count the number of precincts'"
)
repl_tool = Tool(
name="Data",  # We'll just call it 'Data'
func=db_chain.run,
description=description,
)
tools.append(repl_tool)
Define tools
tools = [PythonTool(), repl_tool]  # Use PythonTool
Standard prefix
prefix = "Fulfill the following request as best you can. You have access to the following tools:"
Remind the agent of the Data tool, and what types of input it expects
suffix = (
"Begin! When looking for data, do not write a SQL query. "
"Pass the relevant portion of the request directly to the Data tool in its entirety."
"\n\n"
"Request: {input}\n"
"{agent_scratchpad}"
)
The agent's prompt is built with the list of tools, prefix, suffix, and input variables
prompt = ZeroShotAgent.create_prompt(
tools, prefix=prefix, suffix=suffix, input_variables=["input", "agent_scratchpad"]
)
Set up the llm_chain
llm_chain = LLMChain(llm=llm, prompt=prompt)
Specify the tools the agent may use
tool_names = [tool.name for tool in tools]
agent = ZeroShotAgent(llm_chain=llm_chain, allowed_tools=tool_names)
Create the AgentExecutor
agent_executor = AgentExecutor.from_agent_and_tools(
agent=agent, tools=tools, verbose=True
)
request = "Show a bar graph visualizing the answer to the following question:"
"give a count of employess joined in 2023 in each month"
#"What are the count employess who joined in 2023 ?"
agent_executor.run(request)
so here, instead of agents, can i use SQLDatabaseChains like in my previous code, i want to integrate it to the main extraction code?

Here you go, I have construct a Agent who have a tool that can execute DML queries on your underlying SQL database.
from langchain.sql_database import SQLDatabase
from langchain.prompts import ChatPromptTemplate, MessagesPlaceholder,PromptTemplate
from langchain.tools import BaseTool
from langchain.tools.render import format_tool_to_openai_function
from langchain.schema.runnable import Runnable,RunnableLambda,RunnableParallel
from langchain.chat_models import ChatOpenAI
from langchain.agents.format_scratchpad import format_to_openai_function_messages
from langchain.agents.output_parsers import OpenAIFunctionsAgentOutputParser
from langchain.agents import AgentExecutor
from pydantic import BaseModel, Field
import os

os.environ['OPENAI_API_KEY'] = 'sk-xxxxxxxxxxxx'
SQL_DML_CHAIN_PROMPT = """You are expert in SQLITE. Your main objective is to construct Data manipulation SQLITE query give the
user question: {user_question}.

You need to construct the Data manipulation SQLITE query for the following Database Schema:
{table_info}

Only Output the final SQL-Query and nothing else.

SQL-Query:"""

prompt = PromptTemplate(template = SQL_DML_CHAIN_PROMPT,input_variables = ['user_question','table_info'])
db =  SQLDatabase.from_uri("sqlite:///chinook.db")
sql_dml_chain = RunnableParallel ({"user_question":lambda x:x["user_question"],
                 "table_info":lambda _: db.get_table_info()}) |\
                prompt |\
                ChatOpenAI().bind(stop='SQL-Query:') |\
                RunnableLambda(lambda x:x.content.strip().replace('```sql',''))
agent_prompt = ChatPromptTemplate.from_messages(
    [
        ("system", """
        You are expert in SQL whose main objective is to mainpulate the Chinook Database for which you have
        been given access. You can use the tool `sql_db_manipulation` to interact with  Chinook Database and
        mainpulate the database as per the user requirement.
"""),
        ("user", "{input}"),
        MessagesPlaceholder(variable_name="agent_scratchpad"),
    ]
)

class SQLDBMANIPULATION(BaseModel):
    user_query: str = Field(description='User question which will be translated to a Data Manipulation SQL Query and will be executed on the underlying database')

class SQLDBMANIPULATIONTool(BaseTool):
    name = "sql_db_manipulation"
    description = "Use this tool to convert and execute DML queries given the user question"
    args_schema: type[SQLDBMANIPULATION] = SQLDBMANIPULATION
    sql_dml_chain: Runnable
    def _run(
        self, user_query: str
    ) -> str:
        """Use the tool."""
        query = sql_dml_chain.invoke({"user_question":user_query})
        db._execute(query)

tools = [SQLDBMANIPULATIONTool(sql_dml_chain = sql_dml_chain)]
llm_with_tools = ChatOpenAI().bind(functions=[format_tool_to_openai_function(t) for t in tools])
agent = (
    {
        "input": lambda x: x["input"],
        "agent_scratchpad": lambda x: format_to_openai_function_messages(
            x["intermediate_steps"]
        ),
    }
    | agent_prompt
    | llm_with_tools
    | OpenAIFunctionsAgentOutputParser()
)

agent_executor = AgentExecutor(agent=agent, tools=tools, verbose=True)
agent_executor.invoke({"input":"CREATE the invoices table with columns id,values"})

Hi @keenborder786
I'm using this code but im facing an issue, while
Invoking: sql_db_manipulation with {'user_query': "UPDATE PAY_transaction_settingallow SET [euid] = (SELECT [employeeEuid] FROM employee_details WHERE [employeeName] = 'H#######'), [alw_id] = (SELECT [alw_id] FROM pay_mst_allowance WHERE [alw_desc] = 'Incentive - bt'), [amount] = 2001, [createDate] = GETDATE(), [effect_date] = '2024-03-01', [to_date] = '2024-03-31'"}
it generating a proper query where it's taking the proper [createDate] = GETDATE()
but while executing the query ie. db._execute(query) its taking as
[SQL: UPDATE PAY_transaction_settingallow
SET [euid] = (SELECT [employeeEuid] FROM employee_details WHERE [employeeName] = 'H#######'),
[alw_id] = (SELECT [alw_id] FROM PAY_mst_allowance WHERE [alw_desc] = ' Incentive - bt'),
[amount] = 2001,
[createDate] = DATETIME('now'),
[effect_date] = '2024-03-01',
[to_date] = '2024-03-31';]
because of which i'm gettiing error as "'DATETIME' is not a recognized built-in function name."
"sqlalchemy.exc.ProgrammingError: (pyodbc.ProgrammingError) ('42000', "[42000] [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]'DATETIME' is not a recognized built-in function name."
can you please let me know how to solve this


[MRG] Backend bug escaping variable and user input in emails

Ready for merge after #212 .
Fixing issue identified by @aapeliv in #215 with the solution I found here:
https://laracasts.com/discuss/channels/laravel/escape-string-parameters-for-markdown-emails
Namely, to escape all strings by putting them inside HTML tags. (I used <p> since that was their default already.)

Continued in #279


The cells are empty when the columns of the dataframe contains '.'

This issue can be reproduced as the following sample code. Whether display or editing, the cell contents are always empty.
import pandas as pd
import streamline as st
from st_aggrid import AgGrid
df_template = pd.DataFrame(
'',
index=range(10),
columns=['a.b', 'b.c', 'cd']
)
def cb(r=None):
st.write(r['data'])
with st.form('example form') as f:
st.header('Example Form')
response = AgGrid(df_template, editable=True, fit_columns_on_grid_load=True)
st.form_submit_button(on_click=cb, kwargs=dict(r=response))
st.write(response['data'])
def form_callback():
st.write(st.session_state.my_slider)
st.write(st.session_state.my_checkbox)
with st.form(key='my_form'):
slider_input = st.slider('My slider', 0, 10, 5, key='my_slider')
checkbox_input = st.checkbox('Yes or No', key='my_checkbox')
submit_button = st.form_submit_button(label='Submit', on_click=form_callback)

Same problem 😐 Any solution so far?
I found that there is a property called "supressFieldDotNotation" and it must be True, but I really don't know how to set it.

Hi, I got it! 😀
import streamlit as st
import pandas as pd
from st_aggrid import AgGrid, GridOptionsBuilder

# df is your Pandas DataFrame
gb = GridOptionsBuilder.from_dataframe(df)
gb.configure_grid_options(suppressFieldDotNotation=True)
gridOptions = gb.build()
AgGrid(df, gridOptions=gridOptions)

Hi, I got it! 😀
import streamlit as st
import pandas as pd
from st_aggrid import AgGrid, GridOptionsBuilder

# df is your Pandas DataFrame
gb = GridOptionsBuilder.from_dataframe(df)
gb.configure_grid_options(suppressFieldDotNotation=True)
gridOptions = gb.build()
AgGrid(df, gridOptions=gridOptions)

Thanks. I tried this property but got no luck. The column became uneditable. Does it work on your side?

Hi, I got it! 😀
import streamlit as st
import pandas as pd
from st_aggrid import AgGrid, GridOptionsBuilder

# df is your Pandas DataFrame
gb = GridOptionsBuilder.from_dataframe(df)
gb.configure_grid_options(suppressFieldDotNotation=True)
gridOptions = gb.build()
AgGrid(df, gridOptions=gridOptions)

Thanks. I tried this property but got no luck. The column became uneditable. Does it work on your side?

Hi, you should add this line:
gb.configure_default_column(editable=True)

Hi, I got it! 😀
import streamlit as st
import pandas as pd
from st_aggrid import AgGrid, GridOptionsBuilder

# df is your Pandas DataFrame
gb = GridOptionsBuilder.from_dataframe(df)
gb.configure_grid_options(suppressFieldDotNotation=True)
gridOptions = gb.build()
AgGrid(df, gridOptions=gridOptions)

Thanks. I tried this property but got no luck. The column became uneditable. Does it work on your side?

Hi, you should add this line:
gb.configure_default_column(editable=True)

H, thanks. It works now :) I put it in the construction by mistake.


Add Star-rating component

This PR adds Star-rating component

https://readme-components-git-fork-pranaybinju-4ececa-harish-sethuraman.vercel.app/api?component=star-rating

When we try this we are getting undefined at the place of logo it would be nice we could actually add proper fallback like (skill not found). Also would you mind writing documentation on how to use this component in the readme as well?
https://readme-components-git-fork-pranaybinju-4ececa-harish-sethuraman.vercel.app/api?component=linearprogress

done in 96498cf. Also, have updated README.md. Please do check it out and let me know your thoughts on it.

Thanks for contributing :)

Thanks for contributing :)

Welcome @harish-sethuraman . It was indeed a pleasure working on it


Is VC6 still supported?

So I have been installing various ancient SDKs for the last 7 hours and I'm down to just 2 errors! SDL wants xinput.h from the DirectX 9 SDK. I read the last version of DX9 that works with VC6 is the Summer 2004 version, but it seems to be missing xinput.h. The 2010 version of the SDK does have it, but doesn't compile in VC6. Same story with dxgi.h.
Not sure where to go from here. Maybe my info was incorrect and I need a slightly newer DX9 SDK?
I'm fairly new to this sort of thing, so sorry if I missed something obvious.

I was using the project generator.
Tried again with these zips, same two files missing: https://gist.github.com/avelican/3e7c181abc1ab6164a23bf0dba5f2756
...
...\zillalib\source\sdl\joystick\windows\sdl_dxjoystick_c.h(42) : fatal error C1083: Cannot open include file: 'xinput.h': No such file or directory
...
...\zillalib\source\sdl\video\windows\sdl_windowsvideo.c(250) : fatal error C1083: Cannot open include file: 'dxgi.h': No such file or directory
...

Got you! Sorry for the first post, I somehow misread "xinput.h" as "xaudio.h" and then was completely off...
So it turns out 15 years or so ago when I installed VC6 I somehow installed a "Windows SDK 6.0A" and set the include/library directories in Visual C++ 6 to use it. That SDK includes "xinput.h" and "dxgi.h" which compiles with VC6. Now I couldn't find that SDK 6.0A for download anymore (apparently it was part of Visual Studio 2008) but I found this thread which mentioned that the 6.1 SDK is a minor upgrade of 6.0A so that could maybe work.
I ended up a rabbit hole trying to find one of these old Windows SDK's publicly for download and I found "6.0.6001.18000.367-KRMSDK_EN.iso" on the web archive which contains the 6.1 SDK. I didn't want to run the original installer due to worrying it would break one of my existing working installations of Visual Studio so I extracted some cab files and renamed every file to their original file name and placed them into an "Include" and "Lib" directory. And VC6 didn't want to compile with them...
So I search some more and find "6.1.6000.16384.10.WindowsSDK_Vista_Feb2007Update_rtm.DVD.Rel.iso" on Microsoft's site still available which has the 6.0A SDK! So I created an V6.0A\Include directory and extract these cabs into it

WinSDKBuild-SDK_Core_BLD_Common-common.0.cab
WinSDKBuild-SDK_Core_BLD_Common-common.1.cab
WinSDKBuild-SDK_Core_BLD_Common-common.2.cab
WinSDKBuild-SDK_Core_BLD_Common-x86.0.cab
WinSDKBuild-SDK_DirectShow_BLD_Common-common.0.cab
WinSDKBuild-SDK_IE_BLD_Common-common.0.cab
WinSDKBuild-SDK_IE_BLD_Common-x86.0.cab
WinSDKBuild-SDK_IIS_BLD_Common-common.0.cab
WinSDKBuild-SDK_MDAC_BLD_Common-common.0.cab
WinSDKBuild-SDK_MSI_BLD_Common-common.0.cab
WinSDKBuild-SDK_WMI_BLD_Common-common.0.cab
WinSDKBuild-WinSDKBuild_VistaHeaders-common.0.cab
WinSDKCompiler-WinSDKCompiler_VC8CppHeaders-common.0.cab => BUT ONLY THE FILE "sal.h"

Then I created V6.0A\Lib and extracted these cabs into it

WinSDKBuild-SDK_DirectShow_BLD_X86-common.0.cab
WinSDKBuild-SDK_IIS_BLD_X86-common.0.cab
WinSDKBuild-SDK_MSI_BLD_X86-common.0.cab
WinSDKBuild-SDK_WMI_BLD_X86-common.0.cab
WinSDKBuild-WinSDKBuild_VistaLibs_X86-common.0.cab
WinSDKBuild-WinSDKBuild_VistaLibs_X86-x86.0.cab

I renamed all files from <NAME>_<EXT>.<GUID> to <NAME>.<EXT> using the excellent Siren file renaming tool, set the Include and Lib directories as the top entry in the VC6 directories options and ... it compiles again! But with some warnings... So I added this on top of WinNT.h (after #define _WINNT_):
#if (defined(_MSC_VER))
#if (_MSC_VER < 1300)
//VC6 pops warnings with new Windows SDK headers
#pragma warning (disable : 4035)
#endif
#endif

and also this on top of WinGDI.h (after #define _WINGDI_):
#if (defined(_MSC_VER))
#if (_MSC_VER < 1300)
//VC6 pops warnings with new Windows SDK headers
#pragma warning (disable : 4068)
#endif
#endif

and VC6 is happy again. To spare you the annoyance of doing all that, here's that VC6 compatible V6.0A SDK for download:
Windows_SDK_V6.0A_for_VC6.zip
Just extract it somewhere (i.e. C:\Program Files\Microsoft SDKs\Windows\V6.0A), open the Options window in VC6, go to Directories and add the V6.0A\Include path to the top of the list of Include files and the V6.0A\Lib path to the top of Library files.
 I got Hexzilla to build and run with the zip you provided.
Like you said the order of the includes is important, I had to put the V6.0A include above the VC98 include, otherwise it includes headers it can't compile.
For completeness sake, here's what I have now:
includes
C:\Program Files (x86)\Microsoft SDKs\Windows\V6.0A\Include
C:\Program Files (x86)\Microsoft Visual Studio\VC98\INCLUDE

libs
C:\Program Files (x86)\Microsoft SDKs\Windows\V6.0A\Lib
C:\Program Files (x86)\Microsoft Visual Studio\VC98\LIB

I removed MFC, ATL and February 2003 Platform SDK, and it still builds fine!
Thanks again :)


daemon: Add ingress endpoint

Add Cilium Endpoint representing Cilium Ingress. It is defined without a veth interface so no bpf programs or maps are created for it. Ingress endpoint is needed so that the network policy is computed and configured to Envoy, so that ingress/egress network policy defined for Ingress can be enforced.
Cilium Ingress is implemented as L7 LB, which is an Envoy redirect on the egress packet path. Egress CNP policies are already enforced when defined. Prior to this commit CNPs defined for reserved:ingress identity were not computed, however, and all traffic was passed through by Cilium Ingress was allowed to egress towards the backends. When the backends receive such packets, they are identified as coming from Cilium Ingress, so any ingress policies at the backends can not discern the original source of the traffic.
This PR adds a Cilium endpoint with the reserved:ingress identity, which makes the Cilium node to compute and pass policies whose endpoint selector selects this identity (e.g., by selecting all entities) to Envoy, so that they can be enforced. Envoy listener will then enforce not just the egress policy but also the ingress policy for the original incoming source security identity.
cilium-envoy support for this is added in https://github.com/cilium/proxy/pull/351, which is pulled in in this PR for testing. This PR will be updated once this cilium/proxy PR merges.
Network policies for reserved:ingress identity are now enforced by Cilium Ingress.

/test

/test

/ci-ingress

/ci-ingress

/test

/test

/test

/test

/test

/test

/test

Opened for reviews.

/test

Added Gateway API into the set of known CEC/CCEC owners that use the Cilium Ingress identity.

/test

/test

Rebased.

Separated the Gateway API fix to a commit of it's own.
Rebased and unblocked due to now using the new main cilium-proxy image.

@jrajahalme I haven't gotten to this yet, and I'm on PTO the coming weeks so I'm removing myself from the reviewer list.

/test

Also, the connectivity test will be covered soon in https://github.com/cilium/cilium-cli/issues/2015


Support DialogProps prop

I would love to keep focus on date-picker custom input after onClose or onChange handlers trigger.
I can do it manually but the issue is in animation, so I need to add timeouts which is not ideal solution.

I propose add new prop DialogProps which will be passed directly to mui dialog which will add more customization

Released in rc.13


Updated Bulgarian localization (August 2024)

This is an update on the Bulgarian localization of Ghost.

Added translation of ghost/i18n/locales/bg/comments.json
Updated translation of ghost/i18n/locales/bg/portal.json

Unfortunately, this PR has been left on hold for so long that it has become obsolete and it is wiser to open a new one.


fix multiple resove(stream)

use React\Stream\ThroughStream;
use WyriHaximus\React\Stream\Json\JsonStream;
use function React\Promise\resolve;
use React\EventLoop\Factory;
use React\EventLoop\TimerInterface;

$loop = Factory::create();
$anotherStream = new ThroughStream();
$anotherStream1 = new ThroughStream();

$jsonStream = new JsonStream();
$jsonStream->on('data', function($buffer){
    echo $buffer;
});

$jsonStream->end([
    'first',
    resolve($anotherStream),
    resolve($anotherStream1),
    resolve('third'),
]);

$i = 0;
$loop->addPeriodicTimer(1, function (TimerInterface $timer) use ($anotherStream, &$i, $loop): void {
    $i++;
    $anotherStream->write((string)$i);
    if ($i >10) {
        $anotherStream->end();
        $loop->cancelTimer($timer);
    }
});

$j = 0;
$loop->addPeriodicTimer(1, function (TimerInterface $timer) use ($anotherStream1, &$j, $loop): void {
    $j++;
    $anotherStream1->write((string)($j));
    if ($j >10 ) {
        $anotherStream1->end();
        $loop->cancelTimer($timer);
    }
});

$loop->run();

before ouput
["first","1234567891011","11","third"]

fixed after output
["first","1234567891011","1234567891011","third"]

I shall endeavor to compose a test to cover such circumstances.


iscsiadm buffer overflow with open-iscsi v2.1.2

Description
open-iscsi version 2.1.2 (version included in Flatcar from 2605.9.0) has a bug wherein discovery of too many targets results in buffer overflow in iscsiadm, resulting in the program exiting with errors. This is documented in the Changelog for 2.1.3 and this commit.
Impact
Unable to upgrade past 2605.8.0 as we have approximately 250 targets discovered which triggers the bug and then doesn't mount.
Environment and steps to reproduce

Set-up: Flatcar 2605.9.0 on bare metal
Task: Mount PVC.
Action(s):
a. Create pod utilizing PVC on a mount.
b. Container stuck in Creating due to mount failure from program exit.
Error: iscsi: failed to sendtargets to portal <IP_ADDRESS>:3260 output: *** buffer overflow detected ***: terminated                                                                                , err signal: aborted (core dumped)  (IP obfuscated)

Expected behavior
Expect successful mounting of target.
Additional information
This is really more of a request to update to at least open-iscsi version 2.1.3, but I've filed it as a bug since it technically is one (albeit in a dependency). The issue has already been found and documented as seen in the links provided in the description.
This locks us into utilizing 2605.8.0 for the time being.

Thank you for reporting this issue, and please pardon the inconvenience caused. We'll have a look at updating open-iscsi.

Thank you for reporting this issue, and please pardon the inconvenience caused. We'll have a look at updating open-iscsi.

@tilleyc for what is worth we had a similar problem when discovering luns from our netapp and managed to work around that via setting scans to manual (node.session.scan = manual) and doing targeted discoveries (which is actually the proposed configuration from trident/netapp for our case). No idea if that can be useful for you though, just mentioning.. :))

@tilleyc for what is worth we had a similar problem when discovering luns from our netapp and managed to work around that via setting scans to manual (node.session.scan = manual) and doing targeted discoveries (which is actually the proposed configuration from trident/netapp for our case). No idea if that can be useful for you though, just mentioning.. :))

@tilleyc for what is worth we had a similar problem when discovering luns from our netapp and managed to work around that via setting scans to manual (node.session.scan = manual) and doing targeted discoveries (which is actually the proposed configuration from trident/netapp for our case). No idea if that can be useful for you though, just mentioning.. :))

Interesting, thank you for this. I'll look into it!

@tilleyc for what is worth we had a similar problem when discovering luns from our netapp and managed to work around that via setting scans to manual (node.session.scan = manual) and doing targeted discoveries (which is actually the proposed configuration from trident/netapp for our case). No idea if that can be useful for you though, just mentioning.. :))

Interesting, thank you for this. I'll look into it!

This was addressed in https://github.com/kinvolk/coreos-overlay/pull/791/, that updated the iscsi version to 2.1.3.
This will be included in the upcoming set of releases for stable, beta and alpha.

This was addressed in https://github.com/kinvolk/coreos-overlay/pull/791/, that updated the iscsi version to 2.1.3.
This will be included in the upcoming set of releases for stable, beta and alpha.

The new flatcar releases with these fixes are in the process of getting published. Closing now. Thanks for reporting.

The new flatcar releases with these fixes are in the process of getting published. Closing now. Thanks for reporting.


[3.x] Fix PoolByteArray.decompress_dynamic return value and memleak

Fixes #57644

Using a pointer to construct Variant invoked the boolean constructor.
Allocated PoolByteArray was not freed.

p.s. master does not have these two problems.

Thanks!

Cherry-picked for 3.4.3.


Custom Widgets not rendered when viewing the survey.

Are you requesting a feature, reporting a bug or ask a question?
bug
What is the current behavior?
I created a survey with editor and saved the json to a database, when viewing the survey, custom widgets are not rendered. Does it have anything to do with being the json editor changed from "questions" to "elements" ? example used is barrating widget.
What is the expected behavior?
I expect that custom widgets are rendered when viewing the survey.
How would you reproduce the current behavior (if this is a bug)?
If I got the json like this with "elements" instead of questions, the custom widget will not be rendered as expected.
var survey = new Survey.Model({ elements: [  { type: "dropdown", name: "barrating1", renderAs: "barrating", "ratingTheme": "fontawesome-stars", title: "Please rate the moive you've just watched",       choices: ["1", "2", "3", "4", "5"] } ]});
Provide the test code and the tested page URL (if applicable)
Tested page URL:
Test code
your_code_here

Specify your

browser: chrome
browser version: 58.x
surveyjs platform (angular or react or jquery or knockout or vue): jquery
surveyjs version: 0.12.15

I've managed to reproduce the following behaviour:
With the
{ elements: [ { type: "dropdown", name: "barrating1", renderAs: "barrating", "ratingTheme": "fontawesome-stars", title: "Please rate the moive you've just watched", choices: ["1", "2", "3", "4", "5"] } ]}
json I've got the "There is no visible page or question in the survey." message instead of question.
With the
{ questions: [ { type: "dropdown", name: "barrating1", renderAs: "barrating", "ratingTheme": "fontawesome-stars", title: "Please rate the moive you've just watched", choices: ["1", "2", "3", "4", "5"] } ]}
json everething works like a charm.
@muhfred Can you confirm the same behaviour on your side? Or you have another issue(s)?

all questions are shown except for the custom widget.

@muhfred I've fixed issue related to the "elements" root property (fix will be available in the nearest update) and created a plunk with current dev version of survey-jquery package: https://plnkr.co/edit/tj0BfVzVkC8MidOfgjtm?p=preview
All questions are displayed correct for me.
Please feel free to modify the plunk to reproduce issue if it still not fixed.

awesome, thank you, please tell which branch I should use for pull requests, I finished a localization file for arabic.
Thanks.

@muhfred It should be the master, https://github.com/surveyjs/surveyjs/tree/master/src/localization
Thank you,
Andrew

Is the issue has been fixed in version 0.12.17? I'm just checking to make sure.

@muhfred Sure, the fixes are in the latest released version.
Thank you,
Andrew


Limited list of decks

List of user-owned decks is limited by the default API response (which returns maximum 10 resources). Allow this list to fetch more than 10 decks.

This bug is present in the annotations too; ideally the request middleware should take care of any requirements regarding the JSON:API spec.


why do you need php, npm support

Without looking at the source, my first thought going over the Readme is why do you need php? Could you not come up with a Javascript solution that doesn't have a dependency on php? This would be really nice to have as straight javascript then it could just run with only the inclusion of a js file.
Also i'm not sure how to use bower, but i am familiar with npm, it would be convenient if you could do a class npm install whichbrowser like many other modules. Which is i believe node support. This can probably just be marked as a question.

Yes, it can be done in Javascript alone, but then every visitor needs to download the complete device database which is way too large. That is why you need to do server side detection.

I made a Node.js version because I can't find any other library with this grade of detection rate. You can find it here https://www.npmjs.com/package/which-browser


Problem running Tankobon 2021.6.6

I can view help and version but if I try to add any titles, run the GUI, refresh, etc I get the same error.
File "c:\users\user\appdata\local\programs\python\python39\lib\site-packages\tankobon\models.py", line 80, in __post_init__     self.desc[lang] = localized.strip().replace("\r\n", "\n") AttributeError: 'dict' object has no attribute 'strip'
I had tried running Tankobon in the Windows Subsystem for Linux (Ubuntu) and also ran into issues. I assumed it was because of WSL so I switched to running it in Windows directly.
Is there some way to fix this? Is it just me? Thanks.

It could be related to how tankobon now treats descriptions as dictionaries, but it's strange that there are nested dictionaries. Could you paste here your index file (at ~/.local/share/tankobon/index.json.gz)?
After you upload the index file, remove it from ~/.local/share/tankobon/. tankobon should create a new empty index file and the GUI should work again.

index.json.gz
The file was long so I didn't want to paste just the contents, hopefully just pasting the file itself works for you.
You are correct though, it looks like the GUI works after removing that index. I didn't think it was the series I was adding.

I realised that the description field was being converted to a dictionary twice:
https://github.com/ongyx/tankobon/blob/94778f3075c0ca5549773b212215a7422cf26524/tankobon/sources/catmanga.py#L43-L48
https://github.com/ongyx/tankobon/blob/94778f3075c0ca5549773b212215a7422cf26524/tankobon/models.py#L76-L77
Because models.Metadata already converted the string description to a dict, and the catmanga source did not check for this, hence the nested dictionary.
Thanks for opening this issue. I'll push the bugfix as version 2021.6.7.

As for WSL2 support, tankobon's GUI should work if an X server (like vcxsrv) is running on Windows. I actually set up a Bash script that makes the WSL shell aware of vcxsrv, you can check it out in this gist.

Awesome, thank you. I can confirm that I was able to get the last few chapters now. Thanks for looking into this. I have not tried it in WSL yet but will try to give it a shot. (I do not have an X server since I've only used it for basic tasks, but that could be fun to setup).
One last, unrelated question. Are there any plans to add download limiting? I know a lot of online readers watch for fast traffic that looks like a scraper. Either way, thanks for the great work.

Yes, it's possible to rate limit. The core.Downloader class uses concurrent.futures internally to download pages, so we can control the maximum number of requests made using max_workers.
As for the 'looks like a scraper' part, tankobon deliberately obfuscates this by setting the User-Agent and Referer fields in downloader sessions.
(mangakakalot apparently blocks requests using Cloudflare if the user agent is python-requests.)

Awesome, thanks for the info. I appreciate all of the work going into this.


Add support IAM password policy expire details in table oci_identity_authentication_policy

Is your feature request related to a problem? Please describe.
1.5 Ensure IAM password policy expires passwords within 365 days
1.6 Ensure IAM password policy prevents password reuse
Describe the solution you'd like
A clear and concise description of what you want to happen.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context or screenshots about the feature request here.

As of now no api is available to get password policy expire details.


[Docs]: [Rehaul] Share Data Across Pages

@spark-c can you close this and open it on the https://github.com/appsmithorg/appsmith-docs repo please? Thanks


imdb import

Description
adding 4500 seen movies is a bit dificult, a import would be great :)
In relation to...
A component
Justification
got to many seen movies in my life
Proposed Solution
No response
Additional Information
No response

Oh, cool idea! What format are the movies exported in? There would have to be a few changes made (such as pagination as well)


Chat - Space Not Added After Emoji Selection in Composer

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Version Number: v1.4.61-0
Reproducible in staging?: Y
Reproducible in production?: N
Email or phone of affected tester (no customers<EMAIL_ADDRESS>Logs: https://stackoverflow.com/c/expensify/questions/4856
Issue reported by: Applause-Internal team
Action Performed:
1, Navigate to any chat.
2, Add emojis in the composer.
Expected Result:
Upon selecting emojis, notice that a space is not added after the emojis.
Actual Result:
After selecting emojis in the composer, a space should be added after each emoji.
Workaround:
Unknown
Platforms:

Which of our officially supported platforms is this issue occurring on?

[ ] Android: Native
[x] Android: mWeb Chrome
[ ] iOS: Native
[x] iOS: mWeb Safari
[ ] MacOS: Chrome / Safari
[ ] MacOS: Desktop

Screenshots/Videos
https://github.com/Expensify/App/assets/115492554/e3dd07eb-c84e-476b-8787-3df868206497

View all open jobs on GitHub

@garrettmknight I haven't added the External label as I wasn't 100% sure about this issue. Please take a look and add the label if you agree it's a bug and can be handled by external contributors.

This might be related to Live Markdown Preview.

We think this issue might be related to the #vip-vsb.

This might be related to Live Markdown Preview.

Yeah, or maybe also the emoji picker/keyboard issue. if so I'd much rather raise those as non-blocking issues and not revert these major PRs

I don't think this is a deploy blocker.

[!note]
I remember the exact same issue was opened 7 months ago: Chat - Space is not added after an emoji is selected

But in this case:

This might be related to Live Markdown Preview.

I think @tomekzaw might be right since there were no other major changes to the Composer recently, therefore that would be the first place I'd look at for the root cause.
Anyway the issue mentioned from 7 months ago can definitely help give more context and check some other possible root causes off the list.

It seems like this bug has been fixed in the meantime as I cannot reproduce it on current prod:
https://github.com/Expensify/App/assets/20516055/a884dc06-7235-4a94-aa4e-283417708810
There was an issue with text cursor placed incorrectly (one character earlier than it should be) when typing – perhaps this bug was another symptom?

From the OP video it looks like it wasn't just the cursor position, since there's clearly no spaces between the 3 emojis:

Just pulled latest main and I confirm that the issue is still present (consistently):

MacOS: Chrome / Safari
https://github.com/Expensify/App/assets/56457735/c57575f0-4066-4088-9967-d83e3f9ea88e

iOS: mWeb Safari
https://github.com/Expensify/App/assets/56457735/0f223563-4b2f-449d-a65f-2be1f24c1186

I looked at what's actually happening frame-by-frame and I noticed that on the first selected emoji there's actually an empty space and also a newline but shortly after selection we can notice how the Live Markdown Preview (most likely, not sure though) is formatting and removing the space and newline, leaving us with the emoji without a space (cursor right after it):

MacOS: Chrome / Safari (frame-by-frame)
https://github.com/Expensify/App/assets/56457735/bc53b64d-0fb5-410a-ad0c-ebb54566a0d9

And weirdly, it looks like the space of the first emoji is maintained on iOS: mWeb Safari (see video above) as long as the user adds emojis without focusing the Composer, but not for the subsequent emojis. The space is not maintained for the first emoji if the Composer is focused (cursor visible) when adding the subsequent emojis.
cc @tomekzaw Any thoughts ?

Indeed, the bug is reproducible on current main (8af9eae36c) but not on production 🤔

I think this issue has been already fixed in https://github.com/Expensify/App/pull/39934. I can't reproduce it on the lates main now.
https://github.com/Expensify/App/assets/39538890/eed35fce-98d9-4eef-b79d-2c318b7004cb
https://github.com/Expensify/App/assets/39538890/fc7ee020-d68d-47c5-8d3d-763e44060fc0

Fixed on staging and prod, closing.


How to update the package to add the redirection page

which redirection and where ?

the one that you upadated later.for those who have already used earlier where there was no direction option

Why not update the package bro, you will get new functionality.


Get YARP running in the Benchmark lab

We need to get YARP running in the benchmark lab (https://msit.powerbi.com/view?r=eyJrIjoiYTZjMTk3YjEtMzQ3Yi00NTI5LTg5ZDItNmUyMGRlOTkwMGRlIiwidCI6IjcyZjk4OGJmLTg2ZjEtNDFhZi05MWFiLTJkN2NkMDExZGI0NyIsImMiOjV9).

RPS vs. Response Body Size (HTTP)
| 10 Bytes | 100 Bytes | 1 KB | 10 KB | 100 KB
-- | -- | -- | -- | -- | --
No Proxy (Direct) | 706,267 | 702,534 | 652,696 | 455,617 | 253,065
Raw HttpClient | 305,749 | 307,846 | 284,828 | 218,234 | 46,033
YARP | 193,642 | 192,527 | 189,875 | 151,088 | 40,552
Envoy | 251,300 | 251,382 | 248,528 | 206,643 | 75,803
HAProxy | 385,037 | 383,118 | 368,631 | 334,647 | 49,677
NGINX | 11,841 | 13,820 | 13,179 | 42,745 | 21,945

@samsp-msft @Tratcher @sebastienros Here are some initial benchmark results of YARP vs other proxies running on our "Citrine" machines. These are all doing HTTP.
As follow up, I plan on getting numbers

using HTTPS on both the backend and frontend
with non-empty request bodies
with logging completely turned off

Don't forget to add --application.runtimeversion 5.0.* to get the latest runtime. I did this change on proxy-scenarios.yml for httpclient only today. It was using the one from the sdk, from aspnet, which is lagging by a few days.  Please add it to this file, and when you run it on the command line.

https://github.com/aspnet/Benchmarks/pull/1517/files

Hello, guys! Have you any fresh updates for performance metrics?

@sebastienros 21 pages of something looks like a lot of data but frankly unreadable in any timely manner. Is it not?

Any "understandable" chart comparing YARP on net8 vs the competition?

Switch to tab 13 "Proxies" you can click in the numbers at the bottom of the page to bring up a menu to jump with.
Pick:

Protocol: http - http or https-https (these are inbound and outbound combinations)
Payload: any
Which proxies you want to compare


change type of fInputString/fExpression from PChar to string, clearer code

… code

Sorry I do not understand what we need that for?
Inside there are still PChar processing - if looks for null-termination inside all routines.
So this change do not change the fact:
https://regex.sorokin.engineer/en/latest/faq.html#why-tregexpr-does-not-work-with-strings-with-0-inside

it is good to simplify memory management - now not needed to do GetMem, FreeMem, ReallocMem, pascal does it auto.
next step will be supporting 0 chars

year I see.
you are right.


Why return strings are iterators?

Any reason why output strings are also iterators? Why can't they just be normal JavaScript Strings?
This breaks the API of vhtml.
This is the output I've got when I console log the output:
[String: '

0

1

2

3

4

5

6

7

8

9

'] {
  [length]: 109,
  _stringjsx_sanitized: true
}

It looks more like a String instance with additional properties, and not actually a string.

I wrote about why here: https://github.com/dodoas/stringjsx/blob/11b6d223afcdff35359c5130ebdf0e60f7edba40/misc/typescript_string.md
I understand why you're saying it breaks the API but this fork was made for interacting with element.innerHtml, which accepts String objects just fine.
To summarize this fork returns String because it allows us to mark rendered strings as sanitized using the _stringjsx_sanitized attribute (which you've no doubt spotted in your output).  Such as https://github.com/developit/vhtml/issues/34, and https://github.com/developit/vhtml/issues/20.
I also knew it would break some code (it did for us, we had to put some .toString() calls in our code for a while), which is why I documented this in the changelog (which begins at the fork from vhtml) and also a little further down in the documentation.
Perhaps this information should be more prominent in the README?
I'm also curious what is breaking for you? The browsers themselves don't care whether you pass string or String, but many libraries do, and the wider javascript "community" generally considers using String to be a bad idea, so it makes a lot of sense that you would encounter some friction while using this.

Thanks for the explanation, the reason why it was breaking for me because I don't use element.innerHtml directly. I needed to change my library, but I don't remember, and I'm not able to find what I did to fix the issue. The question was asked more than about 8 months ago.


[question]

should i use prerelease or release

The current "release" from a year ago or whenever only works on Plasma 5 and is much buggier than the prerelease. If you're using Plasma 6, you have to use the prerelease. If not, there is a unmaintained prerelease 1.0b1 for Plasma 5 that may or may not work.


Are dgrams subject to congestion control?

My understanding of the RFC 9221 is that datagrams are subject to congestion control (no flow control though). However, I see that datagrams do not respect the setting quiche_config_set_initial_congestion_window_packets().
I can see the streams changing their behavior according to the congestion window size but seems like this config does not apply to datagrams.
So does quiche support congestion control for unreliable datagrams at all?

Closing as answered


[Do Not Merge] Accelerate FastAI Preprocessing

Issue #, if available:
Description of changes:

Accelerate FastAI Preprocessing
For datasets with many columns (>1000), this speeds up FastAI preprocessing by >300x when using pandas==1.5.3
While the speedup is most large using pandas==1.5.3 due to pandas having major slowdowns in several functions, it is also major using older pandas versions that are not as slow (instead of 300x faster, it is 30x faster).
This speedup can result in training time going from 1000 seconds -> 25 seconds, and inference time from 70 seconds -> 0.13 seconds. (robert dataset)
This PR additionally fixes another major bug: TabularNN time estimates were off by a factor of 128x, causing many situations where TabularNN will skip training due to thinking it will run out of time when time_limit is specified. This bug was introduced in #2395 and effects releases v0.6.1 and v0.6.2. The reason is because len(train_dataloader) switched from being train_rows/batch_size to train_rows.

TODO:

[ ] Benchmark
[ ] Create minimal reproducible example using only pandas and numpy, submit performance regression issue to pandas

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Benchmark result looks good! Pareto dominates mainline (2022_02_12 is mainline, 2022_02_14 is this PR):


Fields aren't readable when editing zone templates

PDA version
0.4.1
Python version
3.9
Steps to Reproduce
When you clock on "zone templates" and then edit a template some of the fields aren't readable. Here's a screenshot demonstrating the issue:

Expected Behavior
Fields should be viewable/readable. Ideally, the data field should be shrunk a bit to make room for the Name, Type, Status, TTL fields
Observed Behavior
The fields are smushed together. See screenshot in steps to reproduce.

I've found if you collapse the navigation it helps a little (but they're still unreadable until after you hit save)

@bab5470 we are well aware of the many styling issues the project currently has. It's just not a priority right now.


Simplex4D doesn't work anymore

Line 1350, for the constant G4 when you have done the commit about "Added compile switch to use doubles" the constant has been changed from 20 to 2.

Fix commited


i18n(fr): update cli-reference.mdx

Description (required)

Add changes from #9308 to French translation of cli-reference.mdx
Add missing space before colon for Type and Default in French translation (I also replaced Défaut with Par défaut because it seems more correct to me in French... and this is the syntax we use most often it seems).

Related issues & labels (optional)

Suggested label: i18n

Lunaria Status Overview
🌕 This pull request will trigger status changes.

Learn more
By default, every PR changing files present in the Lunaria configuration's files property will be considered and trigger status changes accordingly.
You can change this by adding one of the keywords present in the ignoreKeywords property in your Lunaria configuration file in the PR's title (ignoring all files) or by including a tracker directive in the merged commit's description.

Tracked Files

Locale
File
Note

fr
reference/cli-reference.mdx
Localization changed, will be marked as complete.

Warnings reference

Icon
Description

🔄
The source for this localization has been updated since the creation of this pull request, make sure all changes in the source have been applied.


Secrets marshaling

Add types necessary for conveniently protecting secret values and only open them in the secured runtime zone.
Example from vault.rs:
let ct = ZoneSpec::default().secure_memory().random().run(|| {
    let pt = recipient_key.as_ref().access().access(data.as_ref()).unwrap();
    let ct = (&*pt.access()).encrypt(&self.view.key, blob_id).unwrap();
    ct
})?;

So, discovered last week that we need guarded versions of Vec and String, since that's how the secrets are typed when being transported around in stronghold: since it's only when the secrets are used that they get typed as [u8; 32] and such and can be protected by a GuardedBox. This change also provoked another pass at refactoring the Protection and Access traits to be more usable. Sorry for the mess, is there a way to convert this PR back into a draft until I'm certain the types will stay?

So, discovered last week that we need guarded versions of Vec and String, since that's how the secrets are typed when being transported around in stronghold: since it's only when the secrets are used that they get typed as [u8; 32] and such and can be protected by a GuardedBox. This change also provoked another pass at refactoring the Protection and Access traits to be more usable. Sorry for the mess, is there a way to convert this PR back into a draft until I'm certain the types will stay?

Convert it back to draft for you; its up at the top next to reviewers.  Unfortunately I also took this and rebased my PR off of it, but Ill go ahead and see if I can revert some of that.

Convert it back to draft for you; its up at the top next to reviewers.  Unfortunately I also took this and rebased my PR off of it, but Ill go ahead and see if I can revert some of that.

Status update: the full flow is now working on Linux (and only minor technical issues on MacOS regarding EOF detection), so we can now review the types: how they feel and operate.
The use-case I implemented first is the communication between the internal actor and the vault. Next one I want to target is the BIP32's mnemonic sentence and passphrase: this would be a breaking change for the wallet @lucasfernog (you would have to first ask the stronghold for it's recipient public key and use it to protect the sentence and passphrase before putting it in a request).
The windows implementation should not be far behind: the guarded containers (where the compilation fails right now) only needs a corresponding guarded allocator (@tensor-programming any updates on this?).

Status update: the full flow is now working on Linux (and only minor technical issues on MacOS regarding EOF detection), so we can now review the types: how they feel and operate.
The use-case I implemented first is the communication between the internal actor and the vault. Next one I want to target is the BIP32's mnemonic sentence and passphrase: this would be a breaking change for the wallet @lucasfernog (you would have to first ask the stronghold for it's recipient public key and use it to protect the sentence and passphrase before putting it in a request).
The windows implementation should not be far behind: the guarded containers (where the compilation fails right now) only needs a corresponding guarded allocator (@tensor-programming any updates on this?).

@rootmos my allocator is mostly done, Im going to try to merge it in here and we will see if it can make the windows side work as well as the linux side.

@rootmos my allocator is mostly done, Im going to try to merge it in here and we will see if it can make the windows side work as well as the linux side.

So, managed to figure out the issue on macos:
When the value is already transferred and we only need to wait for the child process to terminate I used to use poll with the same (now empty/EOF:ed) file descriptor, reasoning that since there shouldn't come any more data on it poll essentially is just a timeout (no more POLLINs), but macos seems to retrigger the POLLHUP event in that scenario (turning the loop into a spin-lock?). The solution was to use nanosleep in this scenario to perform the waiting. I tried to remove the WNOHANG from the waitpid call, but that breaks the timeout functionality, see the added tests. I guess nanosleep is also communicates the intent in a better way, so win-win?

closed for now in favor of #155


Add a panel for browsing through aircraft

Below the "Mods" panel, it would be helpful to have another panel, something like "Aircraft" or "Skins", that lists all of the aircraft and their skins and display which ones are modded, and by which mods, and which ones are not modded.
The only thing is, this would probably need https://github.com/agc93/acevortex/blob/master/src/attributes/attributes.ts to be updated to support DLC skin slots.

Thanks for another great suggestion @Azekthi !
I've had a look at this previously and there's a few things that make this a bit difficult to implement without a significant change to how we handle skin detection. Then again, I've made a few big changes since I tried that out so I will give it another shot.
I'll give this a try, but no guarantees!

Yeah, that makes sense. The data would have to be stored somewhere outside of just the text field in the installed mod. It's no big issue, but it would be supremely helpful to have a single place to see all of it, outside of just launching the game xD

Couple of things now that 0.2.0 is out:

Thank goodness, indeed all of the skins I had installed are now properly detected! Except... just one, right now. Gripen E -Wisna- comes with two files, one for the MREC and one for the livery. Both need to be installed so the proper camo pattern appears in all lighting conditions, but the skin detection in acevortex is seeing this as two skins in the same mod slot. In my example, I've installed them on the Erusea skin.

NPC skins are also showing. Is this intentional? If so, maybe we could set this up a little better, like pushing them to the bottom of this list?

Huh. Never seen a mod distribute the MREC as a separate file. I can fix that up by just ignoring MRECs for now.
As for NPCs, that is intentional, but I'm probably going to make it either a) a toggle or b) a separate section

@Azekthi Alright version 0.2.1 has made its way through the process and should be available now.
All the details are in the release notes but the Gripen situation should be fixed and I've tweaked the Skins view to push NPCs to the bottom and allow toggling them off entirely (purely a visual toggle)

Doing good, doing good! We're almost there :D
I've got a few remaining mods where the skins aren't being detected:

https://www.nexusmods.com/acecombat7skiesunknown/mods/159
https://www.nexusmods.com/acecombat7skiesunknown/mods/379
https://www.nexusmods.com/acecombat7skiesunknown/mods/380
https://www.moddb.com/games/ace-combat-7/addons/su-30m2-experimental

And I've also got this mod adding a new aircraft to the Skins page: "W" https://www.nexusmods.com/acecombat7skiesunknown/mods/453/
Other than these, and the one thing about the NPC toggle not saving between Vortex sessions (maybe change it to a setting?) I think it's looking good :D

I'll look into those mods, but I will say that we might never get to 100%.

Other than these, and the one thing about the NPC toggle not saving between Vortex sessions (maybe change it to a setting?) I think it's looking good :D

That's a deliberate choice.  If I get any more feedback about that and/or requesting it be persisted, I'll change it over.

and sure enough, we've found the "never reach 100%" mark: that Avril F-104 skin is packed with an extremely old method and handling how its done would break detection for a big chunk of other mods.
The weapon mod being identified is definitely a bug but I can fix that up easy enough. As for those Oryol, Stalker and Experimental skins, they all work fine for me. Can you Refresh Skins on those mods and see if it picks it up? The skins are only detected on first install so after that you need to manually refresh them.

I will say that we might never get to 100%

Oh, of course not, there will definitely be edge cases, especially old skins. Doesn't surprise me that that mod, how old it is, isn't working. No worries!
I'm curious if we might be able to have a manual override for the skins? It might help for the skin organization in the Skins page.

That's a deliberate choice.

Ah, fair enough!

As for those Oryol, Stalker and Experimental skins, they all work fine for me. Can you Refresh Skins on those mods and see if it picks it up? The skins are only detected on first install so after that you need to manually refresh them.

I only reported them because Refresh Skins isn't working for these mods.

I'm curious if we might be able to have a manual override for the skins? It might help for the skin organization in the Skins page.

It's not planned at this time (that would be quite a bit of work and would be very easy for a user to get wrong with how its currently designed), but as always if I get more feedback/demand I'll add it to the backlog.

As for those Oryol, Stalker and Experimental skins, they all work fine for me. Can you Refresh Skins on those mods and see if it picks it up? The skins are only detected on first install so after that you need to manually refresh them.

I only reported them because Refresh Skins isn't working for these mods.

Okay can you raise a separate issue for those then and include links to mod reports (right click mod in Mods list > Create Report > Share) for whichever ones aren't working? I can't reproduce it on my end (they get picked up just fine) so will need to investigate them separately.


Create Kris's S DRIVE

What's changing?
How's this tested?
Closes [related issues]

What's changing?
How's this tested?
Closes [related issues]

Please I was on call the that who the responds delayed


Bypass CVV and Expiration required validation

General information

SDK version: v2 Hosted Fields
Environment: Any
Browser and OS: N/A

Issue description
We are now excepting Maestro cards which some do not have CCV or expiration.
Our sandbox and production environments do not require CCV or AVS validation, but we are not able to submit the transaction without receiving a 'Some payment method input fields are invalid.' message.
Is there a setting to make the CVV and expiration not required?
Or a way to bypass this validation?

Can you provide more information about this? It's my understanding that Braintree requires expiration dates for all credit card transactions.
You can set up hosted fields without a cvv, however. Just leave the cvv option out of the setup options.
There are some Maestro debit cards that do not contain a cvv or expiration date, but those cannot be used for online transactions.

I might have bad information from our client on the expiration date.
What if it is unknown at setup if the customer will be using a Maestro card?
Is it possible to make CVV dynamic after setup?

There is currently no way to dynamically turn on and off the cvv field. You can teardown hosted fields and set it up again without CVV, but not collecting cvv can result in more declines.
My guess is that your client is mistaken about the need to not collect CVV. I'm going to close this for now, but comment here if you find out additional information and I can re-open the issue.


Facade name collision with existing package

I'm trying to install Sentry on a Laravel 5 project but I'm already using Cartalyst Sentry for user authentication - which has an existing facade for "sentry." Is there a workaround for this?

My personal opinion is "this isn't our problem". I think you can use app('sentry') instead of the Facade, but maybe I'm wrong. Either way, I have no desire to cater to other people using the Sentry name for their own projects, especially since it dates back so far (and potentially we have trademark law on our side).

If it's not clashing in the IoC container (so app('sentry') is not the issue) people can simply change the facade name in their config files.
    'Sentry' => Sentry\SentryLaravel\SentryFacade::class,

To:
    'SentryTracker' => Sentry\SentryLaravel\SentryFacade::class,

Or something like that (you could also use Raven as facade / IoC name).
Although looking at their (depracated) code on GH it is clashing in the IoC container. The only way around that is renaming Sentry in the IoC container (for this package or the cartalyst one 😉 ).
Possibly using sentry.raven is an solution since that would not clash with a package using raven as IoC binding I believe.

@stayallive thanks! fwiw we intend to completely remove "Raven" from the history books (too confusing to users)

@dcramer the using "Raven" is a terrible idea :P But no idea what would be nice to use instead then.

I'm having this issue which is also stopping me using Sentry on an old Laravel 4 project that uses Cartalyst's package namespacing too. I actually took the service provider and botched it to use a new Facade called "Sentryerrors" instead, but alas this isn't working. Any idea how I can use my own provider to make this work? I love Sentry and desperately need error logging for this app :)

You should be able to copy the facade and service provider into your own application like this: https://gist.github.com/stayallive/2adc8a92aaa64ca5427f50141f715561
And add this Facade instead of the one in the docs:
'SentryErrors' => App\Support\SentryFacade::class,

And add this ServiceProvider instead of the one in the docs:
App\Support\SentryServiceProvider::class,

Also the config file is renamed to sentry-laravel.php in the gist above so you should rename the config file if it was already created.
Note: this code is untested and you might want to adjust the namespaces to suit you application.

So far I've created a custom Facade that returns sentryerrors too but to no avail :)

Yes, this won't work since the service providers registers Sentry under a different key, the Facade is just a shortcut. Check out the gist and look at the original service provider next to it you will see what is happening 😉

I got so close and yet felt so far, but you completed the journey, you're my Samwise Gamgee! Thanks @stayallive :)

You could also just extend our provider right?
class SentryCompatServiceProvider extends SentryLaravelServiceProvider

If so maybe we'll consider offering this as part of core as an alternative configuration, but not the default/recommended.

That is possible yes. However you still need to copy over much code. Maybe add a property that indicates the IoC key used (or maybe that was wat you ment already xD)? Although the same trick is not possible for the facade, so you either need to make your own facade or use none at all.
--
Met vriendelijke groet,
Alex Bouma
On 12 Jul 2016, 22:00 +0200, David<EMAIL_ADDRESS>wrote:

You could also just extend our provider right?
class SentryCompatServiceProvider extends SentryLaravelServiceProvider
If so maybe we'll consider offering this as part of core as an alternative configuration, but not the default/recommended.
—
You are receiving this because you were mentioned.
Reply to this email directly,view it on GitHub(https://github.com/getsentry/sentry-laravel/issues/24#issuecomment-232161724), ormute the thread(https://github.com/notifications/unsubscribe/ABCkwtN44I9MIBQoJBWccIOc4ccamvpvks5qU_JrgaJpZM4JJoz4).

I think having a protected property on the service provider and referring to that would be a great way to start. You could perhaps provide a second facade for alternative naming and as a result, then an extended service provider so people don't even need to create their own and could instead reference something like
SentryCompatServiceProvider

instead. Just a thought, but thanks for all the help :)

If you would provide a extra service provider with changed naming I would say just change it in the main one. Two service providers is probably going to cause more confusing than it is solving.

One caveat about my fix: I didn't change the name of the config file, which means that both this Sentry and Cartalyst Sentry will need to store data in config/sentry.php.  This is obviously far from ideal.  Does it make sense to change the config key as well?
In addition, the logic for binding the user context will fail unless you have created a (Cartalyst) Sentry driver for the Laravel authentication mechanism.  Mine is very simple, and based on this:
https://github.com/Malezha/sentry-auth-laravel (adapted for L5).  This allows e.g. $app['auth']->user() to work.  Then, you also have to implement the getAuthIdentifier() method on your User model.

@hackel IMHO I think that is probably a good idea to keep the config key "in sync" with the IoC registered key.
And the binding of the user context will fail but it is only an example, so you can implement however you see fit (it is also not included in this package only in the docs) so if you use Cartalyst Sentry you can adapt the example to work with their Auth facade or user resolver thingy.

@stayallive Agreed, I updated it to use the $abstract property as config file name as well.

Looks like this is fixed by you in #39 🎉


Document Return Value for Upload

Improve documentation
Link
https://supabase.io/docs/reference/javascript/storage-from-upload
Describe the problem
It was not clear what the return value of the upload function was. I ended up logging it to the console then I was unsure what exactly I should use as the path for the download function.
It is also unclear to me why the bucket is included in the returned Key/path if it is added automatically in the download function.
I was most concerned that if a user had uploaded to a specific folder/subfolder then they could not just take the last piece, they would have to remove the bucket name and first slash every time they wanted to use the download function. (Consider that in most cases, at least in my case, the return value of the upload function is immediately stored in a table/row and then used later to download.)
Describe the improvement
The minimum improvement is explicitly stating on the website that the upload function returns {Key: string} where the Key is a path that includes/is prefixed with the bucket (as made evident after looking at the code in this library). It also needs to be explicitly stated the the download function does not accept this bucket prefix and it must be removed when passing the path parameter.
It would be even nicer if the upload function returned an additional key/property (so that the Key property remains unchanged for backwards compatibility) that returns just the download path (without the bucket) and a separate property for the bucket if desired. The Key property can stay unchanged.
This would reduce confusion and developers would not have to parse/split/trim/format the returned value when storing it or using it to download the file.
Additional context
The original context at which I arrived at this issue was: I was uploading a profile picture to the avatars bucket detailed in the nextjs-ts-user-management example and was storing the returned path in the avatar_url column and then rendering the user profile but I was using the returned Key.

:tada: This issue has been resolved in version 1.8.0-next.1 :tada:
The release is available on:

GitHub release
npm package (@next dist-tag)

Your semantic-release bot :package::rocket:

Closing as this is fixed on V2-rc, thanks for raising the issue!


added check for uppercase letters in command option names

check for uppercase in option names
About
This pull request fixes an issue where when a user creates an option name with an uppercase letter, an unhelpful error shows up.
Checklist

[ ] I've ran pre-commit to format and lint the change(s) made.
[x] I've checked to make sure the change(s) work on 3.8.6 and higher.
[x] This fixes/solves an Issue.

(If existent):

[x] I've made this pull request for/as: (check all that apply)

[ ] Documentation
[ ] Breaking change
[ ] New feature/enhancement
[x] Bugfix

Also use conventional commits

Also use conventional commits

SHHHHHH

A check for uppercase command names already exists.

This is for option names

Use regex to check if the name is valid, since no uppercase letters and no symbols are allowed with the exception of - and _. There was some check using regex in v3, by the way. Don't just check for uppercase!

No need to take code from there when we have copilot to do regex for me :D

You know fl0w is gonna kill you if he finds some copilot comments, right?

Use regex to check if the name is valid, since no uppercase letters and no symbols are allowed with the exception of - and _. There was some check using regex in v3, by the way. Don't just check for uppercase!

No need to take code from there when we have copilot to do regex for me :D

You know fl0w is gonna kill you if he finds some copilot comments, right?

You know copilot wrote the whole pr right?

not funny at all imo, do it yourself or don't do it.

GitHub copilot pull-request, not mergeable imo.

I sound annoyed and I'm gonna rewrite it with regex anyways but did you genuinely want me to rewrite it by hand.

@Dworv Yes, you should probably write something that indicates you dedicated some genuine effort into it

Copilot is like copy and pasting code from stackoverflow instead of optimizing a solution yourself because "it's easier."
Writing code yourself is going to show that you've put in effort, and not by using an AI.


Make /reference/terraform.html more useful

This website's #2 search term is "pulumi vs terraform"

which apparently ends up landing folks on the /reference/terraform.html page

which is not terribly helpful. We should improve this page.

Fixed by #566


Add Distinct method and tests

https://docs.microsoft.com/en-us/dotnet/api/system.linq.enumerable.distinct?view=netframework-4.7.2

I could also do this!

Done in #43

:(

Sorry mate, I already started it before seeing your comment!!


AB tags don't accumulate

I just opened the SGF file http://lifein19x19.com/forum/download/file.php?id=2310 in Sabaki 0.30.0, and many Black stones are missing from the initial position (you can see the file displayed in Eidogo at http://lifein19x19.com/forum/viewtopic.php?p=119544#p119544).
Studying the SGF file, my guess is that the second AB tag (containing only [ic]) is blowing away the first AB tag (containing [pp][pn][qq][pj][pd][fc][db]) instead of adding to it. I looked briefly at the SGF spec but couldn't tell whether AB tags are supposed to accumulate or replace earlier ones. In any case it seems that at least one other program (the file says it was created with MultiGo) assumes that they accumulate. I believe that I have opened the file in CGoban before and it loaded as intended.
Presumably this is the case with AW tags as well.

Strictly, the SGF is faulty, there should be zero or one AB tags in the node, never two. But concatenating the lists would be reasonable, if possible...

Looking at the preact branch, in _parseTokens() there is this:
node[id] = []

I suspect if this became:
if (node[id] === undefined) {
    node[id] = []
}

That might be good enough...


Master to PostgreSQL version 15

** PLEASE DO NOT MERGE ** until thoroughly reviewed and approved by all reviewers. Reviewers must state their approval as a comment in the thread below. Additionally, this merge needs to be appropriately squashed before merging.
PR for moving the master branch up to PostgreSQL version 15.
It contains all of the latest work in the master branch in addition to all of the changes made to go from PostgreSQL version 14 to 15. When this PR is merged the master will be the latest and on PostgreSQL version 15.
Everyone listed as a reviewer needs to review this PR

Looks good to me.


deps: update to<EMAIL_ADDRESS>

Closes #3443

Should this be a master branch commit?

Makes sense.


feat(linter): anchor-is-valid for eslint-plugin-jsx-a11y

try to implement anchor-is-valid for #1141

Currently, I have implemented the base; the remaining work will be done when polymorphic components are supported.


('Connection aborted.', OSError(89, 'Function not implemented')) in version 2.13.0

Version 2.13.0 request.get() function thrown an exception with the message,
('Connection aborted.', OSError(89, 'Function not implemented'))
Reverting to version 2.12.5/4 resolved the issue.
Python Version: 3.5.2
OS: entware ng on asuswrt

Could you provide a full traceback? Or some kind of reproduction code? Are you running with gevent/eventlet? Do you have PyOpenSSL installed?
I have a theory, and my theory is that the Python you have on entware-ng is exposing one of the more complex selector syscalls (hard to know which because I can't see what OS entware considers to be its base, but it could easily be poll, if not epoll or kqueue), but does not actually support it.
It'd be really nice to get a whole traceback, but if you can't do it can you show me what selectors are present? That is, in a Python shell, run:
import select
print(select.select)
print(select.poll)
print(select.epoll)
print(select.kqueue)

To be frank, I'm not a Python dev and is currently facing this issue while using Flexget. The code in Flexget that triggers the exception is,
response = requests.get(self.base_url, params=params)

I've run the command you mentioned above and the result is as follow,
Python 3.6.0 (default, Feb 17 2017, 13:43:51)
[GCC 5.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import select
>>> print(select.select)
<built-in function select>
>>> print(select.poll)
<built-in function poll>
>>> print(select.epoll)
<class 'select.epoll'>
>>> print(select.kqueue)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: module 'select' has no attribute 'kqueue'

I'll be happy to perform whatever tasks you ask of me to resolve this issue.

Ok, so poll and epoll seem to be the problems there. Do you mind running this Python code quickly?
import socket
from requests.packages.urllib3.util import wait

s = socket.create_connection(('httpbin.org', 80))
print(wait.wait_for_write([s])

Here's the result. Seems like we're on the right track,
Python 3.6.0 (default, Feb 17 2017, 13:43:51)
[GCC 5.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import socket
>>> from requests.packages.urllib3.util import wait
>>> s = socket.create_connection(('httpbin.org', 80))
>>> print(wait.wait_for_write([s])
... )
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/opt/lib/python3.6/site-packages/requests/packages/urllib3/util/wait.py", line 40, in wait_for_write
    return _wait_for_io_events(socks, EVENT_WRITE, timeout)
  File "/opt/lib/python3.6/site-packages/requests/packages/urllib3/util/wait.py", line 22, in _wait_for_io_events
    with DefaultSelector() as selector:
  File "/opt/lib/python3.6/site-packages/requests/packages/urllib3/util/selectors.py", line 364, in __init__
    self._epoll = select.epoll()
OSError: [Errno 89] Function not implemented

Aha, ok, so we're getting there. An explanation:
Requests, when using PyOpenSSL, needs to implement some logic to do non-blocking I/O. We do this by looking for the best available selector on the platform and using that. We check for the available selectors by looking at which names are defined in the select namespace.
It seems that this Python distribution is defining the epoll selector, but cannot actually use it. This is probably because the underlying OS defines the epoll syscall but cannot actually use it, and returns ENOSYS.
Now, we can work on this by extending our selectors module to actually attempt to create a selector on startup and looking to see if that works (/cc @SethMichaelLarson), but in the short term you can resolve this by running a small monkeypatch just after you import requests.
In your code, if you add:
import requests.packages.urllib3.util.selectors
requests.packages.urllib3.util.selectors.DefaultSelector = requests.packages.urllib3.util.selectors.SelectSelector

Before you start running your main code, that should re-introduce the older behaviour. If poll works on your OS, you may want to use PollSelector instead of SelectSelector.
Longer term, you should consider reporting a bug upstream to suggest that they remove the definitions for syscalls that don't actually work on their platform: I imagine they'll run into trouble elsewhere.

Ok, thanks.
I'm not so familiar with Linux so who should I be reporting this issue to?

Firmware dev (http://asuswrt.lostrealm.ca/), or
Entware NG dev (https://github.com/Entware-ng/Entware-ng)

Entware is installed onto the firmware (I don't even know my sentence is correct or not). Then via Entware's opkg exec, I installed Python3.

I would guess that the firmware developer is the place to go. One thing that might be useful information to provide the firmware developer, if you can, is a copy of the Python script I wrote you above (the one that calls wait_for_write) along with the strace output that produces. It should show the epoll syscall failing.

Ok, thanks for the help.

@Lukasa, while I think this should be closed (since it's not a Requests bug), I also wonder if the selectors code in urllib3 should attempt to fallback to less efficient methods in cases like this and only then let the OS error bubble up. Thoughts?

@sigmavirus24 Yeah, so I said a few comments ago that the selectors module can detect this case by actually trying to instantiate the selectors, at least for some of them where the selector itself is an FD (we can't do it so easily for poll/select). That's why I tagged @SethMichaelLarson: this is a bit his baby.

I clearly need to finish my coffee before commenting. =)

Fix for this is coming within shazow/urllib3#1128. Basically when determining what DefaultSelector should be we'll attempt to allocate a single object in addition to checking whether select advertises the service if using non-select.select selectors. I would hope most firmware developers would not advertise select.select if it's not available because it's much more of a drastic difference from a usual platform.


Error page in case perform transaction

Describe the bug
Error page in case perform transaction
To reproduce the bug
Steps:

Perform transaction Earning(Stake, Stake more, Unstake, Send fund)
Observe the displayed screen

Actual: Error page

Expect: Navigate to Confirmation popup

Version test:
Validation passed in case:

Transfer
Earning: Stake, Stake more, Unstake, Cancel unstake


Kubernetes workflow to update kubernetes secrets from GitHub

From issue https://github.com/eddiejaoude/stargate/issues/72#issuecomment-799640072

update kubernetes workflow to update secrets from GitHub

export TMP_SECRET_YAML_FILE=secret.yaml
kubectl create secret generic discord-bot-secret --from-literal=DISCORD_BOT_TOKEN=${{ secrets.DISCORD_BOT_TOKEN }} --dry-run -o yaml > $TMP_SECRET_YAML_FILE
kubectl apply -f secret.yaml
rm $TMP_SECRET_YAML_FILE

document how to create a new secret on kubernetes

What exactly do we want to do here ?
Just add a document on how to create secret on K8s ?

Here is what I think we have to do

[ ] make a github action which runs on some interval eg: every 24 hours or anytime a secret is changed(I don't know if there is a trigger like this)
[ ] extract the secret token from github secrets
[ ] make a secret.yaml file which will create a kubernetes secret
[ ] apply these changes of secrets using kubectl
[ ] remove the secret.yaml file to avoid leaking of secrets

Is this right?

Thank you for collaborating.

[ ] I think the simplest solution, is for it to run in an existing action every time. It can be appended to this section https://github.com/eddiejaoude/stargate/blob/main/.github/workflows/docker.yml#L70
[ ] then add documentation on how to add another secret, as there could be multiples

I learnt this from Sid. @sidpalas do you have a video on this on your YouTube channel?


feat: scoping for references to own static members

Closes partially #540
Summary of Changes
Member accesses to

own static attributes,
own nested classes,
own nested enums,
own static methods,
enum variants

are now resolved properly.

:tada: This PR is included in version 0.2.0 :tada:
The release is available on:

Visual Studio Marketplace
GitHub release

Your semantic-release bot :package::rocket:


Resource path is wrong

Currently your decompiler added "s" for all resource types on when making resource dir
https://github.com/REAndroid/ARSCLib/blob/bb46abb499a1604c5675aeba3d12b7ca58ab007c/src/main/java/com/reandroid/lib/apk/ResFile.java#L145
It not good. We must a store standard path like menu, drawable, xml, raw etc.

It was right before some commit, I don't remember why I messed it up.
Now it is fixed with this


V100 PCIE FP16 PS/worker training data corruption bug occurs when distributed over gRPC

System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow): tensorflow/benchmarks:cnn_tf_v1.12_compatible
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 16.04-hwe
Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device: N/A
TensorFlow installed from (source or binary): binary
TensorFlow version (use command below): ('v1.12.0-0-ga6d8ffae09', '1.12.0')
Python version: 2.7.12
Bazel version (if compiling from source): N/A
GCC/Compiler version (if compiling from source): N/A
CUDA/cuDNN version: 9.0/<IP_ADDRESS>-1+cuda9.0
GPU model and memory: V100-PCIE-32GB, NVIDIA driver version 384.145, with intel_iommu=on

$ cat /proc/cmdline
BOOT_IMAGE=/boot/vmlinuz-4.15.0-38-generic root=/dev/mapper/vgroot-lvroot ro intel_iommu=on

$ nvidia-smi topo -m
	GPU0	GPU1	GPU2	GPU3	CPU Affinity
GPU0	 X 	PIX	NODE	NODE	0-9,20-29
GPU1	PIX	 X 	NODE	NODE	0-9,20-29
GPU2	NODE	NODE	 X 	PIX	0-9,20-29
GPU3	NODE	NODE	PIX	 X 	0-9,20-29

Legend:

  X    = Self
  SYS  = Connection traversing PCIe as well as the SMP interconnect between NUMA nodes (e.g., QPI/UPI)
  NODE = Connection traversing PCIe as well as the interconnect between PCIe Host Bridges within a NUMA node
  PHB  = Connection traversing PCIe as well as a PCIe Host Bridge (typically the CPU)
  PXB  = Connection traversing multiple PCIe switches (without traversing the PCIe Host Bridge)
  PIX  = Connection traversing a single PCIe switch
  NV#  = Connection traversing a bonded set of # NVLinks

Describe the current behavior
FP-16 multi-GPU training with CPU as local parameter server is converging in single process mode, but diverging loss value (nan) adding another loopback PS process with grpc. Consistent behaviours for both ResNet-50 and VGG16.
Describe the expected behavior
The same training procedure should yield exactly same result using only 1 worker with/without 1 PS. Not sure why adding SendRecvOps causes data corruption. See other info below.

Detailed log could be found here.

I will try on one of our NVLink machines to see if the problem remains.

I will try to reproduce this problem on one of our NVLink V100-SXM2 machine.

The erroneous device has non-identity DMAR mapping, as shown in the kernel log:
DMAR: 32bit 0000:1b:00.0 uses non-identity mapping

Disabling IOMMU temporarily resolves this issue.
I am still wondering though, as it seems distributed runtime triggers GPU P2P transfer even with CPU as local PS, but the same error does not occur in local training. Is this behaviour intended?
@poxvoculi Paul, is there anything you feel similar here?

Byron,  we'll try to take a look at this before long, to see whether we can reproduce.
What do you mean by "it seems distributed runtime triggers GPU P2P transfer even with CPU as local PS"?  Are you seeing memcpy's direct between GPUs?  A lot of strange optimizations have been done to the TF CNN benchmark suite, so it's possible some kind of cross-device ops are intentionally done even in the CPU-as-ps case.

Patching the latest firmware resolves the issue completely. I will leave it here and hope it could be helpful if someone else meet the same problem.

Thanks a lot Byronyi! We will try this for our 8x Titan V, SuperMicro 4029GP-TRT Server. It shows very similar issues with the PIX connections.

And it worked! :)


feat(nextjs): Add nextjs template and small readme pointing to a full…

… guide
Adds nextjs a popular framework for enabling React based web applications functionalities such as server-side rendering and generating static websites.
Let me know if this is helpful and I will add more web frameworks

Hey @boz , any chance ofreview ? Would like to test this out in Akashyltics app

Didnt see this originally
Added a top level item with a new web framework section :D
@boz

@boz Can we merged this ser? Responded to review


Timber OSX fixes

These are the changes I think should fix some of the problems encountered here on Timber OSX.
The first and the third commits are obvious.  They fix: warning: comparison between signed and unsigned integer expressions (there is one exception, I can't locate the bug in test_fill) and test_scatter_if fail.
The second and the forth commits should fix test_extrema fail and test_reduce_by_key fail. I think SIGABRT may be caused by the wrong barrier usage (my mistakes; see commits ). It's hard to see those bugs, because they don't show up and don't have any side-effect on most of the GPUs (I'm sure about AMD GPUs with official AMD APP and drivers). I hope they'll help with Timber OSX.

Unfortunately, links to test fails stopped working yesterday. I don't know if this is a temporary situation.

Thanks for fixing these! Yeah, the test runners seem to be turning over again. Hopefully there will be a new build soon.

There was a new build and my fixes worked. I'll do more if I get more free time ;)


Add Tooltip rerouting

Tooltips don't reroute to according statistics.

Work on this can only be started once #99 is successfully closed

Work on this can only be started once #99 is successfully closed


how to map >> Map<String, BigDecimal> in java using "@ApiModelProperty"

Note: "[ equals to <"         and       "] equals to >"
Actually i want to map "Map of [String, BigDecimal]" property using " @ApiModelProperty" to generate it right in swagger.json file,
i did it as:
@ApiModelProperty(name  ="Data", notes = "Data", dataType = "Map[string,string]")
public Map[String, String] getData() {
return data;
}
and i got this in swagger.json file
"Data": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
but i think this mapping is wrong, am i right?
and if this is wrong, what should i do?
thanks

Please open the issue on swagger-core.


Add Sodium Issue #1016 Fix mod

Add Sodium Issue #1016 Fix mod

This list is for server side mods, sodium fix is a client side mod


Memory leak: Async directives hold onto full DOM trees

Description
A few of the first-class Promise directives hold onto their parts (and the part's nodes). I didn't think this was too serious at first, until I thought about the DOM trees they're holding onto.
Eg:
// Let's call this the Page 1 UI.
render(html`

  ${until(promise1, 'foo')}

`, container);

Here, we know there'll be a
foo
 rendered inside the container. But we've chained off of promise1, and that chain holds the part's startNode and endNode. Those nodes hold every other node in the tree, either directly or indirectly. Imagine this until directive was somewhere deeply nested under container.
Now image we change to a different template on the same container:
render(page2Ui, container);

Here we've completely wiped away that other templates DOM tree. But actually, no, we haven't. until is still holding on to everything rendered under that container until promise1 resolves.
Ideally, we'd use the disconnect API clean up. We could have these Promise awaiting directives use a Promise.race:
Promise.race([disconnect, userValue]).then((resolvedValue) => {
  part.setValue(resolvedValue);
  part.commit();
}, () => {
  // disconnected
});

Now, when the part is disconnected (either because a parent node disconnected, or because the part updated do a different value), we can reject the disconnect promises. When the chain settles, the reference to the part will be cleaned up.
Test Case
test('holds DOM tree after disconnect', async () => {
  let resolve1: (v: any) => void;
  const promise1 = new Promise((res, _) => {
    resolve1 = res;
  });
  render(html`<div>${until(promise1, 'foo')}</div>`, container);
  assert.equal(stripExpressionMarkers(container.innerHTML), '
foo
');
  const text = container.firstElementChild!.firstChild!.nextSibling as Text;
  assert.equal(text.data, 'foo');

  // Render a different template over container, so everything is "freed".
  render(html``, container);
  assert.equal(stripExpressionMarkers(container.innerHTML), '');

  resolve1!('bar');
  await promise1;

  // Do not allow commits after a disconnect
  assert.equal(text.data, 'foo');
});

Expected Results
First class directives should make it easy to avoid memory leaks.
Actual Results
Memory leaks are easy.
Browsers Affected

[x] Chrome
[x] Firefox
[x] Edge
[x] Safari 11
[x] Safari 10
[x] IE 11

We have a directive disconnect API in lit-html 2.0


Support an unencrypted encryption scheme

Type of change
Select the type of your PR

Bugfix
Enhancement / new feature

Description
Changes the kekSelection contract so that the KekSelector can mark a record as un-encrypted.
Additional Context
Checklist
Please go through this checklist and make sure all applicable tasks have been done

[ ] Write tests
[ ] Make sure all tests pass
[ ] Review performance test results. Ensure that any degradations to performance numbers are understood and justified.
[ ] Make sure all Sonar-Lint warnings are addressed or are justifiably ignored.
[ ] Update documentation
[ ] Reference relevant issue(s) and close them after merging
[ ] For user facing changes, update CHANGELOG.md (remember to include changes affecting the API of the test artefacts too).

I think the output of the conversations around https://github.com/kroxylicious/kroxylicious/pull/774 is that 774 represents a better starting point for fixing the null handling but a version of this idea could be the final solution to conveying the state.