when trying to update records of my table it is giving me these errors

First Check

[X] I added a very descriptive title to this issue.
[X] I used the GitHub search to find a similar issue and didn't find it.
[X] I searched the FastAPI documentation, with the integrated search.
[X] I already searched in Google "How to X in FastAPI" and didn't find any information.
[X] I already read and followed all the tutorial in the docs and didn't find an answer.
[X] I already checked if it is not related to FastAPI but to Pydantic.
[X] I already checked if it is not related to FastAPI but to Swagger UI.
[X] I already checked if it is not related to FastAPI but to ReDoc.

Commit to Help

[X] I commit to help with one of those options 👆

Example Code
This is the user class which is making my routes, I am getting errors in my Put method. My function update has issues and I was following this on youtube by bitfumes.

from fastapi import APIRouter,Depends,status,HTTPException
from  MerchantRegistration import models,database,hashing,schemas,oauth2
from sqlalchemy.orm import Session
from typing import List
from repository import user

router=APIRouter(
    prefix="/user",
    tags=['Users']
)

@router.get('/', response_model=List[schemas.ShowUsr])
def all(db:Session=Depends(database.get_db),current_user:schemas.UsrBase=Depends(oauth2.get_current_user)):
    users=db.query(models.User).all()
    return users

@router.post('/',status_code=status.HTTP_201_CREATED,response_model=schemas.ShowUsr)
def create(request:schemas.UsrBase, db:Session=Depends(database.get_db)):
    Lst_of_users= models.User(user_name=request.user_name, f_name=request.f_name,
                             l_name=request.l_name, email=request.email, phonenumber=request.phonenumber,
                             companyName=request.companyName, websiteURL=request.websiteURL, password=hashing.Hash.bcrypt(request.password)
        )

    db.add(Lst_of_users)
    db.commit()
    db.refresh(Lst_of_users)
    return Lst_of_users

@router.put('/{id}',status_code=status.HTTP_202_ACCEPTED,response_model=schemas.ShowUsr)
def update(id:int,request:schemas.UsrBase,db:Session=Depends(database.get_db)):

    print(id)
    usr = db.query(models.User).filter(models.User.user_id == id)
    print(usr)
    if not usr.first():
        raise HTTPException(status_code=status.HTTP_404_NOT_FOUND,
                            detail  = f"User with id {id} is not available ")
    usr.update(request)
    db.commit()
    return 'done'

@router.delete('/{id}',status_code=status.HTTP_204_NO_CONTENT)
def destroy(id,db:Session=Depends(database.get_db),current_user:schemas.UsrBase=Depends(oauth2.get_current_user)):
    usr=db.query(models.User).filter(models.User.user_id == id)
    if not usr.first():
        raise HTTPException(status_code=status.HTTP_404_NOT_FOUND,
                            detail=f"User with id {id} is not available ")

    usr.delete(synchronize_session=False)
    db.commit()
    return 'done'

@router.get('/{id}',response_model=schemas.ShowUsr,status_code=200)
def get_user(id,db:Session=Depends(database.get_db),current_user:schemas.UsrBase=Depends(oauth2.get_current_user)):

    user=db.query(models.User).filter(models.User.user_id == id).first()
    print(user)
    if not user:
        raise HTTPException(status_code=status.HTTP_404_NOT_FOUND,
                            detail = f"User with id {id} is not available ")
        # response.status_code=status.HTTP_404_NOT_FOUND
        # return {"detail" : f"User with id {id} is not available "}

    return user

My model is below

from sqlalchemy import Column,Integer,String
from database import Base

class User(Base):
    __tablename__='user'
    __table_args__ = {'extend_existing': True}

    user_id=Column(Integer,primary_key=True, index=True)
    user_name=Column(String)
    f_name=Column(String)
    l_name=Column(String)
    email=Column(String)
    phonenumber=Column(String)
    websiteURL=Column(String)
    websiteDetails=Column(String)
    companyName=Column(String)
    password=Column(String)
    howYouHearAboutUs=Column(String)

The Schemas is defined below :

from pydantic import BaseModel,Field
from typing import List,Optional

class UsrBase(BaseModel):
    user_name:str
    f_name:str
    l_name: str
    email:str
    phonenumber: str
    websiteURL:str
    websiteDetails: str
    companyName: str
    password:str
    howYouHearAboutUs: str

class Usr(UsrBase):
    class Config():
        orm_mode=True

class ShowUsr(BaseModel):
    user_id:str
    user_name:str
    companyName:str
    email:str
    websiteURL:str
    password:str

    class Config():
        orm_mode=True

class Login(BaseModel):
    username:str
    password:str

class Token(BaseModel):
    access_token:str
    token_type:str

class TokenData(BaseModel):
    email: Optional[str] = None

Description
when I try to update a record in my DB this is the error which I am getting :
SELECT "user".user_id AS user_user_id, "user".user_name AS user_user_name, "user".f_name A
S user_f_name, "user".l_name AS user_l_name, "user".email AS user_email, "user".phonenumbe
r AS user_phonenumber, "user"."websiteURL" AS "user_websiteURL", "user"."websiteDetails" A
S "user_websiteDetails", "user"."companyName" AS "user_companyName", "user".password AS user_password, "user"."howYouHearAboutUs" AS "user_howYouHearAboutUs"
FROM "user"
WHERE "user".user_id = %(user_id_1)s
I am printing my query in the put method so that I can check whether the parameters are being matched or not but in the where clause why is the "%" coming before the user_id and why _1 is appended to it ?
Operating System
Windows
Operating System Details
No response
FastAPI Version
0.78.0
Python Version
3.10.2
Additional Context
No response

The %(user_id_1)s part of your SQL query looks correct to me. This is a just a placeholder, when executing the query SQLAlchemy will insert the corresponding values or pass them separately to the database.
When looking at the code, first thing I noticed is that id does not have any type in some API endpoints. This means you will get the id as a string (e.g. in destroy and get_user), and your database will probably not know how to deal with the string - integer comparison.
In addition, the update method passes a pydantic object to SQLAlchemy in usr.update(request). I suspect it should be something like usr.update(request.dict()), since the underlying update method expects a dictionary.
Do these hints solve your issue? If not, please provide a full Python backtrace of the exception you are encountering.

Hi as you mentioned above I have added the data type for id and also updated the usr.update(request.dict()). After making these changes the data when being altered on the swagger UI, It is getting updated in the database but still gives an Internal server error.
Below I have attached the screenshots of the browser and the error which I got on my terminal.
@slackner  would be great if you could help me out with this error.
For my reference I learned FastAPI from this youtube link
https://www.youtube.com/watch?v=7t2alSnE2-I&t=11051s
and started to make my own project using his learning.

The traceback still seems to be truncated, it lacks information about where it crashes on your Python code. Can you share the full traceback please? If its too long to include here, you can also use a gist and just share the link.

Hi, @slackner I updated my put method in this way (posting the code below) and all my fields are being inserted into the database too.
The repository has been defined here:
Updating the user details that they would like to update
def update(id:int,request:schemas.UsrBase,db:Session):
p = request.password
request.password = hashing.Hash.bcrypt(p)
user = db.query(models.User).filter(models.User.user_id == id)
if not user.first():
raise HTTPException(status_code=status.HTTP_404_NOT_FOUND,
detail=f'User with id {id} is not available')
user.update(request.dict())
db.commit()
return 'updated'
The code above which I had raised my ticket has a response_model, which I removed in my new code. It worked properly and did not throw any errors.
The router is defined here:
@router.put('/{id}',status_code=status.HTTP_202_ACCEPTED)
def update(id:int,request:schemas.UsrBase,db:Session=Depends(database.get_db),current_user:schemas.UsrBase=Depends(oauth2.get_current_user)):
return user.update(id,request,db)


[WIP] Refactor API Calls

I refactored the createBlueprint API call so it gets called from a saga. I refactored the fetchBlueprintContents API call so it doesn't call as many other functions and is more readable.

Closing this one. These updates were pulled into #500


This seems cool... How about MySQL support?

This seems cool. Many times users start with SQLProvider because it's fast to start with, and works fine with any size of database. But then at some point users may have a need to write a manually for what-ever reason. Linq is not perfect. For now, the solution has been to write a stored procedure, which is unoptimal as other program logic is in F#-code. So I can see these two could work well side-by-side on a project.
The main drawback of FSharp.Data.SqlClient has been lack of other databases.
But they have a good comparison page, this could be added there, just send a PR and try to be objective: http://fsprojects.github.io/FSharp.Data.SqlClient/comparison.html
Are you planning to support Mysql and Oracle?

Hi. I'm happy to hear that you like the project. SQLProvider is definitely the canonical ORM for F# users.
Adding support for other database backends should be pretty simple, but is not at the top of my priorities for the time being. MySQL would definitely come first, Oracle much later. I'd like to have a plugin system where you could point to an assembly in rzsql.json, and type provider would load additional IBackend implementations from there.
In case somebody reading this wants to try their hand at adding a backend, these are the current steps:

Define a list of supported functions and their types. This doesn't have to be exhaustive to start with. Actually I'd save this part for last since it's pretty mind-numbing.

Define a migration backend. DefaultMigrationBackend handles most of it, but it doesn't know how to create the database if one does not exist.

Define a LiteralTranslator, ExprTranslator, and StatementTranslator (like these). Here you can inherit from the default implementations, and just override the parts where your backend's syntax differs from RZSQL. Check the others for examples: TSQL is really complicated, SQLite is almost nothing since RZSQL has virtually the same syntax, Postgres is somewhere in between.

Implement IBackend using all that stuff, like here

Give your backend a name and add it to the config parser for rzsql.json

Write tests for the special SQL translations done by your backend. Most important is to have a "smoke test" that checks the translated SQL for a reasonably complex set of schema operations and a query, like this. You run the translated SQL by hand on a real database to make sure it works, then paste it into the "expectation" for the test so future changes to the output can be re-checked.

Closing since #5 and #6 cover it now.


wasmparser: Add getters for useful internal state to the FuncValidator

Closes https://github.com/bytecodealliance/wasm-tools/issues/732.
This adds the following APIs:

fn len_locals() -> u32
fn get_local_type(index) -> ValType
fn operand_stack_height() -> u32 (already existed)
fn get_operand_type(index) -> Option<Option<ValType>>
fn control_stack_height() -> u32
fn get_control_frame(depth) -> Option<&Frame>

@alexcrichton applied all your review suggestions


Identify if we can move from 'UsableFrom' to 'Capabilities'

Currently plugins define which Swish host can use them:
usableFrom: ['core', 'clip', 'gui']

Can we change this to use capabilities, e.g., plugins define what capabilities they require:
requires: ['HtmlOut']

And apps call some initialise function on the plugin manager with the capabilities they provide:
pluginManager.init(['HtmlOut', 'Persistence']);

Now the plugin will only appear to apps which expose all the required capabilities.
Proposed initial capabilities:

HtmlOut- outputs HTML (only handled by Clip)
Progress- makes use of the args.progressUpdate method
Status- makes use of the args.statusUpdate method

Maybe combine with Progress as like ExecFeedback (?) - it's unlikely an app will offer one but not the other

Persistence- maintains state, not useful for e.g. Swish-Core

Capabilities aren't required to do things - a plugin can return HTML without declaring HtmlOut, but are used when it doesn't make sense for the plugin to be used if the capability doesn't exist.
To Do

[x] Identify if this covers all the UsableFrom use-cases (for internal plugins)

Identification is complete, we can.
Replaced with #35  for implementation.


[Feature]: Add more playback speed options

What feature do you want to add?
0.75x and 1.25x speed buttons and editing of speed using keyboard
Why do you want to have this feature?
Currently, there is only a 1.5x and 2.0x speed option. 1.5x is too fast to watch anything comfortably. So, there should be a 1.25x speed button, and a way to edit the speed using the keyboard.
Any other details to share?
No response

Possible but we would have to find some way to make it fit in this limited space

Do you have any ideas?

How about making it a slider?

As a temporary solution on chromium based browsers: Video Speed Controller Extension

Could use Global Speed too


Add Marshmallow device to testing

Make sure we update at least one device to marshmallow and put in the new ADB command to enable us to give the app permissions.

The ADB command (tested and verified) for granting permissions: adb shell pm grant <app name> android.permission.<permission name> e.g. adb shell pm grant com.test.thalitest android.permission.ACCESS_COARSE_LOCATION

I'm closing this in favor of 30 which Marek pointed out.


Format list item field values

New instance method on SalesforceIQ client to facilitate input of data to list item fields, which require a kind of convoluted syntax. Converts simple key/value data store into the format SalesforceIQ expects for list item fields, using data pulled from the associated list.

Do you guys want to take a quick look at this, @matthewheck and @wchest? I've done some testing, and it seems to be working well. I tried to be mostly stylistically consistent with the surrounding code, too. Currently using this function in my WaterFro development.


update appveyor configuration

Codecov Report

Merging #56 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master      #56   +/-   ##
=======================================
  Coverage   75.86%   75.86%
=======================================
  Files          30       30
  Lines         667      667
  Branches       89       89
=======================================
  Hits          506      506
  Misses        114      114
  Partials       47       47

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 002ddff...d879899. Read the comment docs.


Collisions of RigidBody2D are offsetted when moving.

Godot version:

9f82368d40f1948de708804645374ea02ca6e7db
OS/device including version:

Linux eb 4.17.2-1-ARCH #1 SMP PREEMPT Sat Jun 16 11:08:59 UTC 2018 x86_64 GNU/Linux
Issue description:

Collisions of RigidBody2D are offsetted when moving.
In our current project we swap the mode back and forth from MODE_CHARACTER to MODE_KINEMATIC.
KinematicBody2D seems not affected.
Steps to reproduce:
See the attached demo scenes, videos and gif.
Minimal reproduction project:
(use arrow keys to move)
collisionOffsetIssue.zip
video1
video2

Still reproducible in the current master branch.

Can anyone still reproduce this bug in Godot 3.2.3 or any later release?
I tried the repro, but not sure what to look at.

@KoBeWi
yes it's still reproducable with the current stable (3.2.3).
In the first demo, the "spaceship" accelerates all the time, this pushes the collision down:

In the second demo:

You see that the collision is offsetted based on the speed:


View Full Command Output

Summary
Would it be possible to show the full commands that are listed in the "Command" column?
Additional context
We use a lot of different parameters in our environment, and it would help if we could view the full command the process is using.

I will take care of that.

@Trevor-Bond re: your enhancement request.
Thanks to @artuone83's PR, this issue should land in the app soon and you (and everyone else) should benefit from it via the New Relic One Catalog by the end of the week.


More unit test cases to ensure LogSegment ordering

Also adds the right comparator on maps in the stats classes

Codecov Report

Merging #721 into master will decrease coverage by 0.07%.
The diff coverage is 100%.

@@             Coverage Diff              @@
##             master     #721      +/-   ##
============================================
- Coverage     65.74%   65.67%   -0.08%
+ Complexity     3772     3769       -3
============================================
  Files           328      328
  Lines         25072    25072
  Branches       3144     3144
============================================
- Hits          16484    16466      -18
- Misses         7711     7725      +14
- Partials        877      881       +4

Impacted Files
Coverage Δ
Complexity Δ

...tore/src/main/java/com.github.ambry.store/Log.java
98.19% <100%> (ø)
53 <0> (ø)
:arrow_down:

.../main/java/com.github.ambry.store/ScanResults.java
96.87% <100%> (ø)
21 <0> (ø)
:arrow_down:

...in/java/com.github.ambry.store/BlobStoreStats.java
85.85% <100%> (-0.96%)
93 <0> (-1)

...github.ambry.rest/AsyncRequestResponseHandler.java
88.52% <0%> (-2.3%)
23% <0%> (ø)

...b.ambry.network/BlockingChannelConnectionPool.java
64.03% <0%> (-2.2%)
8% <0%> (ø)

.../java/com.github.ambry.router/DeleteOperation.java
91.66% <0%> (-1.52%)
43% <0%> (-1%)

.../main/java/com.github.ambry.router/GetManager.java
85.55% <0%> (-1.12%)
16% <0%> (-1%)

...m.github.ambry.clustermap/HelixClusterManager.java
93.59% <0%> (-0.72%)
32% <0%> (-1%)

.../main/java/com.github.ambry.router/PutManager.java
84.13% <0%> (-0.69%)
22% <0%> (ø)

... and 2 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a817724...a640322. Read the comment docs.

@nsivabalan  fixes for bugs - please review

@nsivabalan you are the only reviewer, could you merge?


Sass Eyeglass support?

Would you consider adding Eyeglass support (https://github.com/sass-eyeglass/eyeglass)? It's more intuitive that just installing via vanilla NPM (where users would then have to specify a direct import path to the stylesheet within Sass).

Hi @philwareham ! Thanks for the suggestion!
It's definitely a good idea!  I didn't knew about that until now..

Will not be on Sass eyeglass for now.

Would also love Eyeglass support. I'm wondering why this was closed?

It's closed because I currently have no time to keep maintaining this project.
If you feel like you want to add Eyeglass, please do :)
I've been watching their docs at the time this issue was opened, I found it unclear. So I never bothered myself looking deeper.
But once again, if you want Eyeglass support, you can clone the repo and do what it need :)
Thanks!

I submitted a pull request (#87) that adds Eyeglass support :) I just learned about Eyeglass but hopefully I've avoided any mistakes although I agree that the Eyeglass docs are confusing.


[bug] React component failed to build

What happened?
When I update giscus-react from 2.2.2 to 2.2.3, my react project building crashed:

I'm not sure if my case is the same with https://github.com/giscus/giscus-component/issues/782.
Debug
I'm using Giscus in such way:
const Giscus = require('@giscus/react')

Then I print 'Giscus' in project with console.log:

giscus-react in 2.2.2 it prints a function as follow:

giscus-react in 2.2.3 it prints a path as follow:

Environment

Software
Version(s)

React
18.0.0

Node
16.13.0

Others
【advice】If the build product changes commit, is it better to upgrade with BREAK CHANGE?

Fixed in #810, released in v2.2.4.


Add Functionality to The Plant Search Page

Search page was completed by Dony. Search functions correctly and results are displayed on the same page after requesting from the API.


Matcher includes is not working in expectJsonSnapshot

Discussed in https://github.com/pactumjs/pactum/discussions/98

Originally posted by captaincc423 December  1, 2021
I'm trying to get some matchers to work in expectJsonSnapshot and I'm running into a few problems:

I'm trying to use a variable variable with a string in an "includes()", e.g. "id": includes(response.body.id) and it's not working. It always says it doesn't match.

Am I misusing these matchers?

Hi, I was reviewing the issue and I have a propose for solution.

I think it's possible to pass a function to include for get the value of body snapshot. For example include( (resp) => resp.body.id)).  So in to src/models/expect.js method _validateJsonSnapshot(response)  add new 'if' validating if param of include is a functions, if it is true, load the file json snapshot and evaluate the functions.
And, finally send the result to  jmv.validate( ... ) , similar to actual behavior of include for string parameter

What do you thinks about?

The matchers are initially designed to support contract testing. Need to evaluate on how it effects the matching capabilities at flow server if we start supporting callback functions.

Yes, It's true, is necessary evaluate the impact.
Another solution could be passing the functions as string in to include(), and use eval() o new Function()() for evaluate in to _validateJsonSnapshot(response) , for example:
...

"id": includes('return response.body.id')
...
// In _validateJasonSnapshot(response)
// Previews validations of return in string
value = new Function(value)(response)
...
const current_rules = jmv.getMatchingRules(value, '$.body')

I add a draft PR for review the second solutions.  #213

I close Pull Request , comment in the PR! #213

@olcortesb  Thank you for taking time to fix this issue.
The easiest resolution would be making the strict comparison configurable while validating json snapshots.
const strict = false;
const errors = jmv.validate(actual, expected, all_rules, '$.body', strict);

@olcortesb Thank you for taking time to fix this issue.
The easiest resolution would be making the strict comparison configurable while validating json snapshots.
const strict = false;
const errors = jmv.validate(actual, expected, all_rules, '$.body', strict);

User needs to be cautious while disabling strict comparison. May be we can pass the true/false as the second or third argument.
expectJsonSnapshot(matchers, strict?);
expectJsonSnapshot(name, matchers, strict?);

OK, Interesting, I take your recommendation with strict comparison configurable and prepare a Pull Request! thanks

This is fixed https://github.com/pactumjs/pactum-matchers/pull/26


Vertica fixes for 0.13.1 - Manually merging #9845

Describe your changes :

Adapting https://github.com/open-metadata/OpenMetadata/pull/9845 for 0.13.1

Type of change :

[x] Bug fix
[x] Improvement
[x] New feature
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] Documentation

Frontend Preview (Screenshots) :
For frontend related change, please link screenshots of your changes preview! Optional for backend related changes.

Checklist:

[x] I have read the CONTRIBUTING document.
[ ] I have commented on my code, particularly in hard-to-understand areas.
[ ] I have added tests that prove my fix is effective or that my feature works.
[x] All new and existing tests passed.

Reviewers

Will ignore the py-tests failure here. That one is flaky and has been fixed on main. Waiting just for maven and cypress


Update Project-Community Fit report

Changes proposed ✍
What
Change Product-Community Fit to Project-Community on reports page

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.1 out of 2 committers have signed the CLA.:white_check_mark: bumblebee89:x: garrrikkotuaYou have signed the CLA already but the status is still pending? Let us recheck it.


check all manually created manifest files

[x] Carla_Cargo.toml
[x] Eletric_eel_wheel.toml
[ ] HandiBot.toml
[ ] Lasersaur.toml
[ ] LittleRP.toml
[ ] okh_-_AXIOM.toml
[ ] okh_-_Baby_MIT_Cheetah_Robot.toml
[ ] okh_-_Corne_keyboard.toml
[ ] okh-cosi_measure_mechanical.toml
[ ] okh-crKbd.toml
[ ] okh_-_FarmBot.toml
[ ] okh_-_Flipper_Zero.toml
[ ] okh_-_GliaX-Faceshield.toml
[ ] okh-Index.toml
[ ] okh_-_Inkplate_6.toml
[ ] okh-Jubilee.toml
[ ] okh_-_Koruza.toml
[ ] okh-Makair
[ ] okh_-_MNT_Reform.toml
[ ] okh-MPPT-1210-HUS.toml
[ ] okh_-_OpenEVSE.toml
[ ] okh_-_Roden.toml
[ ] okh_-_Unlimited_Hacking_Keyboard.toml
[ ] OpenPCR
[ ] OpenROV.toml
[ ] Opentrons.toml
[ ] The_Spine.toml
[ ] OHO-CAB/okh-Zigzag_solar_water_heater.toml
[ ] OHO-CAB/okh-Workshop_crane_powered_by_drill.toml
[ ] OHO-CAB/okh-Wind_Mill_Pump.toml
[ ] OHO-CAB/okh-Solar_food_dryer_for_vegetables.toml
[ ] OHO-CAB/okh-Small_water_turbine.toml
[ ] OHO-CAB/okh-Safe_and_sturdy_shelter.toml
[ ] OHO-CAB/okh-Rice_Threshing_Machine-Pedal_Driven.toml
[ ] OHO-CAB/okh-Pipe_bending_machine.toml
[ ] OHO-CAB/okh-Long_Andre_Cargo_Bike.toml
[ ] OHO-CAB/okh-Hammer_Mill_for_Corn_Processing.toml
[ ] OHO-CAB/okh-DIY_Solar_Water_Heater.toml
[ ] OHO-CAB/okh-Crown_Cap_Machine.toml
[ ] OHO-CAB/okh-Carla_Cargo_Crowd.toml
[ ] OHO-CAB/okh-Brick_Making_Machine_CETA-RAM-for_soil_bricks.toml
[ ] GSCOP_documentation_projects/okh_-_AmboVent.toml
[ ] GSCOP_documentation_projects/okh_-_BCN3D_MOVEO.toml
[ ] GSCOP_documentation_projects/okh_-_JPL_Open_Source_Rover_Project.toml
[ ] GSCOP_documentation_projects/okh_-_Open_source_ventilator.toml
[ ] GSCOP_documentation_projects/okh_-_Poppy_Humanoid.toml
[ ] GSCOP_documentation_projects/okh_-_Pslab-hardware.toml

@damamitesh where did you find version & license for handybot?

aaaah and for updating this, I think, we need to delete all Wikibase entries for these manually… (and wait until the Krawler fetched the new versions)


File "C:\Python38\lib\site-packages\blinkpy\sync_module.py", line 171, in get_camera_info     return response["camera"][0]

I seem to be getting this error frequently all the time:
Could not extract camera info: {'message': 'Camera not found', 'code': 500}
Traceback (most recent call last):
File "C:\Python38\lib\site-packages\blinkpy\sync_module.py", line 171, in get_camera_info
return response["camera"][0]
KeyError: 'camera'
Could not retrieve calibrated temperature.
Could not find thumbnail for camera unknown
NoneType: None
Seems to be related to a specific sync module refresh I'm doing like this:
blink.sync["SYNC MODULE NAME"].refresh(force_cache=True)
Did we lose support for the above?

Im trying to figure out exactly what is failing, a specific sync module or sync module with camera...

I did some more specific testing this morning and have been unable to force/reproduce. When triggering a flask method that was running when the error was caused manually it worked fine.  So this appears intermittent, maybe a resource/throttling thing again on the side of Blink when doing a refresh?
Let me know if I can gather more specific info

It does seem to continue to work after the error, reports it and moves on. I think I know the answer but just checking to confirm, any idea how to catch it then wait say 60 seconds and try again?

Great, thanks.
That explains why sometimes I see it twice in a once, twice, or many times... I couldn't figure out what was causing that but now it makes sense.
I also noticed that even after error the camera state seems to be accurate which means usually the retry was working I suppose?
Would be great if I could configure # retries, and seconds between retries, or something like that...
Thanks!


Update the version of react-navigation/native

Details

This PR updates version of react-navigation/native in order to access latest changes related to typing of getState - here is a link to original react-navigation issue - link.
Fixed Issues

$ https://github.com/Expensify/App/issues/34523
Tests

[x] Verify that no errors appear in the JS console

Offline tests

[x] Verify that no errors appear in the JS console

QA Steps

[x] Verify that no errors appear in the JS console

PR Author Checklist

[x] I linked the correct issue in the ### Fixed Issues section above
[x] I wrote clear testing steps that cover the changes made in this PR

[x] I added steps for local testing in the Tests section
[x] I added steps for the expected offline behavior in the Offline steps section
[x] I added steps for Staging and/or Production testing in the QA steps section
[x] I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
[x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
[x] I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).

[x] I included screenshots or videos for tests on all platforms
[x] I ran the tests on all platforms & verified they passed on:

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

[x] I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
[x] I followed proper code patterns (see Reviewing the code)

[x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
[x] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g. myBool && <MyComponent />.
[x] I verified that comments were added to code that is not self explanatory
[x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
[x] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method

[x] If any non-english text was added/modified, I verified the translation was requested/reviewed in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:

[x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
[x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is approved by marketing by adding the Waiting for Copy label for a copy review on the original GH to get the correct copy.
[x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
[x] I verified the JSDocs style guidelines (in STYLE.md) were followed

[x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
[x] I followed the guidelines as stated in the Review Guidelines
[x] I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
[x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
[x] I verified any variables that can be defined as constants (ie. in CONST.js or at the top of the file that uses the constant) are defined as such
[x] I verified that if a function's arguments changed that all usages have also been updated correctly
[x] If any new file was added I verified that:

[x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory

[x] If a new CSS style is added I verified that:

[x] A similar style doesn't already exist
[x] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG))

[x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
[x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
[x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
[x] If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
[x] If the PR modifies the form input styles:

[x] I verified that all the inputs inside a form are aligned with each other.
[x] I added Design label so the design team can review the changes.

[x] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
[x] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.

Screenshots/Videos

Android: Native

Android: mWeb Chrome

iOS: Native

iOS: mWeb Safari

MacOS: Chrome / Safari

MacOS: Desktop

@roryabraham What should I put in place of "proposal link"?

@roryabraham I went through the app and all seems to work fine, how do we want to proceed with that one?

Hey @roryabraham @MrRefactor, could you share some specific flows/mechanisms I should test with more attention? Or should I just perform a general sanity check of the App behavior?

I'd focus mostly on navigation flows and deeplinking. We'll need Applause to test the transition from OldDot too.

Also @staszekscp maybe you want to test HybridApp and make sure this isn't causing regressions?

Reviewer Checklist

[ ] I have verified the author checklist is complete (all boxes are checked off).
[ ] I verified the correct issue is linked in the ### Fixed Issues section above
[ ] I verified testing steps are clear and they cover the changes made in this PR

[ ] I verified the steps for local testing are in the Tests section
[ ] I verified the steps for Staging and/or Production testing are in the QA steps section
[ ] I verified the steps cover any possible failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
[ ] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)

[ ] I checked that screenshots or videos are included for tests on all platforms
[ ] I included screenshots or videos for tests on all platforms
[ ] I verified tests pass on all platforms & I tested again on:

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

[ ] If there are any errors in the console that are unrelated to this PR, I either fixed them (preferred) or linked to where I reported them in Slack
[ ] I verified proper code patterns were followed (see Reviewing the code)

[ ] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick).
[ ] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g. myBool && <MyComponent />.
[ ] I verified that comments were added to code that is not self explanatory
[ ] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
[ ] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method
[ ] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
[ ] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is approved by marketing by adding the Waiting for Copy label for a copy review on the original GH to get the correct copy.
[ ] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
[ ] I verified the JSDocs style guidelines (in STYLE.md) were followed

[ ] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
[ ] I verified that this PR follows the guidelines as stated in the Review Guidelines
[ ] I verified other components that can be impacted by these changes have been tested, and I retested again (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar have been tested & I retested again)
[ ] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
[ ] I verified any variables that can be defined as constants (ie. in CONST.js or at the top of the file that uses the constant) are defined as such
[ ] If a new component is created I verified that:

[ ] A similar component doesn't exist in the codebase
[ ] All props are defined accurately and each prop has a /** comment above it */
[ ] The file is named correctly
[ ] The component has a clear name that is non-ambiguous and the purpose of the component can be inferred from the name alone
[ ] The only data being stored in the state is data necessary for rendering and nothing else
[ ] For Class Components, any internal methods passed to components event handlers are bound to this properly so there are no scoping issues (i.e. for onClick={this.submit} the method this.submit should be bound to this in the constructor)
[ ] Any internal methods bound to this are necessary to be bound (i.e. avoid this.submit = this.submit.bind(this); if this.submit is never passed to a component event handler like onClick)
[ ] All JSX used for rendering exists in the render method
[ ] The component has the minimum amount of code necessary for its purpose, and it is broken down into smaller components in order to separate concerns and functions

[ ] If any new file was added I verified that:

[ ] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory

[ ] If a new CSS style is added I verified that:

[ ] A similar style doesn't already exist
[ ] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(theme.componentBG)

[ ] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
[ ] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
[ ] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
[ ] If the PR modifies a component or page that can be accessed by a direct deeplink, I verified that the code functions as expected when the deeplink is used - from a logged in and logged out account.
[ ] If the PR modifies the form input styles:

[ ] I verified that all the inputs inside a form are aligned with each other.
[ ] I added Design label so the design team can review the changes.

[ ] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
[ ] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.
[ ] I have checked off every checkbox in the PR reviewer checklist, including those that don't apply to this PR.

Screenshots/Videos

Android: Native

Android: mWeb Chrome

iOS: Native

iOS: mWeb Safari

MacOS: Chrome / Safari

MacOS: Desktop

once we update package.json and package-lock.json, I can run an AdHoc build here and request a QA run

once we update package.json and package-lock.json, I can run an AdHoc build here and request a QA run

updated

I also can see that Github Actions are failing, should I run npm run gh-actions-build and commit the changes?
@roryabraham @situchan @paultsimura

Also @staszekscp maybe you want to test HybridApp and make sure this isn't causing regressions?

Thanks Rory thinking about it! I'll try to test it today, but don't wait for me with the merge if everything else is fine. It may take a while, and since it's a small bump, and it touches mostly types and a patch to web navigation we should be fine

Hey! I've just build the app from this PR, and it seems to work fine 😄

:hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

🚀 Deployed to staging by https://github.com/roryabraham in version: 1.4.47-0 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
failure ❌

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅

🚀 Deployed to production by https://github.com/roryabraham in version: 1.4.47-10 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅


Fix non working code by removing unused and breaking forEach

Fix non working code by removing unused and breaking forEach

This change is

:lgtm: thanks @gregbenner

🙌🏽  no worries!


fix missing meta prop for pagination

See https://vizzuality.atlassian.net/browse/MARXAN-374

We miss you typings! sweat_smile

Totally. I'm fully guilty here of having added @types/jsonapi-serializer only to zap it myself. The reason is explained in api/src/types/jsonapi-serializer.stub.d.ts - I didn't have a chance back at that time to think if what was missing from the @types/jsonapi-serializer declarations could be achieved easily (probably contributing this back as a PR to the definitelytyped repo).
If you have thoughts on that, I'd welcome your opinion 😃

We miss you typings! sweat_smile

Totally. I'm fully guilty here of having added @types/jsonapi-serializer only to zap it myself. The reason is explained in api/src/types/jsonapi-serializer.stub.d.ts - I didn't have a chance back at that time to think if what was missing from the @types/jsonapi-serializer declarations could be achieved easily (probably contributing this back as a PR to the definitelytyped repo).
If you have thoughts on that, I'd welcome your opinion 😃

@hotzevzl I can take a quick look at it (previously I did some locally-extending existing types) if only you could provide some example code what we expect to work


Discord voice servers connection fails

When entering a voice channel in Discord conncetion fails at "RTC Connecting" stage with "No route" response.
Tested using both tcp and http as a transport protocol setting in reality-ezpz. Also i have tried different clients (nekobox, v2rayN), different Discord server locations and operating systems (Windows 10, Arch Linux) and got the same error. Other apps and websites seem to be working fine.

@CyrilHaritonov
Can you send me some connection log from you client?
You should increase log level to see these kind of logs.

log_nekoray.txt
Here is some logs during the atempt to connect to Discord voice channel. Nekoray was executed with -debug option and level of logs was set to debug in core options.

While is seems the problem is in config of the client (proxy/socks: unknown Socks version), I have updated the rulesets for server.
You can fetch new rules and test it again, maybe this time works:
bash <(curl -sL https://bit.ly/realityez) -r

I tried both with nekoray and v2rayN and got the same results with Discord. Here are some logs from the v2rayN client in the same situation as the previous. Those does not seem to indicate any error on client side.
log2.txt

I had the same problem. By the way, the problem is really on the client side, since when connecting to the voice channel from Android(v2rayNG) with the same settings, the connection is successful 🥲

@CyrilHaritonov @Xorsiphus
I think maybe it is because inclusion of Russia IP in bypass rules.
I have updated the rules.
Please test it again after restarting the service:
bash <(curl -sL https://bit.ly/realityez) -r

Unfortunately this did not help, as I already said, most likely the problem is in the client, since when connecting from the phone everything works

Maybe it is related to the protocol of voice channel.
I think it is using UDP and when the client uses socks as inbound, it cannot correctly forward packets.
When you use mobile client, it is using tun interface that can handle udp packes.
I suggest you to test it with v2rayn but enable the "tun interface" option from the bottom of the window.

enable the "tun interface" option

Enabling tun mode and adding Discord.exe to whitelist on Nekoray resolved this issue.
Thank you!


'DepthAnythingPreprocessor' node error

Hi. I got an recent error regarding this node. Could it be due to Comfy recent update?
FETCH DATA from: X:\SD Launcher\SD nowy\Packages\ComfyUI\custom_nodes\ComfyUI-Manager\extension-node-map.json [DONE]
[ERROR] An error occurred while retrieving information for the 'DepthAnythingPreprocessor' node.
Traceback (most recent call last):
File "X:\SD Launcher\SD nowy\Packages\ComfyUI\server.py", line 447, in get_object_info
out[x] = node_info(x)
File "X:\SD Launcher\SD nowy\Packages\ComfyUI\server.py", line 424, in node_info
info['input'] = obj_class.INPUT_TYPES()
File "X:\SD Launcher\SD nowy\Packages\ComfyUI\custom_nodes\comfyui_controlnet_aux\node_wrappers\depth_anything.py", line 8, in INPUT_TYPES
ckpt_name=INPUT.COMBO(
TypeError: INPUT.COMBO() got an unexpected keyword argument 'resolution'

It's due to a typo in this extension's code. I just fixed it recently

It's due to a typo in this extension's code. I just fixed it recently

Thank you for reply. Fixed.


Vac Bypass breaks steam

steam goes offline i can still enter games but i cant check the store, library, or friendslist

how did you get it to work
my says VAC BYPASS couldnt start correctly


[KYUUBI #5698][Authz] Hudi privilege object for table should ignore meta column

Why are the changes needed?
To close #5698
Hudi privilege table should ignore meta column,
For simple sql
SELECT * from hudi_ns.table1_hoodie

will throw such excepton, we should ignore meta columns
Permission denied: user [someone] does not have [select] privilege on [hudi_ns/table1_hoodie/_hoodie_commit_time,hudi_ns/table1_hoodie/_hoodie_commit_seqno,hudi_ns/table1_hoodie/_hoodie_record_key,hudi_ns/table1_hoodie/_hoodie_partition_path,hudi_ns/table1_hoodie/_hoodie_file_name,hudi_ns/table1_hoodie/id,hudi_ns/table1_hoodie/name,hudi_ns/table1_hoodie/city]

How was this patch tested?

[x] Add some test cases that check the changes thoroughly including negative and positive cases if possible

[ ] Add screenshots for manual tests if appropriate

[ ] Run test locally before make a pull request

Was this patch authored or co-authored using generative AI tooling?
No

ping @yaooqinn

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (905170d) 61.43% compared to head (7fcfc6e) 61.45%.

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #5699      +/-   ##
============================================
+ Coverage     61.43%   61.45%   +0.01%
  Complexity       23       23
============================================
  Files           607      608       +1
  Lines         35727    35741      +14
  Branches       4891     4892       +1
============================================
+ Hits          21950    21964      +14
- Misses        11393    11399       +6
+ Partials       2384     2378       -6

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

The case in PR desc looks reasonable to me. Anything belonging to the table shall have proper privileges. If you use * to retrieve them, then authorize them. Otherwise, * shall not point to the meta columns instead of skipping them in authz.

The case in PR desc looks reasonable to me. Anything belonging to the table shall have proper privileges. If you use * to retrieve them, then authorize them. Otherwise, * shall not point to the meta columns instead of skipping them in authz.

Oh...I make a mistake, just checked with the hudi dev that in our prod, SELECT * FROM HUDI will ignore the HUDI meta column, but for real case, it will show hudi's meta columns too. Since we write unit test with collect() not show(), didn't find this.

Close this since it's not a issue


improvementRemove excess code

Proposed changes
Issue Number: close #xxx
Problem summary
Describe your changes.
Inherited from:https://github.com/apache/doris/pull/19123
Checklist(Required)

[ ] Does it affect the original behavior
[ ] Has unit tests been added
[ ] Has document been added or modified
[ ] Does it need to update dependencies
[ ] Is this PR support rollback (If NO, please explain WHY)

Further comments
If this is a relatively large or complex change, kick off the discussion at<EMAIL_ADDRESS>by explaining why you chose the solution you did and what alternatives you considered, etc...

run buildall


Update wrong "Path to publish"

I think that the Source folder should be $(Build.SourcesDirectory) instead of $(Build.ArtifactStagingDirectory). Otherwise, you're copying files from the same place you're dropping them.
This is for the "C++ app" section in the "Artifacts in Team Build"

@compuguru Thank you for your contribution, I have assigned this to the author of the article for review. Thank you.


HBASE-24756 Backport HBASE-24336 "[Metrics] FSDataInputStream's localBytesRead is wrong" to branch-2.2

HBASE-24336 is applicable to branch-2.2 also.

@binlijin @Reidddddd
Please review.


New Group - Drafted message is not saved if the group doesn't have any messages yet

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

Action Performed:

Create a new group
Draft a message in the compose box
Navigate to another conversation
Group chat should now disappear from LHN
Create the same group again
Check for the drafted message.

Expected Result:
Drafted message should be displayed.
Actual Result:
Drafted message is not saved in the group conversation.
Workaround:
None - message is lost.
Platform:

Where is this issue occurring?

Web
iOS
Android
Desktop App
Mobile Web

Version Number: 1.1.16-9
Reproducible in staging?: Yes
Reproducible in production?: Yes
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
https://user-images.githubusercontent.com/44479856/143508238-774f6105-48f6-4bd2-9a5f-94e6ebadd787.mp4
Expensify/Expensify Issue URL:
Issue reported by: @Christinadobrzyn
Slack conversation: https://expensify.slack.com/archives/C01GTK53T8Q/p1637801619497000
View all open jobs on GitHub

Triggered auto assignment to @MonilBhavsar (Engineering), see https://stackoverflow.com/c/expensify/questions/4319 for more details.

Issue looks good. Can reproduce it.
@isagoico looks like video is of another bug 😅

I'm looking into the issue, Other related issue linked to this

Draft a message with individual user
Start a new group chat
Draft comment entered in 1 should not be linked to group chat started in 2

Found a similar issue and asked for confirmation

Issue looks good. Can reproduce it. @isagoico looks like video is of another bug 😅

omg my bad! Fixed it 🤦

Will be closing after linked PR is merged

@MonilBhavsar Whoops! This issue is 2 days overdue. Let's get this updated quick!

OK, #6207 is merged. The second step would be to keep the new chat in the LHN if the user left a draft. cc: @MonilBhavsar

Tested this on your branch and can't reproduce the issue. 👏
I don't think we want to keep the drafted message in the LHN. We also don't do that with individual chat.
but let's ask in slack and get others views

We show reports with draft message in LHN.
But there is a filter where reports with no message is not shown in LHN. But if this report has a draft it should be shown in LHN.
Yeah, good point. Please raise it there and see.

@parasharrajat, created a new issue here


doc/admin-guide: minor fixes

Fix a typo and a syntax error in the ATS Administrator's Guide.

[approve ci]


Feat/vue apollo composable functions plugin

Hi everybody 👋
I've been working on a plugin to generate code for v4 of vue-apollo.
https://github.com/vuejs/vue-apollo/releases/tag/v4.0.0-alpha.1
V4 introduces an api very similar to react hooks for react-apollo, therefore the code in this PR was initially copied over from the react-apollo plugin and modified for vue.
Happy to hear any feedback and if you feel like this PR is in a good shape I'm willing to write docs for it as well. 🚀
In use:
<template>
  <h1>{{ result }}</h1> <-- Hello World! -->
</template>

<script lang="ts">
import { createComponent } from "@vue/composition-api";
import { useHelloWorldQuery } from "../generated/graphqlOperations";

export default createComponent({
  setup() {
    const { result } = useHelloWorldQuery();
    return { result };
  },
  name: "home"
});
</script>

Related issues:

https://github.com/dotansimha/graphql-code-generator/issues/1539

Todo:

[x] fix useQuery, useSubscription and useMutation input types
[x] fix required inputs/arguments in generated code

@iskanderbroere Thank you for this great work! We are also about to release a new version for codegen to support extracting graphql definitions from vue files. That's perfect timing!
https://github.com/ardatan/graphql-toolkit/pull/358

Hey, awesome thanks for doing this @iskanderbroere! I was working on one of these too for the follow up to ardatan/graphql-toolkit#358 and I'm glad that someone else picked it up. 🎉
I see an issue with the current outputs: the useQuery, useSubscription, and useMutation functions are not taking in the full reactive types.

useQuery and useSubscription both take a reactable type T | Ref<T> | ReactiveFunction<T> for their inputs.
useMutation oddly takes only T | ReactiveFunction<T> for its types.

Here's an example:
Current, missing Ref and ReactiveFunction inputs
// Only defined <T>, missing Ref<T> and ReactiveFunction<T>
export function useFeedQuery(
  variables?: FeedQueryVariables,
  baseOptions?: VueApolloComposable.UseQueryOptions<FeedQuery, FeedQueryVariables>
) {
  return VueApolloComposable.useQuery<FeedQuery, FeedQueryVariables>(
    FeedDocument,
    variables,
    baseOptions
  );
}

// Only defined <T>, missing ReactiveFunction<T>
export function useSubmitRepositoryMutation(
  baseOptions?: VueApolloComposable.UseMutationOptions<SubmitRepositoryMutation,SubmitRepositoryMutationVariables>
) {
  return VueApolloComposable.useMutation<
    SubmitRepositoryMutation,
    SubmitRepositoryMutationVariables
  >(SubmitRepositoryDocument, baseOptions);
}

Expected, with full types
// With T | Ref<T> | ReactiveFunction<T>
export function useFeedQuery(
  variables?:
    | FeedQueryVariables
    | Ref<FeedQueryVariables>
    | ReactiveFunction<FeedQueryVariables>,
  baseOptions?:
    | VueApolloComposable.UseQueryOptions<FeedQuery, FeedQueryVariables>
    | Ref<VueApolloComposable.UseQueryOptions<FeedQuery, FeedQueryVariables>>
    | ReactiveFunction<VueApolloComposable.UseQueryOptions<FeedQuery, FeedQueryVariables>>
) {
  return VueApolloComposable.useQuery<FeedQuery, FeedQueryVariables>(
    FeedDocument,
    variables,
    baseOptions
  );
}

// With T | ReactiveFunction<T>
export function useSubmitRepositoryMutation(
  baseOptions?:
    | VueApolloComposable.UseMutationOptions<
        SubmitRepositoryMutation,
        SubmitRepositoryMutationVariables
      >
    | ReactiveFunction<
        VueApolloComposable.UseMutationOptions<
          SubmitRepositoryMutation,
          SubmitRepositoryMutationVariables
        >
      >
) {
  return VueApolloComposable.useMutation<
    SubmitRepositoryMutation,
    SubmitRepositoryMutationVariables
  >(SubmitRepositoryDocument, baseOptions);
}

I am submitting a PR today for vue-apollo that addresses some of the issues I found while working on the hooks plugin:

Correctly handles unwrapping Refs for mutations, so the input types will also include Ref<T>.
Exports a wrapper type for the very verbose reactable type T | Ref<T> | ReactiveFunction<T>.
Allows user hooks to actually define their return types.

I'll tag you when I post it, hopefully we can coordinate.

I also noticed another issue: the generated mutation functions are not taking input variables when they are required by the API, which is not type safe.
For example, given this mutation document:
const ExampleUpdateDocument = gql`
  mutation exampleUpdate($id: ID!, $example: ExampleInput!) {
    exampleUpdate(id: $id, example: $example) {
      ...
    }
  }
`;

There are two required variables. However, the generator outputs
// ExampleUpdateMutationVariables is unused
function useExampleUpdateMutation(baseOptions?: ...) {  ... }

// Should be required!
export type ExampleUpdateMutationVariables = {
  id: Scalars["ID"];
  example: ExampleInput;
}

but it should be:
function useExampleUpdateMutation(
  variables: ExampleUpdateMutationVariables | ...,
  baseOptions?: ...
) { ... }

because those variables are required by the API. Thus this results in type safe calls.
Given that some mutations can be called without inputs, it seems like the generator could check to see if the mutation has any variables, and then exclude that input if it's not required.
// Output variables as the first argument if the mutation has inputs
function useMutationWithArgumentsMutation(variables: ..., baseOptions?: ...) { ... }

// Don't output variables argument if the mutation doesn't take arguments (rare)
function useMutationWithoutArgumentsMutation(baseOptions?: ...) { ... }

I also noticed another issue: the generated mutation functions are not taking input variables when they are required by the API, which is not type safe.
For example, given this mutation document:
const ExampleUpdateDocument = gql`
  mutation exampleUpdate($id: ID!, $example: ExampleInput!) {
    exampleUpdate(id: $id, example: $example) {
      ...
    }
  }
`;

There are two required variables. However, the generator outputs
// ExampleUpdateMutationVariables is unused
function useExampleUpdateMutation(baseOptions?: ...) {  ... }

// Should be required!
export type ExampleUpdateMutationVariables = {
  id: Scalars["ID"];
  example: ExampleInput;
}

but it should be:
function useExampleUpdateMutation(
  variables: ExampleUpdateMutationVariables | ...,
  baseOptions?: ...
) { ... }

because those variables are required by the API. Thus this results in type safe calls.
Given that some mutations can be called without inputs, it seems like the generator could check to see if the mutation has any variables, and then exclude that input if it's not required.
// Output variables as the first argument if the mutation has inputs
function useMutationWithArgumentsMutation(variables: ..., baseOptions?: ...) { ... }

// Don't output variables argument if the mutation doesn't take arguments (rare)
function useMutationWithoutArgumentsMutation(baseOptions?: ...) { ... }

The useMutation api is different from useQuery and useSubscription.  useMutation expects variables in the baseOptions  argument rather than a separate argument. That does leave us with the problem that baseOptions is hardcoded to never be required, I'll look into that.

useMutation oddly takes only T | ReactiveFunction<T> for its types.
https://v4.apollo.vuejs.org/guide-composable/mutation.html#variables
This should give you an answer why it doesn't take a regular Ref<T>

Thanks for your replies @iskanderbroere , I appreciate your attention for quality of the outcome.

The useMutation api is different from useQuery and useSubscription. useMutation expects variables in the baseOptions argument rather than a separate argument. That does leave us with the problem that baseOptions is hardcoded to never be required, I'll look into that.

You're right, the useMutation API itself is incorrect in the alpha and that will have to be addressed.
I think your proposed solution is fine, though I think we can do better. IMO the wrappers should make the API easier to use, not try to 1:1 match it where it makes more sense to be developer friendly.
useCommentQuery({ id: 15 }, options)
useCommentSubscripton({ id: 15 }, options)
useCommentMutation({ variables: { id: 15 }, ...options })  // weirdly different for no value

useMutation oddly takes only T | ReactiveFunction<T> for its types.
v4.apollo.vuejs.org/guide-composable/mutation.html#variables

This should give you an answer why it doesn't take a regular Ref<T>

You and the documentation are correct, passing in a non-reactive value is going to not be reactive. However, that's not what I was referring to. I can see how this could have been confusing.
What I am talking about is the useMutation function signature itself. useQuery and useSubscription can both allow for refs in their variables and options, but useMutation is currently not configured to allow a ref for options.
I don't believe there's a technical reason for this, because I have a minimal patch that allows useMutation to also take options: Ref<>, and it works as expected. I brought this up to give you a heads up that this will (hopefully) change in the alpha after I submit the PR.
For example, this works as expected in my branch:
const randomName = ref('')

// v4-alpha4 causes a type error but it works fine
const options = ref({ variables: { id: 1, name: randomName } })

const { mutate } = useMutation(RandomNameMutation, options) // no error

// button @click="randomizeName"
function randomizeName () {
  randomName.value = Math.random().toString()
  mutate()
}

Ah yeah I see what you mean. I'll take a look at once you opened a PR in the vue-apollo repo.

I think it makes most sense to keep this PR open until @vue/apollo-composable has reached beta. I'll try to keep it up to date.

@ardatan Can you please review?

Looks good to me!
@iskanderbroere
We can wait for beta or merge it now and we would take Vue Apollo community's attention earlier :)

@iskanderbroere I think we can merge it for now. So we can get some feedback from the community. What do you think? @dotansimha

There's still one bug in this branch which I didn't fix yet. I'll fix it on Monday and we can merge 👍

Alright feel free to review and/or merge the branch !


this is a bug?

Details

The number of characters is the same, why the width of the two lines are not the same

datas

┏━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┠─────────────────────────────────────────────────────────┨

@smalltimoo I am not sure what you are talking about here. Please update your issue with all requested information and steps to reproduce, or else we are not able to help.
Closing this for now.


Typo error in CONTRIBUTING.md

Hey ! I want to fix a typo error in CONTRIBUTING.md can you just assign it to me ?

Yeah, you're welcome to do so !

Hey ! I want to fix a typo error in CONTRIBUTING.md can you just assign it to me ?

Yeah, you are welcome to do so!

Hey ! I want to fix a typo error in CONTRIBUTING.md can you just assign it to me ?

Yeah, you are welcome to do so!

Thanks


Look into performance improvements for crop

The modification for improving crop performance involves configuring the input format to perform filtering to prevent reading all of the tiles outside of the crop region. This can only be done if the input raster to the crop is a stored image (as opposed to the result of a map algebra expression).
I am changing the crop map op so that it checks to see if its raster input is a MrsPyramidMapOp. If it is,it sets the crop bounds in that map op (after cloning it so as not to affect any other map op's that use the same raster input). If the MrsPyramidMapOp has bounds assigned to it (as described above), it in turn configures the Hadoop input format with those bounds. The input format has logic to limit the returned splits (and records) to only include tiles within those bounds, thus preventing the reading of all tiles in the image unnecessarily.
Note that if the input raster passed to crop is not a reference to a stored image (e.g. it is another map algebra expression), it will use the existing Spark filtering because that's all it can do.

In my testing within AWS EMR, a crop operation on a worldwide image ran in 22 minutes, 12 seconds with the old code, and now runs in 1 minute, 38 seconds. And the tobler friction surface computation (which required two crop operations ) that ran in approximately 50 minutes, now runs in 2 minutes and 42 seconds.

A couple questions-
What was the crop operation (how big)?
What change was made to speed this up?

I cropped a worldwide image down to 2 degrees square
In a nutshell, I made changes to perform the filtering at the data input level rather than waiting until the data is flowing through Spark. That prevents ever having to push all the unneeded tiles through the system. There is more detail on this in the second paragraph of my earlier comment along with conditions under which is still has to perform the Spark filtering.


ISSUE-58 #Codecov configuration to check code coverage

To add code coverage -
How do we integrate it with GitHub?
Sign up in codecov.io via your GitHub account, give access to repository on which report has to be generated.
Once pull request is merged, code coverage will be generated on codecov.io website then you can add that report link in README.md

ignore section not getting recognized for coverage. probably path is wrong for java files.


FindAndCount,  生成的count语句有问题?

SELECT  * FROM `orders` WHERE (merchant_id IN (?,?)) AND (`delete_at` IS NULL OR `deleted_at`=?) LIMIT 10 []interface {}{"1", "2", "0001-01-01 00:00:00"}

SELECT count(*) FROM `orders` WHERE (merchant_id IN (?,?)) AND (`delete_at` IS NULL OR `deleted_at`=?) AND (`deleted_at` IS NULL OR `deleted_at`=?) []interface {}{"1", "2", "0001-01-01 00:00:00", "0001-01-01 00:00:00"}

count语句多了一个 (deleted_at IS NULL OR deleted_at=?)

If you have deleted column, the condition will be added automatically.


[FEATURE] Could robot.operational() return an error code instead of a simple boolean for error handling

Is your feature request related to a problem? Please describe.
When using reobot.operational(), I only have logs to inform me on why the robot is not operational. I cannot use those to do automatic error handling nor inform an operation that uses and HMI.
Describe the solution you'd like
I would like the method to return error codes instead of a simple boolean, something like this:
0: no problem, robot is operation
1: robot is not enabled
2: breaks are engaged
4: Not in auto mode (remote)
8: has fault
16: in reduced state
32: e-stop engaged
I put each error on it's own bit so it can be known if there are multiple error at the same time, but I don't think that is strictly necessary.
Describe alternatives you've considered
I tried to bypass this limitation by using the contextlib.redirect_stdout and contextlib.redirect_stderr context mangers to capture the flexivrdk's messages in a string, but in both cases the message was printed and nothing was captured.
Another posiblity is to expose other methods to probe each problems individually. Something like:
bool Robot::enabled(); // True if robot is enabled, false if robot is not enabled
bool Robot::breaks_engaged(); // True if breaks are engaged, false if breaks are released
int Robot::auto_mode(); // 0 if manual mode, 1 if auto mode, 2 if auto mode (remote)
int Robot::fault(); // Return error code of the fault instead of a simple boolean
bool Robot::reduced_state() // True if robot is in reduced state, false if robot is not in reduce state
bool Robot::external_estop_released(); // Complementary method to give the state of the external e-stop botton that can be wired in the control box
Additional context
N/A

@skyrimax Is this what you are looking for?
https://github.com/flexivrobotics/flexiv_rdk/blob/release/v1.5/include/flexiv/rdk/robot.hpp#L112

@pzhu-flexiv Yes, that's what I'm looking for. THank you for pointing this to me, it is not listed in the RDK's documentation. Since we are developping in Python, the online documentation has been our only way to know what methods are available for us to use. Looking at the top of the page, it does say RDK 1.4 so we assumed it was up to date. Thanks for your help, I'll test this method when I have the time and will close the issue if it solves our issues. I am leaving the url of the documentation we used as proof that this method is not listed.
https://rdk.flexiv.com/api/classflexiv_1_1rdk_1_1_robot.html

@skyrimax The link I provided is in release/v1.5 branch, which is not released yet. If you are watching the repo, you should receive a notification when v1.5 is released. At that time the online documentations will be updated as well. Thanks for your feedback!


FALCON-2197, enable and disable functionalities for extensions

@PracheerAgarwal, can you please squash your last four commits into 1. It is easy to a diff between my last review the the changes. Else, I'll have to look at the whole patch again OR look at each commit individually.

One comment which has been missed , which I had mentioned earlier too.
Can you make changes to localExtensionManager and modify org.apache.falcon.unit.TestFalconUnit#testSubmitAndScheduleExtensionJob
to test for disabling and then update and enable it back and to check if it gets updated then


[Feature Request] stroke-dasharray for SVG

As I've used this property for making an animation on SVG circle, it needs to use stroke-dasharray to make it happens.
So I used unsafe("stroke-dasharray", "0 100"), it was very unsafe as the name, and the browser console keeps showing this message.

Would you mind to suggest to me what I can remove this or add this property in bs-css?
Thank you

Hi, PR is welcome.
you can find the svg properties in Css_Core.rei in the SVG module.

hi @pzshine,
Writing css properties in camel case will fix that error, like unsafe("strokeDasharray", "0 100")
The Css.style uses emotion's object styles under the hood
https://github.com/reasonml-labs/bs-css/blob/c21a693b9472853e41ec7596ffba09736bf09aba/bs-css/src/Css_Js_Core.re#L32
toJson turns style rules into a JSON object
https://github.com/reasonml-labs/bs-css/blob/c21a693b9472853e41ec7596ffba09736bf09aba/bs-css/src/Css_Js_Core.re#L24-L25
CssImplementation.make is defined here
https://github.com/reasonml-labs/bs-css/blob/c21a693b9472853e41ec7596ffba09736bf09aba/bs-css-emotion/src/CssJs.re#L8


Google Play services out of date.  Requires 10298000

[ 03-03 02:08:55.886  9642:10407 W/GooglePlayServicesUtil ]
Google Play services out of date.  Requires 10298000 but found 10087438

I have this in my logcat too.
20:19:29.612 GooglePlayServicesUtil(22091)
Google Play services out of date.  Requires 10298000 but found 10087438
Package Name: com.hyperionics.avar
App Link:
https://play.google.com/store/apps/details?id=com.hyperionics.avar
Thanks for your hard work.

The first app I have that actually throws a user-visible message because of the low version number is 'Tapas' (https://play.google.com/store/apps/details?id=com.tapastic&hl=de). It still works, since the message disappears after 2 or 3 seconds.

Confirmed. Google docs also requires a newer version

Hey, guys. Do you have a nightly builds apk storage or something similar? Maybe Travis stashes them somewhere? How can I get latest master build apk?

@vermut: You can get it here.
Use the drop-down menu to select the preview version.

@vermut: The preview releases are also available via F-Droid – however updating microG via F-Droid has a problem… The comment here describes how to do it.

@Awerick Thank you. F-Droid 0.104 resolved it all. Needed "unstable updates" to start rolling.


BLUETOOTH permission is listed as optional in docs but seems to be required

The Android setup docs under Step 2 - Add permissions to your AndroidManifest.xml: list the BLUETOOTH permission as optional but I am seeing a consistent crash for at least a Samsung SM-925T.  I have not tested enough to determine if this is device specific but either way it should not happen.  It causes our app to go into a crash/restart cycle of sometimes more than 10 times.
02-02 10:09:11.688 13384-13405/? E/BluetoothAdapter: Application does not have bluetooth permission, registering is failed
02-02 10:09:11.688 13384-13405/? E/BluetoothAdapter: java.lang.SecurityException: Need BLUETOOTH permission: Neither user 10348 nor current process has android.permission.BLUETOOTH.
                                                         at android.os.Parcel.readException(Parcel.java:1620)
                                                         at android.os.Parcel.readException(Parcel.java:1573)
                                                         at android.bluetooth.IBluetoothManager$Stub$Proxy.registerStateChangeCallback(IBluetoothManager.java:350)
                                                         at android.bluetooth.BluetoothAdapter.<init>(BluetoothAdapter.java:594)
                                                         at android.bluetooth.BluetoothAdapter.getDefaultAdapter(BluetoothAdapter.java:576)
                                                         at com.mixpanel.android.mpmetrics.SystemInformation.isBluetoothEnabled(SystemInformation.java:141)
                                                         at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.getDefaultEventProperties(AnalyticsMessages.java:559)
                                                         at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.prepareEventObject(AnalyticsMessages.java:573)
                                                         at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.handleMessage(AnalyticsMessages.java:251)
                                                         at android.os.Handler.dispatchMessage(Handler.java:102)
                                                         at android.os.Looper.loop(Looper.java:158)
                                                         at android.os.HandlerThread.run(HandlerThread.java:61)

Hi @agramian ! Thanks for reporting this. What's the SDK Version that you are using? Also, have you modified the library somehow?
Thanks!

Hi @patedit no I have not modified the library at all.  I'm using it exactly as your docs instruct.  Here's the info from my gradle file.
    compileSdkVersion 25
    buildToolsVersion "25.0.2"

    defaultConfig {
        minSdkVersion 16
        targetSdkVersion 25
...
    compile "com.mixpanel.android:mixpanel-android:4.9.3"

1 same problem

What's slightly crazy about this is that there's already this in SystemInformation.isBluetoothEnabled():
        } catch (SecurityException e) {
            // do nothing since we don't have permissions
        }

I can't figure out from the stacktrace how the app would be crashing on a SecurityException from the getDefaultAdapter() call

Hehe, I know. This crash is pretty crazy (hence my interest of including the permission in the AndroidManifest.xml). I suspect it's an OEM implementation that I'd need to dig into.

+1 similar issue:
I get the same error message every time i open the app. But it does not crash at least.
Still.. it looks wierd to see error output in my logcat every time I open the app..

same here on android N samsung device s8
05-04 08:04:41.778 12607-12634/com.sample.airwatchsdk E/BluetoothAdapter: Application does not have bluetooth permission, registering is failed
05-04 08:04:41.781 12607-12634/com.sample.airwatchsdk E/BluetoothAdapter: java.lang.SecurityException: Need BLUETOOTH permission: Neither user 10201 nor current process has android.permission.BLUETOOTH.
at android.os.Parcel.readException(Parcel.java:1693)
at android.os.Parcel.readException(Parcel.java:1646)
at android.bluetooth.IBluetoothManager$Stub$Proxy.registerStateChangeCallback(IBluetoothManager.java:375)
at android.bluetooth.BluetoothAdapter.(BluetoothAdapter.java:640)
at android.bluetooth.BluetoothAdapter.getDefaultAdapter(BluetoothAdapter.java:621)
at com.mixpanel.android.mpmetrics.SystemInformation.isBluetoothEnabled(SystemInformation.java:144)
at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.getDefaultEventProperties(AnalyticsMessages.java:553)
at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.prepareEventObject(AnalyticsMessages.java:567)
at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.handleMessage(AnalyticsMessages.java:247)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:154)
at android.os.HandlerThread.run(HandlerThread.java:61)

I'm having this error too:
07-28 09:24:52.657 12893-13502/br.com.sltalk E/BluetoothAdapter: Application does not have bluetooth permission, registering is failed
07-28 09:24:52.657 12893-13502/br.com.sltalk E/BluetoothAdapter: java.lang.SecurityException: Need BLUETOOTH permission: Neither user 10529 nor current process has android.permission.BLUETOOTH.
at android.os.Parcel.readException(Parcel.java:1620)
at android.os.Parcel.readException(Parcel.java:1573)
at android.bluetooth.IBluetoothManager$Stub$Proxy.registerStateChangeCallback(IBluetoothManager.java:358)
at android.bluetooth.BluetoothAdapter.(BluetoothAdapter.java:598)
at android.bluetooth.BluetoothAdapter.getDefaultAdapter(BluetoothAdapter.java:580)
at com.mixpanel.android.mpmetrics.SystemInformation.isBluetoothEnabled(SystemInformation.java:144)
at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.getDefaultEventProperties(AnalyticsMessages.java:620)
at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.prepareEventObject(AnalyticsMessages.java:634)
at com.mixpanel.android.mpmetrics.AnalyticsMessages$Worker$AnalyticsMessageHandler.handleMessage(AnalyticsMessages.java:294)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:148)
at android.os.HandlerThread.run(HandlerThread.java:61)
                                                             [ 07-28 09:24:52.667 12893:12893 W/         ]
                                                             Unable to open '/system/framework/qcom.fmradio.jar': No such file or directory

Any updates on this issue?

guys, could you kindly tell me what are the devices you are seeing this issue on and their android version? thanks!

@patedit Samsung s7 Edge

same issue on S6 EDGE and S7 EDGE

what about the android version? is it only happening on N? Do you guys see something in common with all the devices? thanks!

Android API 7.0

both devices

Same here, on galaxy s7 edge

It seems like this bug is still not solved yet.
@patedit ,@Mixplanel  can you please resolve the problem ASAP...
We don't really want to have a BLUETOOTH permission in our manifest ..requesting this is really permission so bad for the UX..

I cant even download my app from play store from emulator because emulators does not have bluetooth!!! FIX IT

@dementia2029 Sorry, I am not sure I understand your problem. Whether you can or can't download your app from Google Play is unrelated to this issue.
Guys, hopefully this PR will solve your issue https://github.com/mixpanel/mixpanel-android/pull/499 I'll make a release today!

@patedit we can't download a released app (with mixpanel) from google play to our emulator because mixpanel requires bluetooth, if the device doesn't have bluetooth then the app wont show up in google play.

@adin234 because of this pull request Mixpanel no longer requires bluetooth. If you would like to remove the need from your manifest, make a release, and try installing on an emulator again, you may do so.

@levibostian i just explained to @patedit why this issue and the app not being downloadable from the store and an emulator are related

Thanks for the clarification @adin234 ! And nice profile pic 👨💻


Error since update to 2.0.1

Details
What steps did you take and what happened:
Changed app-template version from 2.0.0 to 2.0.1 ( 2.0.3 gives the same error )
What did you expect to happen:
Template rendered

Anything else you would like to add:
Im getting following error:
Error: template: vscode/charts/app-template/templates/common.yaml:14:3: executing "vscode/charts/app-template/templates/common.yaml" at <include "bjw-s.common.loader.generate" .>: error calling include: template: vscode/charts/app-template/charts/common/templates/loader/_generate.tpl:8:6: executing "bjw-s.common.loader.generate" at <include "bjw-s.common.render.controllers" .>: error calling include: template: vscode/charts/app-template/charts/common/templates/render/_controllers.tpl:25:12: executing "bjw-s.common.render.controllers" at <include "bjw-s.common.class.deployment" (dict "rootContext" $ "object" $deploymentObject)>: error calling include: template: vscode/charts/app-template/charts/common/templates/classes/_deployment.tpl:59:13: executing "bjw-s.common.class.deployment" at <include "bjw-s.common.lib.pod.spec" (dict "rootContext" $rootContext "controllerObject" $deploymentObject)>: error calling include: template: vscode/charts/app-template/charts/common/templates/lib/pod/_spec.tpl:61:12: executing "bjw-s.common.lib.pod.spec" at <include "bjw-s.common.lib.pod.field.containers" (dict "ctx" $ctx)>: error calling include: template: vscode/charts/app-template/charts/common/templates/lib/pod/fields/_containers.tpl:22:30: executing "bjw-s.common.lib.pod.field.containers" at <include "bjw-s.common.lib.container.spec" (dict "rootContext" $rootContext "controllerObject" $controllerObject "containerObject" $containerObject)>: error calling include: template: vscode/charts/app-template/charts/common/templates/lib/container/_spec.tpl:48:12: executing "bjw-s.common.lib.container.spec" at <include "bjw-s.common.lib.container.field.volumeMounts" (dict "ctx" $ctx)>: error calling include: template: vscode/charts/app-template/charts/common/templates/lib/container/fields/_volumeMounts.tpl:28:14: executing "bjw-s.common.lib.container.field.volumeMounts" at <eq (dig "statefulset" "volumeClaimTemplates" nil $controllerObject) nil>: error calling eq: uncomparable type []interface {}: []
Additional Information:

I'm using argocd and this is my values.yaml file, which works on 2.0.0:
app-template:
  # Common library: https://github.com/bjw-s/helm-charts/tree/main/charts/library/common
  # https://github.com/bjw-s/helm-charts/blob/main/charts/library/common/values.yaml
  # https://github.com/linuxserver/docker-code-server
  controllers:
    main:
      containers:
        main:
          image:
            repository: ghcr.io/linuxserver/code-server
            tag: 4.18.0
          env:
            TZ: "Europe/Warsaw"
            PUID: "1000"
            PGID: "1000"
            DOCKER_MODS: "linuxserver/mods:code-server-python3"

  service:
    main:
      ports:
        http:
          enabled: true
          port: 8443
          primary: true  # Assuming you want this to be the primary port based on your old values

  persistence:
    config:
      enabled: true
      type: persistentVolumeClaim
      size: 1Gi
      retain: true  # Assuming you do not want to retain the PVC upon `helm uninstall`

I get the same error on 2.0.1 and 2.0.2 on the exact example from the docs.

Thank you for reporting the issue. I will investigate and try to see what's going on

If it will help something. I've tested other deploy I've got, and it works with 2.0.3. I think difference is that it uses:
  persistence:
    config:
      enabled: true
      existingClaim: audiobookshelf-config

So maybe its in case that existingClaim for config is missing ?

I am also having this issue in v2.0.3 as well.
It works great in my FluxCD environment. However, trying to apply it manually for a project I have - that doesnt use gitops for my cluster - I get this error as well. Not sure if this information is helpful in troubleshooting but I thought I would share regardless.

Hmm... this is very strange. I just added the values from the OP to a values.yaml file and ran helm template -f values.yaml --debug and this works without any issue.
What Helm version are you using?

That looks to be the culprit. When I downgrade my Helm version to that, I see the same error. I will see if there is anything I can do about it.

I think I have found the problem and have implemented a fix in v2.1.0.

Great news, thanks !

Confirmed worked without problems, on problematic charts !


[WIP] - Copy analytics files from Briefs FE

This is the proposed approach to DRY'ing the GA related code. We have left _events.js out as we imagine this to be app specific. There may well be others as we progress.
https://trello.com/c/Jj4cz4u4/336-implement-a-custom-dimension-for-buyer-supplier-and-admin-in-ga
Paired with @katstevens

This should hopefully not require a major version bump now:

custom meta template can be pulled into FE apps whenever it is needed
the 'new' analytics files can be linked in the FE app's /app/assets/javascripts/_analytics.js whenever they're ready to be used (and the old assets analytics files deleted)


ImportError: cannot import name 'CronSlices' from 'crontab'

I've just installed detect-secrets-server on Ubuntu 20.04
but, when I try to add a local repo, I get this error:
detect-secrets-server add /home/samir/projects/website --local
Traceback (most recent call last):
  File "/usr/local/bin/detect-secrets-server", line 5, in <module>
    from detect_secrets_server.__main__ import main
  File "/home/samir/.local/lib/python3.8/site-packages/detect_secrets_server/__main__.py", line 6, in <module>
    from detect_secrets_server.core.usage.parser import ServerParserBuilder
  File "/home/samir/.local/lib/python3.8/site-packages/detect_secrets_server/core/usage/parser.py", line 6, in <module>
    from .add import AddOptions
  File "/home/samir/.local/lib/python3.8/site-packages/detect_secrets_server/core/usage/add.py", line 4, in <module>
    from crontab import CronSlices
ImportError: cannot import name 'CronSlices' from 'crontab' (/usr/local/lib/python3.8/dist-packages/crontab/__init__.py)

any idea?

Just ran into this same issue. Not sure if you've figured it out, but for anyone else who sees this, you probably have crontab installed instead of python-crontab

Getting the same error, looks like the requirements.txt are not included in the PyPi package?

If you run pip install detect-secrets-server then python-crontab will not be installed. If you run pip install detect-secrets-server[cron] then everything should be fine. While the latter command is in the install instructions, I think python-crontab should just be included by default to reduce confusion.


Bug during Second Stage Training

So I tried to follow the first, second training approach. The first stage went through with little problems, but when I use the second training stage after a few iterations I get this message. I set the first_stage_path parameter to the model I trained in the first stage.
Then I set second_stage_load_pretrained to False. I use a LJSpeech style dataset with a single speaker, directory structure is exactly the same as in LJSpeech. Any ideas what leads to this kind of behaviour?
Traceback (most recent call last):
  File "/raid/nils/projects/StyleTTS2/train_second.py", line 788, in <module>
    main()
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/click/core.py", line 1078, in main
    rv = self.invoke(ctx)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
  File "/raid/nils/projects/StyleTTS2/train_second.py", line 308, in main
    bert_dur = model.bert(texts, attention_mask=(~text_mask).int())
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1518, in _wrapped_call_impl
    return self._call_impl(*args, **kwargs)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1527, in _call_impl
    return forward_call(*args, **kwargs)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/nn/parallel/data_parallel.py", line 185, in forward
    outputs = self.parallel_apply(replicas, inputs, module_kwargs)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/nn/parallel/data_parallel.py", line 200, in parallel_apply
    return parallel_apply(replicas, inputs, kwargs, self.device_ids[:len(replicas)])
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/nn/parallel/parallel_apply.py", line 110, in parallel_apply
    output.reraise()
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/_utils.py", line 694, in reraise
    raise exception
RuntimeError: Caught RuntimeError in replica 0 on device 0.
Original Traceback (most recent call last):
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/nn/parallel/parallel_apply.py", line 85, in _worker
    output = module(*input, **kwargs)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1518, in _wrapped_call_impl
    return self._call_impl(*args, **kwargs)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1527, in _call_impl
    return forward_call(*args, **kwargs)
  File "/raid/nils/projects/StyleTTS2/Utils/PLBERT/util.py", line 9, in forward
    outputs = super().forward(*args, **kwargs)
  File "/raid/nils/projects/StyleTTS2/venv/lib/python3.10/site-packages/transformers/models/albert/modeling_albert.py", line 719, in forward
    buffered_token_type_ids_expanded = buffered_token_type_ids.expand(batch_size, seq_length)
RuntimeError: The expanded size of the tensor (780) must match the existing size (512) at non-singleton dimension 1.  Target sizes: [2, 780].  Tensor sizes: [1, 512]

Your text (and audio) is too long. Your text cannot be longer than 512 tokens due to PL-BERT limitations (max context length 512).

@yl4579 Hello I am facing the same issue, is there any implementation since then which could handle long-formed sentences? would highly appreciate it.

I vote for Longformer! BTW, thank you for your work!


optimize with str.format(**dict)

I got an unicode error while trying to run this:
> python -m soccer.main --players --team AFC
 File "soccer\writers.py", line 118, in team_players
    click.secho(fmt.format(**player), bold=True)
 UnicodeEncodeError: 'ascii' codec can't encode character u'\u20ac' in position 11: ordinal not in range(128)

Therefore, we'll need to make sure the strings are unicode:
    fmt = (u"{jerseyNumber:4} {name:28} {position:23} {nationality:23}"
           u" {dateOfBirth:18} {marketValue}")

Using __future__ import unicode_literals seems to be throwing an error somewhere else (I don't have the time right now to debug it), but if you can fix that, I think using this might be better.

I made the suggested changes.  Sorry about that.

Thanks. If you fix the padding issues, then we'll be good.
Before:

Now:

str.format() left aligns text but right aligns numbers.  In this last mod, I forced everything to be left aligned.

Thanks @cclauss! :+1:


Add start and step buttons and algorithm dropdown

Add pygame-gui for enhanced GUI elements

Reverted the merge due to the sneaky --amend commit


Sensor Initialization Failed - Compatible with ESP32 ?

Hello, I am trying to use this library on a ESP32.
I changed in the library the file "PWM3360.cpp" and remplaced SPI.begin() by   SPI.begin(18, 19, 23, ss_pin) ; because MISO, MOSI and SCK pins aren't the same.
I tried to use the "basic_interrupt" example but I keep getting the issue "Sensor Initialization Failed". I am sure of the hardware part. I am wondering if the library is compatible with ESP32 ?
Thank you

Let's discuss here:
https://github.com/SunjunKim/PMW3360/issues/2#issuecomment-892851121


Formatter.PrettyPrint not thread safe

Formatter.PrettyPrintmanipulates theprivate static string _indent` variable which is not thread safe.
Possible solutions:

Change the class to non-static.
Use C# 7 local function or delegate for AppendIndent.

Also, Formatter.PrettyPrint(string input) should use JSON.Parameters.FormatterIndentSpaces and not always three spaces.
Also, it would be handy to have JSON.Beautify(string input, string indent) for custom indent (e.g. a tab).

Thanks!
I will look into it.

fixed in v2.2.2

Thanks for a quick fix. 👍
You have left some commented out old code in the Formatter.cs.
I miss a bit JSON.Beautify(string input, string indent) but that's not so important. (Maybe the JSON.Beautify methods are obsolete?).
It's possible to close this issue.


Using the Navigator

I'd like to find out if there is a prescribed way to use the Navigator when using built_redux.
I have a screen that has a button to trigger a call to the server - the button dispatches an Action that is handled by Middleware. The Middleware sends a request to the server and dispatches a success or error action depending on the result. I have reducers update the state depending on the result, which redraws the current screen. That's fine if the response was an error because we want to display it on the same screen.
However, if the server response was successful, I want to navigate to a different screen, but I haven't found a clean way to do that. (Creating a delayed future in the StoreConnector seems wrong, and calling the Navigator from the build method triggers an error.)

Looks like the approach for this is creating a GlobalKey<NavigatorState> and inject it into the middleware layer (or access it as a global, though that's less testable).
https://github.com/brianegan/flutter_redux/blob/simple-navigation-example/example/lib/main.dart#L20
Just have to remember to set the key when creating the MaterialApp.
Perhaps there's a good place to document this?

Hmm i'm not sure the best place to document this. Probably not here because this is pretty flutter specific and built_redux itself is platform agnostic, ie it works for vm, web, or flutter.
Maybe adding it to the example over at flutter_built_redux?

Yes, good point that it's specific to Flutter; I think that would be a good place to put it. When we started trying to figure out these types of things, we found that the examples were just a little too bare-bones to answer some of these more in-depth types of issues.
I'll close the issue here and open one against that repo, referencing this one.


[staging] go_1_21: 1.21.1 -> 1.21.3

Description of changes

maintainers/team-list: add mfrw to golang team
go_1_21: 1.21.1 -> 1.21.3
Changelog: https://go.dev/doc/devel/release#go1.21

Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
23.11 Release Notes (or backporting 23.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

Is there anything blocking this from being merged? 1.21.3 released today addressing CVE-2023-44487 and targeting staging this will take a while.

I will upgrade this PR in place to move to 1.21.3; Thank you for the pointer.

Ah, ok. Can you target staging-next please? That's two security releases of varying severity, even with the rebuilds it should at least take the shortest path to master as 1.21.3 affects commonly used software like Traefik. I'll happily merge it.


mqtt message localization is complete

Add point clouds and detect when localization is complete.
Receive mqtt message localization is complete, state, per user. This is useful for avoiding multi user re localization of the scene

Add point clouds
What's this part

Point clouds was just a reference to one method students were using to align the scene, probably ancillary to the feature. As long as they have access to a "localization complete" message, I think they can manage any pre-alignment themselves.


LibWeb: Restore event characteristics of MouseEvents

Fixes #660
Contributes to #102

cc: @caitp @tcl3

we need to make the same change for WheelEvent, right?

Yes, that would be nice

Can it be merged now?

Thank you 👏