PowerPC VLE e_rlwinm and e_rlwimi bit mask generation incorrect

These two instructions generate a bit mask using operands NB and ME.  The operands are defined in the ppc_common.sinc file as "ME=(1,5)" and "NB= (11,15)".  ME looks correct but NB is incorrectly set to the same location as the bit bit shift field "SHL=(11,15)".
I think the definition of NB in ppc_common.since should read "NB=(6,10)" instead.
As an example "74 63 37 7F" decodes using as "e_rlwinm A,S,SHL,NB,ME" with fields:

 OP=(26,31)    = 011101

 S=(21,25)     = 00011   gives r3

 A=(16,20)     = 00011   gives r3

 SHL=(11,15)   = 00110   0x06 ,     But NB=(11,15)  so gets 0x06

     (6,10)    = 11101              NB should (6,10) to go here and get 0x1D

 ME=(1,5)      = 11111   0x1F

 BIT_0=(0,0)   = 1

Which gives the incorrect current behavior:
08fd4168 74 63 37 7f     e_rlwinm   r3,r3,0x6,0x6,0x1f
Whereas the expected correct behavior taking NB=(6,10) would be:
08fd4168 74 63 37 7f     e_rlwinm   r3,r3,0x6,0x1d,0x1f
For reference the VLE reference manual e_rlwinm instruction is shown below.  Note that Ghidra uses NB in place of MB and that the manual's bit ordering needs to be reversed.  So operand MB at bits 21..25 would correspond to NB(6,10).

Duplicate of #752


Try using Observability Platform

User Story
As a Modernisation Platform engineer
I want to have one dashboard for all alerting
So that I have a better visibility of it.
Value / Purpose
Better health of the platform through better observability.
Additional Information
This is in particularly to look into plugging into the existing Observability Platform following this user guide.
This is to implement a PoC using one account as an example and to learn whether it is the right tool for the MP short term. The PoC should also evaluate which accounts should be included if we wanted to use it on the whole platform level (and to see if it would vary from one account to another).
Jacob W has confirmed he is available to help if required.
Definition of Done

[x] PoC is implemented for one account
[x] List of accounts it should be enrolled to (if implementing it further) is documented
[x] Differences between enrolling it into various accounts are understood and documented
[x] Another team member has reviewed the PoC solution
[x] Deployment pipeline runs clean
[x] Solution is demoed to the team and the next steps are agreed
[x] Follow on ticket(s) are created (if any)

Follow on ticket to be created,


siconos_vview crashes due to "OSError: [Errno 24] Too many open files"

The command siconos_vview siconos_mechanisms.hdf5  in  siconos-tutorials/examples/mechanics/Mechanisms/Trip_Magnetic
crashes. The context manager tmpfile does not close the file
Traceback (most recent call last):
  File "/Users/vincent/.local/bin/siconos_vview", line 23, in <module>
    vview.run()
  File "/Users/vincent/.local/lib/python3.11/site-packages/siconos/io/vview.py", line 2997, in run
    self.initialize_vtk()
  File "/Users/vincent/.local/lib/python3.11/site-packages/siconos/io/vview.py", line 2953, in initialize_vtk
    self.init_shapes()
  File "/Users/vincent/.local/lib/python3.11/site-packages/siconos/io/vview.py", line 1915, in init_shapes
    self.init_shape(shape_name)
  File "/Users/vincent/.local/lib/python3.11/site-packages/siconos/io/vview.py", line 1704, in init_shape
    reader = topods_shape_reader(e)
             ^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/vincent/.local/lib/python3.11/site-packages/siconos/io/mechanics_hdf5.py", line 438, in topods_shape_reader
    print( "get_open_fds() is: ", get_open_fds() )
                                  ^^^^^^^^^^^^^^
  File "/Users/vincent/.local/lib/python3.11/site-packages/siconos/io/mechanics_hdf5.py", line 413, in get_open_fds
    raw_procs = subprocess.check_output(
                ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/subprocess.py", line 466, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/subprocess.py", line 548, in run
    with Popen(*popenargs, **kwargs) as process:
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/subprocess.py", line 1026, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/subprocess.py", line 1849, in _execute_child
    errpipe_read, errpipe_write = os.pipe()
                                  ^^^^^^^^^
OSError: [Errno 24] Too many open files

fix with e9eec95


SQL Server Management Studio not installed.

Some of my remote students are getting this message when trying to install SSMSExecutor on their computer. They all have SSMS 19 installed so that’s obviously not right.
What does this message mean and is there a way around it?

Hi @manngo,
the installer needs to know where SSMS is installed. So it checks the registry key Computer\HKEY_CURRENT_USER\Software\Microsoft\SQL Server Management Studio\<internal version>_config\InstallDir.
For SSMS 2019 (v18) the registry key should be Computer\HKEY_CURRENT_USER\Software\Microsoft\SQL Server Management Studio\18.0_IsoShell_Config\InstallDir.
Microsoft changed the SSMS naming and it is confusing. When you say SSMS 19, do you mean SSMS 2019 (v18) or SSMS v19.
Can you check with your students witch exact version of SSMS do they have installed (Help > About). And what is stored in the registry key above.
The extension currently does not support SSMS v19 and SQL Server 2022. I am planning to upgrade it soon.

I mean SSMS v19. I know about the versioning confusion here, and also that the call it version 15 in the vssettings XML file, just in case it wasn’t confusing enough.
As far as I am aware they’re all using SQL Server Express, the currently available version. Are you saying that the server version also affects its behaviour?

Is there any progress on getting this to work with v19? Is there something we can bandaid to get this going?

Cloning the repository, building with Visual Studio 2017 and pointing to the SSMS 19 instalation worked for me as a workaround.

Cloning the repository, building with Visual Studio 2017 and pointing to the SSMS 19 instalation worked for me as a workaround.

Is there a chance of your sharing this? I don’t have the tools or experience to do this myself.
Thanks


Python 2 Compatibility

Since this tool might be used by people other than programmers, complete compatibility with Python2 is a desirable feature. Almost all the code is already backwards compatible and the only (minor) issue is in the two print statements in the main function (line 39 and line 43), which, in Python2, currently print something like
('Password1', 'was found')

These can be easily modified to use string formatting so as to make the code 100% compatible with Python2 and produce the same results regardless of the version.
In other words, change print(pwd, "was found") to print("{} was found".format(pwd)) and print(pwd, "was not found") to print("{} was not found".format(pwd))

If those are the only two changes, why not make a quick PR?

@ToonSpin Just wanted to check if it's worth it, this can be deemed borderline pedantic. Also I didn't think about versions of Python older than Python2.6, so putting this out here increases the chances of finding other bugs (if they exist) in the older versions, and then all the fixes can be incorporated in one go.

Hi, thanks for this. Perfectly happy for you to tweak the code in a PR and i'll merge it. Please make sure it remains compatible with Python 3! :)

#11 implements these changes, while maintaining compatibility with Python 3.

Thanks! 👍

Sorry to bring it up again, but I think #12 kind of breaks this with
#!/usr/bin/env python3

As I have both Python 2 and Python 3 installed on my system so I don't know how that shebang behaves on a system with just Python 2 installed. Although, as per this StackOverflow answer I believe it's safer to use the following shebang (we qualify for the rare case mentioned there)
#!/usr/bin/env python

As long as the script is both Python 2 and 3 compatible I do believe that @aditya95sriram's is a good shebang line to use.

@ToonSpin And keeping the script Python 2 compatible is what I'm proposing. Because the target users of this repo need not be programmers and might be people who stick with the default Python installation their system came with, which in many cases is Python 2.

I was wholeheartedly agreeing with you, that's all. :) My opinion probably doesn't really matter because it's not my repo, but you were saying sorry for bringing it up, and I felt that you were right, so I wanted to show support.
My comment is trying to say that it's not always the right shebang, but because you and Mike feel things should be Python 2 and 3 compatible (which I think is a good thing), I think changing the shebang is the right thing to do, but I guess it didn't come out right.

@ToonSpin no offense taken 😄

You're both right - I didn't spot the 3! I'll make the change, it's best to preserve compatibility, most installations will have a symbolic link between python to whichever anyway.

As the SO answer states

The reason for these recommendations, given in PEP 394, is that python can refer either to python2 or python3 on different systems.

Whichever it is, it can only refer to an installed version and since we're covering all our bases this shebang is perfect for us.
Also to prevent issues like this from happening in the future, maybe you should add a line in the readme asking people to preserve compatibility in their PRs.


Wrong color for camel cased constants

Hello,
I came across this strange bug in PHP.
Camel cased constants have a different colour than regular constants.

VSCode version: 1.2.0
Extensions: All disabled except for the latest Material Theme version
Settings: All set to default

It's ok with other colour themes so it can't be expected behaviour. Any ideas?

I will investigate. Right now i have no idea about the cause.

Hi @TitasGailius I found a little bug (i think) in the php extension. It provide a different scopes:
The first one is recognised as support class

The second one is recognised as "other constant"

I can only set the color for "other.constant" scopes, but this will afflict all the other variables.

I see developers use these scopes for PHP classes, do you think it might be a solution?
{
    "name": "Library class/type",
    "scope": [
        "support.type",
        "support.class"
    ],
    "settings": {
        "foreground": "#FFCB6B"
    }
},
{
    "name": "User-defined constant",
    "scope": [
        "constant.character",
        "constant.other"
    ],
    "settings": {
        "foreground": "#FFCB6B"
    }
},

The issue is that i have two completely different scopes. I can't make the camelcase one yellow, because use the same scope of other variables. I can only make grayish the not camelcase one.

Yeah, making it grey-ish is a solution and maybe it's even a better one because it makes it easier to differentiate classes from constants although that's not how most themes that I've used behave.
For my personal liking, I wanted it to be consistent so I added this override to my vs-code config which perfectly solves the issue:
    "editor.tokenColorCustomizations": {
        "textMateRules":[
            {
                "scope": "constant.other.php",
                "settings": {
                    "foreground": "#FFCB6B"
                }
            }
        ]
    }

@TitasGailius In your config you are changing the color of the second one, not the first one.

Yes, I know.
What I meant is that from my experience on how other themes behave and for my personal liking I wanted it to be yellow as it's more consistent. :)

Ok, I think I can release a fix with yellow constant.other.php.

Fixed in the new release


Bugfix/home page typo #2

TEST

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.:x: LamTrinh-princess sign nowYou have signed the CLA already but the status is still pending? Let us recheck it.


Accept filedisk.Disk instances as well as file paths.

https://www.npmjs.com/package/file-disk

@jhermsmeier Does this overlap with some of the stuff that you've been doing recently??

@lurch I guess this could be done with disk and/or mbr, gpt etc. as well – but that ship has already sailed, from what I can see (meaning there'd need to be quite some API-bending). Not something to change in this PR.

Sorry, I didn't mean this PR specifically (sorry I didn't make that clear) I meant this repo in general...

And I guess file-disk is what I use my blockdevice for – which is the base API which my disk image formats implement – so that you can use disk or other modules with any other module implementing a format or actual block device without having to change anything.

CI builds are failing with e.g.
2.46s$ nvm install 0.12
Downloading and installing node v0.12.18...
Downloading https://nodejs.org/dist/v0.12.18/node-v0.12.18-linux-x64.tar.xz...
######################################################################## 100.0%
Computing checksum with sha256sum
Checksums matched!
Now using node v0.12.18 (npm v2.15.11)
$ node --version
v0.12.18
$ npm --version
2.15.11
$ nvm --version
0.33.2
before_install
13.56s$ npm install -g npm@latest
/home/travis/.nvm/versions/node/v0.12.18/bin/npm -> /home/travis/.nvm/versions/node/v0.12.18/lib/node_modules/npm/bin/npm-cli.js
<EMAIL_ADDRESS>/home/travis/.nvm/versions/node/v0.12.18/lib/node_modules/npm
4.24s$ npm install
npm WARN npm npm does not support Node.js v0.12.18

I guess the tests themselves need some TLC before this PR can be merged?


Hey Buddy just cloned your repository but I am seeing a blank black screen on the window after running and nothing else can u help me with this

Man, I am sorry that I reply so late, I rarely check this page.
Shaders can't be compiled, can I know your pc specs?

So sorry I just saw your Reply.
Processor	Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz   1.80 GHz
Installed RAM	8.00 GB (7.86 GB usable)
System type	64-bit operating system, x64-based processor

lol, so long time.
I have just checked your GPU, so it is obvious that it can't be compiled, because your intel hd 620 supports only OpenGl 4.4, when this project is built with OpenGl 4.6 (my assumptions).
It seems that I have to recompile this project with an older version actually : )
My new project (Pengine) is built with an older version, you can check it out.


Fixed paths to work on other OSs

I can confirm that TES3Merge can be built on Linux if built using mono's fork of msbuild, however the paths need to be fixed to allow it to interact with the filesystem properly.
I've removed backslashes from paths and added calls to Path.Combine to ensure that the proper separator is used depending on the OS. I left the separators for the registry as they were, given that it's not really meaningful to look in the registry for the installed location of Morrowind on other operating systems, even though mono does actually provide a registry of sorts.

Excellent, thanks for the contribution.


Lead: Creating a new Lead manually

[ ] CRM > Lead
[ ] Enter Name, Organization, Campaign, Next Contact by
[ ] Save lead

To test:

[ ] Lead ID
[ ] Check if Calendar event is added for the Next Contact Person

//Test case written
context('Table MultiSelect', () => {
beforeEach(() => {
cy.login();
});
it('Generate a New Lead', () => {
cy.new_form("Lead");
cy.fill_field("lead_name", "Michelle", "Data");
cy.fill_field("customer_group", "Commercial", "Link");
cy.fill_field("company_name", "Mednet", "Data");
cy.fill_field("contact_date", "11-12-2019 14:02:14", "Datetime");
cy.fill_field("contact_by"<EMAIL_ADDRESS>"Link");
cy.save();
cy.submit();
});
});


[Butterfly Aspect] mage grid & some improvements

Changes / Comments

add default Modifier for schicksal
add dmg Modifier
change mage grid

Roll20 Requests
Comments are very helpful for reviewing the code changes. Please answer the relevant questions below in your comment.

[ ] Does the pull request title have the sheet name(s)? Include each sheet name.
[ ] Does this add functional enhancements (new features or extending existing features) ?
[ ] If changing or removing attributes, what steps have you taken, if any, to preserve player data ?

Character Sheet Info Roll20 Internal Use only.

Character Sheet Info Roll20 Internal Use only.


Update dependencies

Type

Infrastructure

Description
Update dependencies, especially react router which now has hooks. We can use them instead of wrapped components in our code. This will avoid the need to pass props when writing tests for components that use router API.
Also, react has got a new update. There was a breaking change for use-resize-observer, so I did not update it.
Checks

npm test - OK
npm run check-types - OK
dev build - OK
prod build - OK
storybook - OK

@azangru I had to push another commit after updating the dev dependencies. I'll update the description to reflect this.

👌


Docs site is down

Describe the bug
When I visit any of the links to the docs, they return this error page

Reproduction
Visit https://gql-tada.0no.co/ (from the link from the issue template below)
gql.tada version
N/A
Validations

[X] I can confirm that this is a bug report, and not a feature request, RFC, question, or discussion, for which GitHub Discussions should be used
[X] Read the docs.
[X] Follow our Code of Conduct

For anyone stuck, for now, I'm just reading the source code here https://github.com/0no-co/gql.tada/blob/main/website/get-started/index.md

We are aware, CloudFlare is stuck in validating SSL for some reason

It seems fine now 🚀
https://gql-tada.0no.co/


Extra compiler/linker options in Package.swift

Add otherCompilerOptions and otherLinkerOptions in Package for Package.swift

Worth noting that there was some previous discussion over at #73 and SR-145.

Thanks, this is something that maybe we need. However, please provide a usecase that justifies this so we can discuss the ramifications.

@mxcl Take a look at SR-145 SR-15 SR-83, which I believe are related (there are probably more). Also, I emailed you about this describing my situation in depth a few days ago as well.

Thanks, for these issues we'd like to solve this with modifications to how module map packages work.
I will be writing up a proposal for this hopefully today.
We are not opposed to supporting arbitrary command line options but we want to avoid it as long as possible, supporting such things offers power and flexibility to developers they may need, but it also causes build problems that can be difficult to fix for end-users who don't understand the packages they are consuming that well.

@mxcl How is different at the end? If we specify header path in modules, it will still cause problems if something is missing and it will be hard to consume it anyway.
I understand your rationale but I am not sure how module maps can improve it. Plus changing the way how module maps work require changes in Clang if I am not mistaken.

Passing arbitrary commands does not allow us any control or mitigation. Specifying paths in the module map allows us to control how and where these paths are input to the toolchain.

Allowing packages to specify any flags they like allows more control than we think is sensible. While we respect the fact sometimes it is frustrating when you have less control we have learned from the mistakes of previous build-systems and packaging systems and would like to be restrictive in order to prevent exotic and hard-to-fix dependency hell scenarios.

@mxcl I agree that module.modulemap is the right place to define all required headers and libraries for the specific module, this should be done by the module.
Even though module.modulemap will bring this ability and eliminate needs to specify -I <header_path> in Package.swift, it is still good to have a way passing options to underlying build system.
This is the use case that I consider about this 'other compiler/linker options'. (of course this case might be just for system module developers, not for all users)
While I write module.modulemap of some library for my tiny project as POC, it is really annoying that I should commit/tag whenever it is modified/tested. so, I took advantage of my PR changes of Package.swift like below...
import PackageDescription

let LIB_ROOT = "<place of my development version of lib instead of OS lib path>"
let SRC_ROOT = "<place of my project>"

let cflags = [
    "-I\(LIB_ROOT)/include",
    "-I\(SRC_ROOT)/ModuleMaps",
    "-F-module-map=\(SRC_ROOT)/ModuleMaps/CZeroMQ/module.modulemap",
]

let lflags = [
    "-L\(LIB_ROOT)/lib",
    "-lzmq",
   "-lczmq",
]

let package = Package(
	name:"Hello",
	// dependencies: [
	// 	.Package(url:"../CZeroMQ", majorVersion:1),
	// ],
	otherCompilerOptions:cflags,
	otherLinkerOptions:lflags
)

Of course I could separate system module when it is ready for release, but while module.modulemap is not yet concreted, it is really useful that I can specify module.modulemap file with -F-module-map. This is not proper way for end user but the point is it can help system developer not to commit/tag every time he/she edit/test the file.
Since SPM produces llbuild.yaml as final output for low level build system, I hope SPM could have enough flexibility.

I think there is value in discussing the possibility of this feature for terminus-packages (ie. root-packages, the package swift-build builds). My main concern is avoiding dependency hell scenarios. My secondary concern is preventing packages at any part of the graph from demanding build settings that are fragile.
Build toolchains are fundamentally fragile. One only has to browse the comments and ratings for popular IDEs to appreciate that. We strongly desire to reduce fragility.
We can solve you motivating problem: that it is tedious to tag packages you are developing, and have intention to do so with some concept of "dev packages".

It is worth noting that the existing of arbitrary search paths is exactly one thing which makes good module support very difficult (because modules from the Clang perspective are intimately intertwined with header search paths, and allowing any project to contribute them is a recipe for disaster). One of our goals in trying to maintain tight control over the dependencies is to try and deliver a much more reliable experience in the long run...

@mxcl @ddunbar Thanks for clarifying SPM's direction. It is helpful to understand it.
Look forward modulemap to solve the issue.


Remove some unsafe code

Just removing some more unsafe code from the task system.

Looks good to me. Thanks!


merge audio fails on archive

Describe the bug
When attempting to archive using merge mode audio, crunchy-cli instead produces the following error:
An error occurred: invalid type: null, expected u32
To Reproduce
Steps / command to reproduce the behavior:
$ crunchy-cli archive --merge audio https://www.crunchyroll.com/series/G6J0G49DR/tower-of-god

Expected behavior
it should not error, and instead download the specified content.
Screenshots

Client (please complete the following information):

OS: macOS Senoma 14.3.1
Version: 3.3.0 (88a28e8 2024-03-10)

Additional context
This happens due to 56f0ed1795d971fb4342b9f0a66216e8af18fd6f, changing that to None provides a temporary workaround however. command.patch

Thanks for reporting. The issue originates from Crunchyroll (ONCE FCKING AGAIN) not delivering consistent api results. I fixed it in v3.3.1


Missing tags/versions

Hi - I realise you're in the process of recovering this repo, please if possible let me know when you have recovered the other tagged versions. I should have a version of 1.3.0 (for v4 support) on disk if you need a commit. Priority of getting this back onto packagist as well as there is now failing deployments.

This should be able to be restored, however - through an organisation settings. The re-creation of a repository is undesirable entirely:
For an organization:

In the upper-right corner of GitHub, select your profile photo, then click Your organizations.
Next to the organization, click Settings.
In the left sidebar, click Deleted repositories.
Next to the repository you want to restore, click Restore.
Read the warning, then click I understand, restore this repository.

Thanks @samandeggs , evidently there are complications with restoring deleted repositories when those repos have forks.
We're looking to resolve this with Github, so have added this temporary repo with a slightly different name.
I don't currently have other versions to tag and push.

I have forked this repo, created an orphaned branch (silverstripe-4) and pushed 1.3.0 that I had a copy of, to it and tagged it as 1.3.0. I wont pursue this further than that, but it's ready in case of need. Hopefully the restoration is successful.


Problems interfacing with Kensington Expert Mouse USB trackball?

Hello,
I'm not quite sure how to make a MWE for this bug, but I just downloaded this software today (from commit d42f533a144c7ba82bf6aa4e8c8591412e39d08d) for my WASD keyboard. It works well, but I noticed that my 4th and 5th mouse buttons have been remapped to "mute" and "fastforward".
The best I can do for a MWE is to give you the results from the EventViewer:
eventType:MouseDown       code:0x0        name:left            flags:                                   misc:{751,113} 1
eventType:MouseUp         code:0x0        name:left            flags:                                   misc:{751,113} 1
eventType:MouseDown       code:0x1        name:right           flags:                                   misc:{751,113} 1
eventType:MouseUp         code:0x1        name:right           flags:                                   misc:{751,113} 1
eventType:ScrollWheel     code:           name:                flags:                                   misc:dx:0.000 dy:-1.000 dz:0.000
eventType:ScrollWheel     code:           name:                flags:                                   misc:dx:0.000 dy:-1.000 dz:0.000
eventType:ScrollWheel     code:           name:                flags:                                   misc:dx:0.000 dy:-2.000 dz:0.000
eventType:ScrollWheel     code:           name:                flags:                                   misc:dx:0.000 dy:-1.000 dz:0.000
eventType:ScrollWheel     code:           name:                flags:                                   misc:dx:0.000 dy:-2.000 dz:0.000
eventType:SysKeyDown      code:0x7        name:mute            flags:                                   misc:
eventType:SysKeyUp        code:0x7        name:mute            flags:                                   misc:
eventType:SysKeyDown      code:0x7        name:mute            flags:                                   misc:
eventType:SysKeyUp        code:0x7        name:mute            flags:                                   misc:
eventType:SysKeyDown      code:0x13       name:fastforward     flags:                                   misc:
eventType:SysKeyUp        code:0x13       name:fastforward     flags:                                   misc:

I had these particular buttons assigned to Application Windows and Mission Control, respectively. I'm using Kensington TrackballWorks version 1.3 and am on OSX 10.12.4 with a 2.9 GHz Intel Core i7

I have found a solution to the problem. It appears that the trackball was being detected as an Apple keyboard. By unchecking the device from the list of modified devices, I was able to return it to its normal working state.

Unless there's a solution to explicitly detect this particular trackball, I'll close this issue as the solution I found works adequately.


Add more validation of IPPool CRD

Validate IP version and prefix length fields.
Signed-off-by: Jianjun Shen<EMAIL_ADDRESS>

Codecov Report

Merging #3570 (d35af17) into main (ce0de59) will decrease coverage by 20.55%.
The diff coverage is 42.85%.

@@             Coverage Diff             @@
##             main    #3570       +/-   ##
===========================================
- Coverage   63.94%   43.38%   -20.56%
===========================================
  Files         278      210       -68
  Lines       27838    25234     -2604
===========================================
- Hits        17802    10949     -6853
- Misses       8110    13198     +5088
+ Partials     1926     1087      -839

Flag
Coverage Δ

kind-e2e-tests
?

unit-tests
43.38% <42.85%> (+0.02%)
:arrow_up:

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


Create new release and update podspec

Thank you for merging my pull request! However could you please create a new release, and update the version number in the podspec of this repository? This way the fix becomes available for CocoaPods users too.

Any chance CocoaPods will be updated to support the latest code?


Add NUnit templates by default to dotnet test

Description
Currently a user needs to run dotnet new -i NUnit3.DotNetNew.Template
before they run dotnet new nunit in order to create an NUnit project. Since mstest and xUnit templates are shipped with the dotnet cli we should also include the NUnit ones to make it easier for users to discover.
Steps to reproduce

Install dotnet cli
Run dotnet new nunit

Expected behavior
Create an nunit project.
Actual behavior
Use sees no suggestion to install NUnit templates or indication that they do exist for .NET Core:

@kendrahavens This needs to be tracked on the dotnet core repo for templates


Installing and activating recommended modules

Modules can provide a rather unique experience for GM and players. But it is necessary to install them individually and, in the game, activate them all.
I was wondering if there would be a way to offer GMs along the import system.json a list of modules that would be installed alongside the game aid and automatically activated when the world is created.

This is complicated. First, some GMs may not want certain modules. Some modules have dependencies and installing many modules at once can give you some conflicts. I as a gm prefer to go testing one by one the modules that best suit to my needs.

I am going to close this, since this seems to be more of a "Foundry" thing, than a "GURPS" thing.


Split up FFunction's issues

Search: organizations and people should always have an area, a site or a nearby site, with at least lng/lat coordinates (ideally a GeoJSON feature) so that they can be mapped #4
Organization/Person detail: areas, sites and event_nearby don't have any GeoJSON feature or lng/lat couple, so we can't populate the Minimap #4
Clustering: anything that needs to be clustered should have a lat/lng coordinate (centroid if it is a polygon). We'll be able to do clustering on the front-end for <1K elements. #4
Some organizations are referenced but have no data #21
The organization chart contains duplicate nodes, we prune them but that might not be the best strategy #22

Moved to new issues.


gzip support？

how to use？Thank you！

@sujiewen
This is not a support forum. For any usage questions that are not specific to the project itself, please ask on Stack Overflow instead.
Thank you.


Tests: clean up remnants of the old string extensions

This cleans up the remaining instances of the
String.nativePathString() and String.escaped() which were overly
broad extensions and poorly named in favour of the new
AbsolutePath.nativePathString(escaped:) and
VirtualPath.nativePathString(escaped:).

@swift-ci please test


Getting the card brand name

require 'credit_card_validations/string'

'4242 4242 4242 4242'.brand # => :visa
puts '4242 4242 4242 4242'.brand # => "visa"

But how do I get the readable credit card brand you've listed in the readme i.e. "Visa" for :visa, or "American Express" for :amex?

@yazinsai , there is no "readable" strings inside gem like in README.
but you can use locales for this if you need

Thanks for the suggestions @Fivell, I'll be using them for my project.
For the benefit of other users, I think would be great to have it in the gem itself (in case other cards are later added).
Would you like me to send in a PR?

@yazinsai , I agree that  some sort of "full brand name"  can be useful in some cases.
do you want to implement something like ?
'4242 4242 4242 4242'.brand_name # "Visa", "American Express", etc

BTW, PR are always welcome !

@Fivell exactly!

@Fivell a few questions I'll need your help with:

Where should the brand names be stored? I initially thought of including them in card_rules.rb since they're all listed there, but that seems like a conflict of concerns. Would like your input on that.

Would be good with a backwards-incompatible change to add_rule?
Before: add_rule(brand, length, prefixes, skip_luhn = false)
After: add_rule(brand, length, prefixes, brand_name, skip_luhn = false)

@yazinsai,  card_rules.rb is just storage for initial data (in future it should be plain yaml file) I think there is no other place to store new info, so it is good enough for now.
About  add_rule method, it starting to  smell because of too many arguments count.
Maybe it is better to use options  hash to incapsulate arguments that don't contain detecting logic.
Sort of
add_rule(brand, length, prefixes, options)
options can contain not mandatory attributes:
skip_luhn - # treated as false if was not  passed
brand_name # just for overriding default behaviour which is capitalizing first letter.
So it is not needed to pass Visa for visa and Maestro for maestro , etc .  But American Express for amex and JCB for jcb, etc.
Also I don't think it can be backwards-compatible,  also method become more generic so maybe it will be better to create add_brand method and deprecate  add_rule
To summarize all the changes,  version of gem will be 2.0.0 so no  backwards-compatiblity is guaranteed

one more thing that I want to change is passing length , prefixes pair as key value hash. Because card prefix rule can be different in scope of length rule. See example
https://github.com/Fivell/credit_card_validations/blob/master/lib/credit_card_validations/card_rules.rb#L34
So maybe add_brand can have next  arguments
add_brand(key, rules , options = {})

where rules is hash like
{
 [15,16] => ['3528', '3529', '353', '354', '355', '356', '357', '358'],
 [15] => ['1800', '2131']
}

or can be array like in initial rules CardRules module.
Like
[
      {length: [15,16], prefixes: ['3528', '3529', '353', '354', '355', '356', '357', '358']},
      {length: [15], prefixes: ['1800', '2131']}
]

In this case we can have 2 methods add_rule and add_brand
add_brand can create shortcut https://github.com/Fivell/credit_card_validations/blob/master/lib/credit_card_validations/detector.rb#L57
and then call add_rule for each length->prefixes pair.
Looks like this simple issue turned to be trigger for good refactoring.....
What do you think about all of this @yazinsai   ?

@yazinsai , I will create new branch 2.0.0 and I will start refactoring there

@Fivell Glad to help. I'll go ahead and make the changes we agreed to earlier, and then you can continue the refactoring to include the length / rules changes.

@yazinsai , I will merge refactoring first, because there to much refactored code . After this we can work on other features simultaneously

https://github.com/Fivell/credit_card_validations/issues/22 is blocker for this task

@yazinsai , do you need any help?

@yazinsai , do you still want to implement this ?

@Fivell Sorry, missed your earlier hints at completion. Working on this now..


Javax.net.ssl.SSLHandshakeException: java.security.cert.CertPathValidatorException: Trust anchor for certification not Found.

Hey, I try to re read some novel, but for some reason I can't download image. Also some novel have image but when you tap or see full image can't download too.
It's say
Javax.net.ssl.SSLHandshakeException: java.security.cert.CertPathValidatorException: Trust anchor for certification not Found.
I also send same issue to your mail with pic hope it's help.

All of the novels are giving me this message and won't work for me

Ensure you are using updated android and disable Load App Keystore in Settings ->Update and Notification -> Network Section, then restart the application.
Please note, I don't have plan to update the application anymore.
You can try: https://novelupdates.inverse.cc/ for updates, but no offline support as far as I know


Scaffolded page mirroring main page

Hello,
So the issue I am having is hard to explain and please ask more questions if I am not clear.
My  ultimate frisbee website has multiple pages and all of them are being scaffolded out using handlebars partials. It seems as if something is getting mixed up when I push to Heroku and my Main page and Guys team page end up being mirrored except for content (since the main page content is from cms javascript file you set in the cms folder).
Here is the link to see what I am talking about:
iupultimate.herokuapp.com
If you would like me to post code I can. I have been going over every bit of my markup and found nothing. Even the _generated index file for the Guys team page is exactly how it should be from my partial I built for it.
Any help would be appreciated!

So I fixed my issue. I could not really find any issues within the compiling of handlebars or any of the processes while pushing to Heroku. So I just deleted the old Guys_team page I had and created a new one. That seemed to have fixed the issue.
Thanks!


Add check for CAP_SYS_MODULE and CAP_DAC_READ_SEARCH

Hi team,

In this PR I've added explicit check for CAP_SYS_MODULE (and CAP_DAC_READ_SERACH as well) at evaluate step. This way it's more clear for end-user what escape techniques he / she can apply after evaluate step is completed.
I suggest to refactor check_ptrace.go in similar way because technically it's just evaluating that CAP_SYS_PTRACE exists and not actually escaping. So I suppose it should belong to evaluate step rather than escape step.
The reason why I didn't implement actual CAP_SYS_MODULE escape in CDK is because each kernel version and architecture combination requires kernel module built specifically for it. Given how many kernel versions and architectures out there I see several options:

To make detailed instructions on how to build kernel module for arbitrary kernel version and architecture and put them to CDK.
To prebuilt kernel module for most popular distributions (e.g. Ubuntu 20.04) include them in CDK binary and leave note on how to build kernel module for other kernel versions.

What do you think about point (3)? Do you have any ideas on how to integrate CAP_SYS_MODULE escape to CDK?

Nikita Stupin
Advanced Software Technology Lab
Huawei

Great!

Maybe we should discuss the point (3) in a new issue, I will find some free time to create one. The PR cannot be reopened on Github.


Hound suggests renaming unused method arguments

Hound suggests renaming unused method arguments, e.g.:

Unused method argument - job. If it's necessary, use _ or _job as an argument name to indicate that it won't be used.

This isn't in the thoughtbot Ruby style guide. The closest thing in the guides is for block parameters:

Use _ for unused block parameters.

I opened a PR for this https://github.com/thoughtbot/guides/pull/335.

I'm thinking at the very least we want to be notified if a variable or argument is unused, because maybe someone forgot to remove it. Not sure if RuboCop supports a message to notify someone that something is unused.

There's a separate notification for an unused variable, and I agree that one makes sense. I'd also be happy with a “this argument is unused, did you mean to remove it?” notification. It's the “you should prefix this” part that I disagree with.

This is now in the thoughtbot guides. Closing.


Bad state: Stream has already been listened to

Bad state: Stream has already been listened to
This does not happen in version 0.6.0, but the corresponding error occurs in version 1.0.0 or 1.0.1.

thanks for open this issue, @synstin can you give me code example?


BrushSelector: Fix resize

Fix https://github.com/bqplot/bqplot/issues/1180
See https://github.com/d3/d3-brush/issues/43

See also https://github.com/bqplot/bqplot/pull/1097

@kaiayoung is it the issue you were mentioning?

This looks similar to what I've done in #1097, although that also contains another change extend->move.
Could you dig into why that was needed?

I am actually not sure this is needed, because the move is done later on in syncModelToBrush

@maartenbreddels do you think it's ready for merging?

@martinRenou The plot renders in the second tab, but it looks like the bouncing is still there unfortunately.

from bqplot import (OrdinalScale, LinearScale, Bars, Figure, Axis, ColorScale, CATEGORY10)
from bqplot.interacts import BrushIntervalSelector
import ipywidgets as widgets
import bqplot as bqp
import pandas as pd
import numpy as np
np.random.seed(0)
plt_x = np.arange(10)
plt_y = np.random.randint(10, size=10)

def print_val(change):
    print(change['new'])

x_sc = OrdinalScale()
y_sc = LinearScale()

plot = Bars(x=plt_x, y=plt_y, scales={'x':x_sc, 'y':y_sc}, colors=['#ff5500'],
            labels=['Date', 'Reads'])

xax = Axis(scale=x_sc, grid_lines='none', num_ticks=10)
yax = Axis(scale=y_sc, tick_format=',d', grid_lines='none', orientation='vertical', min=0)

brushsel_date = BrushIntervalSelector(scale=x_sc, marks=[plot], color='skyblue')

plot.observe(print_val, names=['selected'])

fig = Figure(marks=[plot], axes=[xax, yax],
                              padding_x=0.025, padding_y=0.025,
                             interaction=brushsel_date)

tab = widgets.Tab()
tab.children = [fig, fig]
# widgets.VBox([fig, fig])
tab

This looks like another issue doesn't it? This PR fixes the resize of the BrushSelector https://github.com/bqplot/bqplot/issues/1180
I am looking at the bouncing between views issue, seems very related to https://github.com/bqplot/bqplot/pull/1098, there is so much code duplication in this library I would not be surprised we simply need to apply the same fix at another class.

They're closely related, I think. If you look at #1180, the title says it is only visible initially but disappears when used in a tab or accordion, which arguably includes what we're seeing above. Originally the issue was with the selection only showing once as you say due to invalid figure size. But the current result is probably worse as you don't even end up with a single selection due to the bouncing. Happy to open a separate PR if needed!

Ok, now I see why they are both related. Thanks.
I'm investigating a good way to fix this.

I feel like the bouncing is due to the this.brushsel = this.d3el.call(this.brush); line which triggers brush_start and brush_end. This line is called when the selection changes for updating the brush position, and the fact that it triggers those events it might update the selection as well.

There are multiple issues with the BrushIntervalSelector (some of them appear on the BrushSelector as well, but let's deal with them one at a time):

[x] Updating the selector when a change appeared in another view/in the model needs to be done my calling this.brush.move and this.d3el.call(this.brush). This results in triggering brush_start and brush_move, which itself will update the model and redraw the brush -> lots of bouncing. This PR fixes this issue by discarding the events during the selector redraw
[x] The selected attribute was not using TypedArrays, resulting in bouncing between the Python model and the JavaScript one.
[ ] The first relayout in a tab does not seem to work, which is very odd because relayout appears to work properly on window resizing.
[ ] BrushIntervalSelector with an ordinal scale does not work. It's either coming from issues in the OrdinalScale itself, either coming from how the BrushIntervalSelector uses the scale, or it's coming from the selected attribute which does not have the right TypedArray

In this PR I use a Float32Array for the selected attribute, this seems like an odd choice to me, as we might not know the type of the buffer in advance, it depends on the scale or the data I guess.

We'll need to apply similar fixes to the BrushSelector, and maybe the MultiSelector

LGTM! Thank you


cli/client for obmd

The only way we interact with obmd right now is using curl, and it might make sense to have some cli for admins to use.
I wrote a python client (mostly copy pasta from hil) a while ago to talk to obmd for my own use.
https://github.com/naved001/obmd_client
Does it make sense to keep the cli/client in a separate repo, or should we bake the cli right here.

I'm definitely in favor of a python client library. I don't have strong opinions about whether it should be in this repo or a separate one.

wow this is new to me. So we already have our APIs designed and we write the docs in a yaml/json according to the specification and it magically generate libraries for us? That sounds good, and maybe I'll try it out when I have more time on hand.


Add new event turbo:after-stream-render

Similar to the turbo:before-stream-render event, it would be useful to fire an event after rendering a Turbo Stream page update

We don't plan on adding an after-stream-render event: https://discuss.hotwire.dev/t/event-to-know-a-turbo-stream-has-been-rendered/1554/6

We don't plan on adding an after-stream-render event: https://discuss.hotwire.dev/t/event-to-know-a-turbo-stream-has-been-rendered/1554/6

It helped me https://github.com/hotwired/turbo/pull/20#issue-773325276. Didn't found any drawbacks yet.

The big problem in my case is that after turbo_stream is loaded, the javacript library input_mask doesn't work anymore because the content that changes is the form itself.
They brought to us a solution with Stimulus and "connect()" method b but it does not trigger after turbo stream is loaded.
There is nothing that triggers after page changes.

ran into similar issue  and stimulus is not the answer for me.

Agree with @leewa, this would be of tremendous use to me.
I have this situation:

wrapping div (with a Stimulus controller connected)

a select input to change modes (where change triggers an action that makes a responseKind: 'turbo-stream' request using<EMAIL_ADDRESS>a fieldset containing some fields (that gets re-rendered by that turbo-stream update)
a input[type=hidden] that contains a JSON-serialized dump of the above fieldset (which is updated any time the user changes anything)

The stimulus controller just needs to know when that fieldset has been re-rendered so it can re-serialize its contents into that input[type=hidden]. Without this event, I'm not left with a lot of awesome options. Manual MutationObserver? Reaching upward to the wrapping form's submit event? This event would be great to have

I did this and worked perfectly for what I needed. If you need to update the event listeners on a controller, you can do this:
export default class extends Controller {
  static targets = ['button'];

  connect() {
    this.addEventListeners();

    const observer = new MutationObserver(() => {
      this.addEventListeners();
    });

    observer.observe(this.element, { childList: true });
  }

  addEventListeners() {
    this.buttonTarget.addEventListener('click' () => { /* Do something */ })
  }
}


Project Reunion project system should be decoupled from installed Windows SDK

The .NET 5 project templates for Project Reunion (via the TargetFramework property) have a dependency on a specific version of the Windows SDK (currently 19041). This can result in being unable to successfully compile a newly-created Project Reunion app with a fresh VS install if VS changes the default installed Windows SDK (WinUI encountered this as its own project templates specify 18362 as the target Windows version but VS 16.9 changed the default installed Windows SDK to 19041) since MRT Core defaults to locating makepri.exe from an existing Windows SDK installation.
To avoid this, the Project Reunion Nuget package should specify a Nuget package dependency against Microsoft.Windows.SDK.BuildTools; this will result in the requisite SDK tools being acquired from the Nuget package rather than depending on a pre-existing installation of a specific SDK version.

For this particular issue, we specifically need the BuildTools Nuget package; ideally it would be the 19041 tools (I don't know why nothing newer than 18362 is available, but that might just be because the issue has yet to be forced) but to the best of my knowledge the 18362 tools are still sufficient.

@alwu-msft Sorry, in correcting your link I also pasted the wrong link. Doh! I now see the tooling is stuck at 18362 for some reason.

Microsoft.Windows.SDK.BuildTools is not a complete replacement for the Windows SDK (as the title of this issue suggests) - it only contains build tools, not libs, includes, metadata, etc.  You could instead adopt the Microsoft.Windows.SDK.CPP package, which does provide those assets, but at over 100MB, users may prefer to stick with the Windows SDK.  If the original problem here was that mt.exe couldn't find a dependency, based on hardcoded assumptions, maybe we should fix that?  As a stopgap, we could assert a specific version of the Windows SDK.

Yeah, we're fixing the mt.exe/makepri.exe hard-coded assumptions (via the BuildTools package). That's an interesting point about headers/libs/metadata/etc. Those weren't really on our radar as there isn't a hard dependency on a specific version of the SDK there (our templates are set up to use whatever is the highest version installed).


multi line command becomes "\n"

$ echo 1 \
2

becomes
$ echo 1\\n2

Although the command can run, just look bad.
OS: ubuntu 18.04
shell: zsh 5.4.2 (x86_64-ubuntu-linux-gnu)

+1 It's huge problem to me.


feat(secretmanager): added samples for regional SM

Description
Fixes #
Note: Before submitting a pull request, please open an issue for discussion if you are not associated with Google.
Checklist

[ ] I have followed Sample Format Guide
[ ] pom.xml parent set to latest shared-configuration
[ ] Appropriate changes to README are included in PR
[ ] These samples need a new API enabled in testing projects to pass (let us know which ones)
[ ] These samples need a new/updated env vars in testing projects set to pass (let us know which ones)
[ ] Tests pass:   mvn clean verify required
[ ] Lint  passes: mvn -P lint checkstyle:check required
[ ] Static Analysis:  mvn -P lint clean compile pmd:cpd-check spotbugs:check advisory only
[ ] This sample adds a new sample directory, and I updated the CODEOWNERS file with the codeowners for this sample
[ ] This sample adds a new Product API, and I updated the Blunderbuss issue/PR auto-assigner with the codeowners for this sample
[ ] Please merge this PR for me once it is approved

@vipul7499 PTAL at the failed tests

@Sita04 The tests are failing because of the addition of a new environment variable GOOGLE_CLOUD_PROJECT_LOCATION


palera1n TUI?

Hey,
Just making this PR to ask a question about the status of a TUI. I’m considering making a TUI in go with the Bubbletea or PTerm frameworks.
Was just wondering whether you all would be interested in this being made into a repo under the palera1n org?
Id be fine with or without this being done, was just wondering if any of you all would be interested in this, Thanks!

This is not something to make a spam PR for, but yes, if you'd like (and actually are going to make a TUI), it can be a repo. This is something to talk about in the Discord though.


Add pull to refresh on question detail screen providing the server exposes a self transition

This pull request adds pull to request on the question detail screen if the server exposes a self transition. It will also update the question list when we vote too (fixing #14).

LGTM :+1:


Loop menu

Hello,
I was thinking about adding a Loop menu (one of the TODOs in the code).
This way it doesn't exit abruptly if you write a wrong command.
Something similar to:
def menu(account_data, client, board, session):
    player_username = account_data["username"]
    print("Welcome to Lichess {}!".format(player_username))

    while True:
        print("""
        P to play
        H for help
        Q to quit
        """)
        ans = input("command: ").lower()

        if ans.lower== "q":
            sys.exit()

This use the player would also go back to the menu after a game, maybe change a configuration, token, etc.
I can try to remake the current menu in this format so we can test it out before adding new features.

@ralacerda Yeah, this is a good idea. I have also thought about adding configurations, e.g. If you want to have UCI-format or algebraic notation. You can try to implement this yourself, but remember to ask if there's something you don't understand in the code (or similar). Thank you once again for a nice suggestion!

https://github.com/samthegitguy/lichs/commit/25e53156ad569a848f97198025418668ede6b57a works a little on this, at least for the game time selector. I might work on this more later.


Documentation

Now when the project builds creates a docs folder with typedoc.
All classes, interfaces and methods should be commented to populate the docs so contributing should be easier.

I've seen two good starting contribution to the original project by @ebshimizu and @wegry. You did some work on it and seems some bug fixes probably this repository still have. If you want to contribute you're free to join.


Temporary fix of HBaseQueue.get performance

the issue is https://github.com/scrapinghub/frontera/issues/227

Codecov Report

Merging #280 into master will decrease coverage by 0.09%.
The diff coverage is 100%.

@@            Coverage Diff            @@
##           master     #280     +/-   ##
=========================================
- Coverage   70.16%   70.07%   -0.1%
=========================================
  Files          68       68
  Lines        4720     4719      -1
  Branches      632      576     -56
=========================================
- Hits         3312     3307      -5
- Misses       1272     1275      +3
- Partials      136      137      +1

Impacted Files
Coverage Δ

frontera/contrib/backends/hbase.py
70.63% <100%> (-0.67%)
:arrow_down:

frontera/_version.py
30.14% <0%> (-1.48%)
:arrow_down:

frontera/contrib/messagebus/kafka/async.py
15.28% <0%> (ø)
:arrow_up:

frontera/__init__.py

...apy_recording/scrapy_recording/spiders/__init__.py
100% <0%> (ø)

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 1dec22f...93abdca. Read the comment docs.


[INTERNAL] Replace AbstractReader#filter with resourceFactory#createFilterReader

Depends on https://github.com/SAP/ui5-project/pull/514
Relates to https://github.com/SAP/ui5-fs/pull/438

Coverage remained the same at 94.703% when pulling 0d963d3164ba8e279b46d00a5ee28bb3fb7001ed on use-taskUtil-resourceFactory into 442b7f5d301a7fd3e2d3129838e2e4c7c94b4770 on main.


WFCORE-6841 Create ServiceDescriptors for capabilities defined in AbstractControllerService

https://issues.redhat.com/browse/WFCORE-6841

Core -> Full Integration Build 13577 outcome was FAILURE using a merge of df07108f1bc5331b8ba87b2c9621e092530aa0ae
Summary: Exit code 1 (Step: Build core (Maven)) (new) Build time: 00:01:47

Core -> WildFly Preview Integration Build 13636 outcome was FAILURE using a merge of df07108f1bc5331b8ba87b2c9621e092530aa0ae
Summary: Exit code 1 (Step: Build core (Maven)) (new) Build time: 00:01:51

Core -> Full Integration Build 13837 outcome was FAILURE using a merge of df07108f1bc5331b8ba87b2c9621e092530aa0ae
Summary: Exit code 1 (Step: Build core (Maven)) (new) Build time: 00:01:54

Thanks @pferraro


About the security: is it safe to store API key in localStorage?

I realized that the API key is stored in browser's localStorage. Though we use HTTPS to request the API, bug I wonder whether the browser's extensions have the ability to access localStorage...
Nevertheless, this repo is great:)

Same concern. Some basic encryption would be nice

Thank you for raising your concern about the storage of API keys in the browser's localStorage. We understand the importance of data security and would like to clarify that this is a deliberate choice made by the development team.
Firstly, it is generally safe to store sensitive data such as API keys in localStorage, which is similar to how login credentials are stored as cookies. While browser extensions may have access to localStorage, it is unlikely that a malicious software with access to localStorage will know what the API key is for or which website it belongs to.
That being said, we acknowledge that if a malicious software is specifically targeting OpenAI's API key, they will always be able to obtain the key since the encryption scheme is public. Furthermore, there is no other place to store the key for encryption other than localStorage. If a malicious software has access to localStorage, they can also access the key for encryption.
As a responsible developer, we should not give users a false sense of safety, even if the API key is encrypted. We strongly advise users not to install untrusted browser extensions, regardless of whether the key is encrypted or not.
Thank you for bringing up your concerns, and please do not hesitate to reach out if you have any further questions or suggestions.

Thanks for the reply:)

Thank you for raising your concern about the storage of API keys in the browser's localStorage. We understand the importance of data security and would like to clarify that this is a deliberate choice made by the development team.感谢您关注浏览器本地存储中 API 密钥的存储问题。我们理解数据安全的重要性，在此澄清这是开发团队深思熟虑的选择。
Firstly, it is generally safe to store sensitive data such as API keys in localStorage, which is similar to how login credentials are stored as cookies. While browser extensions may have access to localStorage, it is unlikely that a malicious software with access to localStorage will know what the API key is for or which website it belongs to.首先，将 API 密钥等敏感数据存储在 localStorage 中通常是安全的，这类似于将登录凭据存储为 cookie 的方式。虽然浏览器扩展程序可以访问 localStorage，但可以访问 localStorage 的恶意软件不太可能知道 API 密钥的用途或它属于哪个网站。
That being said, we acknowledge that if a malicious software is specifically targeting OpenAI's API key, they will always be able to obtain the key since the encryption scheme is public. Furthermore, there is no other place to store the key for encryption other than localStorage. If a malicious software has access to localStorage, they can also access the key for encryption.话虽如此，我们承认，如果恶意软件专门针对 OpenAI 的 API 密钥，他们将始终能够获得密钥，因为加密方案是公开的。此外，除了 localStorage 之外，没有其他地方可以存储加密密钥。如果恶意软件可以访问 localStorage，他们也可以访问密钥进行加密。
As a responsible developer, we should not give users a false sense of safety, even if the API key is encrypted. We strongly advise users not to install untrusted browser extensions, regardless of whether the key is encrypted or not.作为一个负责任的开发者，我们不应该给用户一种错误的安全感，即使 API 密钥是加密的。我们强烈建议用户不要安装不受信任的浏览器扩展，无论密钥是否加密。
Thank you for bringing up your concerns, and please do not hesitate to reach out if you have any further questions or suggestions.感谢您提出疑虑，如果您有任何进一步的问题或建议，请随时与我们联系。

我在自己的vps上面部署，vps页面设置了密码访问，怎么样把自己申请的openai api key放在vps上面呢？

可以放在 .env

可以放在 .env

请问如果把这一工程打包为纯静态页面放在nginx上运行而不是直接使用nodejs启动，这个文件中的配置会生效吗

可以放在 .env

请问如果把这一工程打包为纯静态页面放在nginx上运行而不是直接使用nodejs启动，这个文件中的配置会生效吗

ok 亲测生效


Added Python 3 support

CI Build - https://travis-ci.org/avinashvarna/sanskrit_lib/builds/307050014


Start Enroll

Hello, I need help enrolling a user. I've modified another version of the SDK. My question is: have you ever modified this SDK for enrollment purposes?
Another question: The setFingerprint method is not working. Could you please help me understand what might be going wrong?

Hi there!
Modifying the SDK for Enrollment:
Yes, I’ve worked with the ZKTeco Laravel package for user enrollment. Modifications to the SDK usually involve adjusting the communication between the ZKTeco device and the Laravel app, especially with handling fingerprint data and ensuring compatibility with custom setups. Depending on your specific use case, you might need to make changes to how data is processed or how API calls are made to the ZKTeco device. If you have specific modifications in mind, feel free to share, and I can guide you through them.
Issue with setFingerprint Method:
If the setFingerprint method isn’t working, it could be due to several reasons:
Device Communication: Ensure the ZKTeco device is properly connected and that it’s configured to communicate with your Laravel app. Check the IP settings and device connection.
SDK Version Compatibility: Ensure you are using a version of the SDK that supports the method. Some versions may require different methods or parameters.
Error Handling: Check for error messages or logs from the device or SDK to pinpoint the issue. Sometimes it could be a mismatch in the fingerprint format or issues in how the data is sent to the device.
Timeouts or Connection Issues: The method might fail if the connection to the ZKTeco device times out, so you might want to test the network or increase the timeout threshold.
If you can provide more details about the modification you’ve made to the SDK or any error logs, I’d be happy to help debug the issue further!

Is it possible to have events on this issue? I am working with the C#-based ZKTeco SDK, and we have events like onverify. I was thinking if it is possible to have such here.


New changes in the API RequestsLibrary

After making changes, I still see this, so will not push till all of these are resolve, else its flooding the logs and as well breaks those who are at lower level of package.
------------------------------------------------------------------------------
[ WARN ] Keyword 'RequestsLibrary.Post Request' is deprecated. Please use `POST On Session` instead.
[ WARN ] Keyword 'RequestsLibrary.Get Request' is deprecated. Please use `GET On Session` instead.
[ WARN ] Keyword 'RequestsLibrary.To Json' is deprecated. Please use ${resp.json()} instead. Have a look at the improved HTML output as pretty printing replacement.
[ WARN ] Ignoring space after '\n' is deprecated. For more info see: https://github.com/robotframework/robotframework/issues/3333
Test REST Setup :: Verify REST works.

new version for robotframework request API
https://marketsquare.github.io/robotframework-requests/doc/RequestsLibrary.html

old last working levels
robotframework-requests (0.7.0)
robotframework-requests (0.7.1)

new

robotframework-requests (0.8.1)

Back leveling to last known https://gerrit.openbmc-project.xyz/c/openbmc/openbmc-build-scripts/+/40909

Was trying some changes to check the behaviors and responses.. but looks like we may need to handle exception newly than response code.. have raised on ticket for it https://github.com/MarketSquare/robotframework-requests/issues/322
let see..

Need to work on this sooner :)

Robotframework requests package upgrade changes
Current working package version
robotframework-requests            0.7.2
To Test:
      pip3 install robotframework-requests -U
                 or
      # Once this commit is merged.
      pip3 install -r requirements.txt

      Version latest:
      robotframework-requests         0.9.3

Refer Documentation:
https://marketsquare.github.io/robotframework-requests/doc/RequestsLibrary.html
What is NOT changed:
- The test cases under directory tests/are not modified and is
deprecated but you can continue using it with an older package
and configuration using
   TODO: Awaiting a few more fixes before we branch out soon.
   git clone -b <THIS BRANCH>  https://github.com/openbmc/openbmc-test-automation

Tested:
Upstream HW_CI test list, firmware code update, and a few other
test suite like ipmi, certificate, dumps, ffdc, and redfish
test suites.
Note: I have not tested end to end, so it is likely there could be
grey areas where it could fail but should be minor w.r.t
response data format.


How to get external torques of the UR Robot?

Hello,
I am working with a UR10 Robot and would need the external joint torques (torques caused by external forces) available in ROS for my control structure.
There is the URScript command "get_joint_torques" that give me exactly this values. I managed to write a script running on the robot that sends the returned 6float vector via a socket connection - BUT: as soon as i perform any action or any other command is send to the robot (i.e. a position command via the ur_modern_driver), the script running on the robot stops and does not send any more values.
As far as I know, the ur_modern_driver uses the information, that is published by the UR controller on ports 30002 & 300003, which includes position, vlocity, etc. and only motor currents - no torque nor external torques.
Is there a way to get the external torques for real-time compliance control? Preferably also streamed with 125 Hz like the other values.
Thanks for your help,
kind Regards,
Matthias

If that data is available through either the secondary (TCP30002) or realtime interface (TCP30003) we can add publishers for it to the driver.
If not, it's going to be more difficult, as we would have to extent the small bit of URScript that is run by the driver on the controller.
That in itself is not difficult, but the whole point of ur_modern_driver was to run as little URScript on the controller itself - and then only when it's really needed.

As far as I know, the ur_modern_driver uses the information, that is published by the UR controller on ports 30002 & 300003, which includes position, vlocity, etc. and only motor currents - no torque nor external torques.

If you can figure out whether this is true (ie: the data not being available in sec and rt streams) then we can decide on a possible approach.


Add Windows support for gradle itest

Summary of the changes / Why this improves CrateDB
Checklist

[x] Added an entry in CHANGES.txt for user facing changes
[x] Updated documentation & sql_features table for user facing changes
[x] Touched code is covered by tests
[x] CLA is signed
[x] This does not contain breaking changes, or if it does:

It is released within a major release
It is recorded in CHANGES.txt
It was marked as deprecated in an earlier release if possible
You've thought about the consequences and other components are adapted
(E.g. AdminUI)

Thank you. Can I ask you to stash all of your commits into a single one?

Thank you. Can I ask you to squash all of your commits into a single one?

Done. Thanks for the review! Sorry for not squashing it immediately, was waiting for at least one approval.


Pasted image inverted in dark mode.

I’m sorry for the inconvenience.
Currently, reversing the colors of images in dark mode is a feature of Excalidraw. You can prevent images from being reversed by changing the color mode of Excalidraw in the settings.
But you’ve given me an idea :D. Perhaps in future versions, I should add a setting regarding the reversal of image colors.

In the latest version of ExcalidrawZ(v1.2.3), image can be prevented to invert.


Clarify path/specification and fix copy-paste mistakes

For example:

path Path(segment_count+1) The set of points of this polygon.

This is not correct, it's the set of path segments

Fixed-


Run agent as VSTS service.

Is there any way that I can run docker self-hosted agent as a VSTS service.
I am facing an issue related to Authentication like I am not able to access file share from inside the container. I would like to hast the agent as VSTS service.

It would be a great help if you can add this feature(Add agent as a service)

@ashutoshbarve Thank you for the feedback, your input is valuable to us.
For issues with the documentation comment below, otherwise please use Suggest a feature in the Azure DevOps community to solicit input on this from other users and get the product team's thoughts on feasibility.


feat(ogen-go/ogen): scaffold ogen-go/ogen

Check List

[x] Read CONTRIBUTING.md

[x] Read OSS Contribution Guide

[x] All commits are signed

This repository enables Require signed commits, so all commits must be signed

[x] Avoid force push
[x] Do only one thing in one Pull Request

#26241 ogen-go/ogen OpenAPI v3 code generator for go

Thank you for your contribution!

v4.218.0 is out 🎉
https://github.com/aquaproj/aqua-registry/releases/tag/v4.218.0


rsub capturing group

When I capture a group using rsub, I'm unable to access the capture using $1 or \1. For example
@rsub s/(test)/$1/
prints $1
Am I missing something?

Is there a resolution here? This seems like a major flaw in the system, if parameter replacement is not supported. A potential work-around is using Apache mod_substitute for straightforward replacements without ModSecurity context processing.
 The first example I found, from 2011, doesn't even consider replacement patterns. https://www.trustwave.com/Resources/SpiderLabs-Blog/ModSecurity-Advanced-Topic-of-the-Week--Malware-Link-Removal/
I'm also surprised that a feature so useful (virtual-patching the response body with ModSecurity) seems so obscure and underutilized. Eg, for data leakage. Am I missing something?

Here's a work-around using ModSecurity 2.9.0 and (FYI) OWASP CRS 1120664.  I don't mind the extra RAM requirements, that's cheap and easy these days, but CPU cycles and software inefficiencies are still a cause for concern.

@John-D-B @victorhora
Do you have the outdated rules based on modseucurity origin by Trustware, and i want to know and get more rules to start and use ; can you give me some , i wish you all the best and hope.


Replace pycrypto

Since pycrypto is unmaintained, we're replacing the methods used in our signing and signature verification workflows.
We're also updating the code styling.

Closing PR because untangling the circular dependencies is too much hassle to be worth the effort


Optimize queries with many results

Optimizing the hot path of queries with many matches.

Codecov Report

Merging #76 (4ad3687) into main (97e8f88) will decrease coverage by 1.55%.
The diff coverage is 73.52%.

Impacted Files
Coverage Δ

narrow_down/scylladb.py
90.17% <18.18%> (-7.87%)
:arrow_down:

narrow_down/_minhash.py
100.00% <100.00%> (ø)

narrow_down/_tokenize.py
100.00% <100.00%> (ø)

narrow_down/sqlite.py
97.26% <100.00%> (+0.38%)
:arrow_up:

narrow_down/storage.py
100.00% <100.00%> (ø)


docs: Add user guide for Sign In

Automated message from Dropbox CLA bot
@cosmicAsymmetry, it looks like you've already signed the Dropbox CLA. Thanks!

Wait. What just happened?

try git pull --rebase upstream master


Request

hey i notice you have a custom message for unknown command, love that feature, i really do could you also include you do not have permission! message as well? you already got 1 of my features im looking for in :)
https://forums.spongepowered.org/t/change-a-simple-message/16478/1

For UltimateCore commands you can change this message at "core.nopermissions" in the language file.
For other plugin's commands I am not going to add this because of technical reasons, sorry.


Install expect on proxy

What does this PR change?
This PR installs expect package on the SLE micro proxy.
Context
This is the third attempt to do the same thing.
The first 2 were done at test suite level:

the first one failed because it required too many reboots;
the second one failed because Foreign type proxies don't use the activation key.

Now trying from sumaform.

Closing in favour of Oscar's snippets.


Version in URL

📝 Changed routes:

…ctName]/[[...version]]

(view full size)

Commit 80be4d6b91f2475c4f2ebbd1ddeed3ed3611a7ed (https://thirdweb-a406opxqo-thirdweb.vercel.app).


ovsdb plugin: Don't add new interface

When OVS bridge is unmanaged by NetworkManager, NetworkManager plugin
will not include any information regarding it, the nispor plugin
neither(ovs bridge is user space only interface). The ovsdb plugin will
show it name and type.
This will cause oVirt crash when try to access OVS bridge information of
it which nmstate-0.3 does not.
To fix it, introduced NmstatePlugin.is_supplemental_only which
indicate whether plugin can only amend existing interface or not.
Set the ovsdb as supplemental only so it will never add new interface to
the libnmstate.show().

It's a regression issue.


Set up Azure AD Authentication

Only JL Azure AD users should be able to access the application.
Possibly useful links:
https://github.com/OfficeDev/O365-Node-Express-Ejs-Sample-App
https://github.com/AzureAD/passport-azure-ad
https://github.com/QuePort/passport-azure-oauth
https://msdn.microsoft.com/en-us/library/azure/hh967611.aspx
https://msdn.microsoft.com/office/office365/HowTo/getting-started-Office-365-APIs
http://www.wintellect.com/devcenter/jlane/securing-node-js-applications-with-oauth2-and-azure
http://blogs.technet.com/b/askpfeplat/archive/2014/11/03/adfs-deep-dive-comparing-ws-fed-saml-and-oauth-protocols.aspx
SPA Azure AD:
https://github.com/AzureAD/azure-activedirectory-library-for-js
http://code.tutsplus.com/tutorials/authenticating-nodejs-applications-with-passport--cms-21619

Need to vary configure.js based on which environment you're in (localhost, azurewebsites, or jacobsladder.school).

Extracted config seems to work as of commit db0212d, now need to integrate mongodb and sort out user registration.

Leaving user registration as manual step for now (see util/loadUser.js).  Integrated with mongodb "user" model.  Closing out issue but will open separate ones for things like admin/non-admin users, role-based security, and "run as..." functionality.


trouble parsing csv input without final newline

This example was reduced from a real CSV file, which had several fields, complete with inlined double-quotes, commas, and other potential hazards (I can't share the original file due to PII). Numbers and a few other programs parsed it correctly. zq parses it correctly, once I add a newline on the very last line of the file.
I can reproduce the same behavior with this:
# Unquoted simple strings, plus final newline (due to default `echo` behavior) - works fine
❯ echo "foo,bar\nfoo,bar" | zq -i csv -z 'yield this' -
{foo:"foo",bar:"bar"}

# Quoted string values, plus final newline - still works fine
❯ echo "foo,bar\n\"foo\",\"bar\"" | zq -i csv -z 'yield this' -
{foo:"foo",bar:"bar"}

# Quoted string values, but without a newline ending the contents (changed to `echo -n`), I receive this error message.
❯ echo -n "foo,bar\n\"foo\",\"bar\"" | zq -i csv -z 'yield this' -
stdio:stdin: parse error on line 2, column 10: bare " in non-quoted-field

# Removing the quotes from the values, still with no final newline (`echo -n`), works again.
❯ echo -n "foo,bar\nfoo,bar" | zq -i csv -z 'yield this' -
{foo:"foo",bar:"bar"}

❯ zq -version
Version: v1.16.0

Thanks @chrismo. It turns out this was already a known bug #4732 so I'm going to close this one as a duplicate and you can feel free to "Subscribe" to that one so you'll be notified when we fix it. It helps to have your report though because when we know community users keep bumping into these we need to boost the priority on getting them fixed.


Improve autocomplete sorting

Description

"Best Match" will never be selected by default
Best match results are filtered based on the text written in the input
Results other than best match are not unfurled
Contextual results are shown before best match (currentRow or vars declared in context)
Improved data type expected checks

Trigger fields will get functions best match results
Api header and params keys will get best match results
When no expected field is encoded, will not show best match
Appsmith object is not listed in best match

Improved sorting of best match

Action fields get widgets results and vice versa
Max 3 results are shown in best match

Removed bunch of JS results that were not valid (promise, Function etc)
Added some JS keywords in autocomplete
Improved styling on hint styles

Fixes #5035
Test coverage results :test_tube:
:green_circle: Total coverage has increased
// Code coverage diff between base branch:release and head branch: fix/autocomplete-sorting

Status
File
% Stmts
% Branch
% Funcs
% Lines

:green_circle:
total
53.87 (0.14)
35.8 (0.1)
32.37 (0.06)
54.43 (0.12)

:sparkles: :new:
app/client/src/actions/evaluationActions.ts
58.82
0
0
50

:green_circle:
app/client/src/components/editorComponents/CodeEditor/codeEditorUtils.ts
100 (0)
88.89 (1.39)
100 (0)
100 (0)

:red_circle:
app/client/src/components/editorComponents/CodeEditor/commandsHelper.ts
44.07 (1.96)
33.33 (-6.67)
22.22 (0)
46.3 (2.07)

:red_circle:
app/client/src/components/editorComponents/CodeEditor/hintHelpers.ts
78.26 (-11.74)
75 (-10.71)
40 (-22.5)
77.27 (-12.09)

:red_circle:
app/client/src/components/editorComponents/CodeEditor/index.tsx
71.31 (0.19)
45.99 (-1.34)
52.63 (0)
71.49 (-0.2)

:green_circle:
app/client/src/pages/Editor/PropertyPane/PropertyControl.tsx
57.52 (0.5)
41.67 (0)
25 (0)
59.81 (0.55)

:green_circle:
app/client/src/sagas/EvaluationsSaga.ts
20 (2.97)
3.03 (2.04)
6.67 (3.54)
22.83 (3.03)

:sparkles: :new:
app/client/src/sagas/PostEvaluationSagas.ts
20
0
0
23.42

:green_circle:
app/client/src/utils/autocomplete/EntityDefinitions.ts
46.67 (11.67)
0 (0)
25 (0)
46.67 (11.67)

:green_circle:
app/client/src/utils/autocomplete/TernServer.ts
50.59 (5.66)
39.41 (8.53)
36.21 (5.3)
54.77 (4.93)

:green_circle:
app/client/src/utils/autocomplete/customTreeTypeDefCreator.ts
36.36 (14.93)
100 (100)
0 (0)
30 (11.48)

:green_circle:
app/client/src/utils/autocomplete/dataTreeTypeDefCreator.ts
81.67 (14.6)
57.14 (-4.4)
100 (0)
78.85 (7.18)

:sparkles: :new:
app/client/src/utils/autocomplete/dataTypeSortRules.ts
100
100
100
100

:red_circle:
app/client/src/workers/evaluationUtils.ts
86.67 (-0.29)
70.08 (-1.69)
85.42 (-1.81)
85.91 (-0.33)

/ok-to-test sha=35cc1ce

/ok-to-test sha=8bc69fa

/ok-to-test sha=d8acdab


ebpf-verifier: init at 2023-07-15

Description of changes
This PR adds the following package: https://github.com/vbpf/ebpf-verifier
Closes https://github.com/NixOS/nixpkgs/issues/243051.
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.

LGTM.
Ping me 2023-07-22 to merge.

@AndersonTorres ping 😊


In README.md

Where are possible options described, please change param name quote to quotes (as it defined in code).
It takes some time to get why quote param isn't working.
I'm using "json2csv": "^3.11.5"

Current options are only for version ^4.0.0.
But I agree that we should keep older versions documented.

Just searched them myself and they can be found via git tags, for example https://github.com/zemirco/json2csv/tree/v3.11.5 :)

Thanks, @petetnt!!
I had the same idea some time ago and then forgot to push the link to the repo.


[WIP]Add block migration related jellyroll

to forbidden block-migration for roles not in whitelist.

retest

retest

retest

retest

retest

retest


Create and render HTML output of test suite

Your to-do
Create and render HTML output of test suite.
Currently XSLT stylesheet (from Apache project) with command line script. Change to XQuery to be run within app by developers on demand.
Issues you may encounter
None
Additional context

To use: Run pr-app/test/xqs/test-runner.xq in eXide and select "Direct output" to view formatted HTML output.
Running in vscode creates HTML output, but rendered in angle brackets, rather than formatted.
Assigned to @gabikeane  and @EmmaSchwarz  for review.

Decided not to do this


FR: Beautified tables

Thanks for your great plugin.
I have some ugly tables, like this:
| one | two  | three | four |
| --- | --- | --- | --- |
| 1 |✓| |
|2 | |✓| |
|3| |✓|✓|
| 4 | … | | someting else |
| Total | 100 | 20 | 300000000 |

Linter could change them to such a beautiful table:
| one   | two | three | four          |
| ----- | --- | ----- | ------------- |
| 1     | ✓   |       |               |
| 2     |     | ✓     |               |
| 3     |     | ✓     | ✓             |
| 4     | …   |       | someting else |
| Total | 100 | 20    | 300000000     |

Ups - in this image you better see what I mean:

At them moment, I use these online pretifiers:
https://prettier.io/playground/
https://codebeautify.org/markdown-formatter
What do you think?

I think this is an interesting idea, but we have previously decided against implementing this on the basis that there were plugins to do this already and there was not a good eay of doing this that would not incurr a lot of bug reports.

This can be achieved via Advanced Tables community plugin
After installing it, edit .obsidian/plugins/obsidian-linter/data.json to include custom command:
  "lintCommands": [
    {
      "id": "table-editor-obsidian:format-all-tables",
      "name": "Format all tables in this file"
    }
  ],

Vote on this issue if you want to make it possible to add this command via UI.

Thank you very much. I tried it with my example and it works as expected. But it also works, when I press  at the end of the table. I think this is because of the Advanded Tables plugin.
I don't really understand, what the reason is to enter the code into data.json?
When I paste 3 of my example tables and Linter the note, I get this:
Before lintering:
| one | two  | three | four |
| --- | --- | --- | --- |
| 1 |✓| |
|2 | |✓| |
|3| |✓|✓|
| 4 | … | | someting else |
| Total | 100 | 20 | 300000000 |

| one | two  | three | four |
| --- | --- | --- | --- |
| 1 |✓| |
|2 | |✓| |
|3| |✓|✓|
| 4 | … | | someting else |
| Total | 100 | 20 | 300000000 |

| one | two  | three | four |
| --- | --- | --- | --- |
| 1 |✓| |
|2 | |✓| |
|3| |✓|✓|
| 4 | … | | someting else |
| Total | 100 | 20 | 300000000 |

After lintering:

| one   | two | three | four          |
| ----- | --- | ----- | ------------- |
| 1     | ✓   |       |               |
| 2     |     | ✓     |               |
| 3     |     | ✓     | ✓             |
| 4     | …   |       | someting else |
| Total | 100 | 20    | 300000000     |

| one | two  | three | four |
| ---   | --- | --- | ---           |
| ----- | --- | --- | ------------- |
| 1     | ✓   |     |               |
| 2     |     | ✓   |               |
| 3     |     | ✓   | ✓             |
| 4     | …   |     | someting else |
| Total | 100 | 20  | 300000000     |

| one | two  | three | four |
| ---   | --- | --- | ---           |
| ----- | --- | --- | ------------- |
| 1     | ✓   |     |               |
| 2     |     | ✓   |               |
| 3     |     | ✓   | ✓             |
| 4     | …   |     | someting else |
| Total | 100 | 20  | 300000000     |

The reason to add those lines to the data.json would be to have the Linter run that command when you lint the current file.
As for why it is not formatting the tables correctly, I assume that is a bug in advanced tables if you ran format all tables from a specific table.

It is actually the first time I see problems in the Advanced tables. I experimented a bit, and here's what I found.

If Linter changed the position of the table (e.g. removes empty lines before it, so it starts on later line than before linting), then we can see artifacts during AT pass.
If tables go one after another without anything in-between, they might become corrupted. Interestingly enough, I've seen the behavior similar to the one in screenshots above, and also the opposite behavior, when only the first table gets mangled, and the rest are formatted properly.

I'm not keen on TypeScript, but the only idea I have after digging through code is this: AT gets the location of each table from app.metadataCache.getFileCache(...).sections. My assumption is that CacheMetadata doesn't get updated before the custom commands run, thus providing the AT with outdated positions to operate on. OTOH, Linter doesn't seem to rely on the cache at all (as far as I can search). Even adding timeout before running custom commands didn't update the CacheMetadata.
In my experiments, running AT separately from Linter, even via obsidian console, correctly formatted all tables, even in poorly-formatted markdown file. @pjkaufman , is there a way we could run commands before Linter runs? Is there some hidden reason to limit custom commands to run only after linting?

@Mikle-Bond , there are a couple of reasons they run after the file is linted.
The most problematic is I cannot wait for custom commands to finish before running the Linter as they are run asynchronously and, if I recall correctly, they do not properly handling waiting for the command to finish running. As such, I cannot run them before the Linter because that would potentially cause modifications to the current file to get overwritten by the Linter making changes as they could happen between when custom commands start and when after the Linter has already read in the current file's contents.
The other problem might not be a real issue. But it is my understanding that there is a time delay in how long it takes modifications of a file's contents in some cases to get populated to the CodeMirror editor of the current file. Thus if there is that time delay when any custom command runs, then the Linter would operate on bad data.
I will check whether or not custom commands can properly be waited for or if they always run async and cannot be properly awaited. If it is the latter, then I cannot support running custom commands before Linting. If it is possible to run custom commands before the Linter I believe this becomes a duplicate of #596 .

Commands that require an editor/active instance of a file would only get run on open files (currently these can only be added manually to the data.json since they don't come back in the list of commands from the obsidian API)

Well, the editorCallback commands seem to appear in all command dropdowns (including one in Linter settings). I patched AT, and it works. Only editorCheckCallback and checkCallback commands will be picky about it.

Would need to do something like the following instead of just executeCommandById:

I've tried to set a breakpoint in Obsidian Dev Console to see how commands are run

e.checkCallback ? e.checkCallback(!1) : e.callback ? e.callback() : console.error("Command ".concat(e, " did not provide a callback"))
// and editor*Callback is preferred if present

Seems almost like the code snippet you've provided. executeById chooses the correct callback, and runs it. If it is a *Check* callback, it runs it with false. From obsidian docs, it is correct to do:

The checkCallback runs twice. First, to perform a preliminary check to determine whether the command can run. Second, to perform the action.
Since time may pass between the two runs, you need to perform the check during both calls.
src: https://docs.obsidian.md/Plugins/User+interface/Commands

Also, as all the callbacks are not async callbacks, I would assume that they are meant to be executed synchronously.

Hey, @pjkaufman
Sorry I died in the middle of the Custom Commands discussion. And thank you for implementing that)
As custom commands have official implementation I see a possible solution for this issue too. I ran some tests with Advanced Tables plugin and some ways to lint files break tables, and some do not.
Minimal setup for the tests: a table with two blank lines between it and previous paragraph, and consecutive-blank-lines enabled. E.g. like this:
abcd

| foo   | bar   |
| ----- | ----- |
| hello | world |

Results of my observations:

how lint is executed
do tables break

run command "Lint current file"
yes

save file (with "Lint on save" enabled)
yes

change focus to another file/pane/split
no

RMB on file header and selecting "Lint file"
yes

RMB on current file in Navigation and selecting "Lint file"
no

Selecting folder with file and selecting "Lint folder"
no

Which means whenever Lint plugin uses runLinterEditor instead of runLinterFile it will break tables.
The only functional difference between them seems to be an explicit this.app.vault.modify here: https://github.com/platers/obsidian-linter/blob/d8f7f0c2bddc8967a22f4f968e772b30de5dcb39/src/main.ts#L324C5-L324C50
My assumption: it refreshes cache for the file, so the custom command receives up-to-date context on file. Would you mind to look into it? Could it be added to the runLinterEditor? Or, maybe, it should be added before each custom command, as there might be other command that rely on up-to-date cache?

Hey @Mikle-Bond . I am not sure I fully follow. Right now, I am more focused on fixing up a live preview issue which swaps from using editor replace range and just uses editor.setValue. This may fix the issue you are seeing.
However I thought the solution that had been suggested for this was to allow users to decide if a custom command would run before or after the Linter logic. Am I mistaken in this? Thanks for helping me better understand what the next steps are.

The reason I mention running the logic before the Linter does is that there is a debounce for when things save when changes are made to the current editor. This meams that the cache is not updated for a second or 2 which causes plugins that rely on cache to have a little bit of an issue running right after the Linter does when running on the editor directly. It may be possible to just save the file directly and bypass this, but I would prefer to not have to do that directly when linting the current file if possible.

if a custom command would run before or after the Linter logic

Yes, this particular issue would be solved if custom commands were allowed to run before linter. Though I couldn't imagine any other kind of command that would benefit from this. And with this approach, your plugin will probably run with stale cache, just like AT right now. It might not be an issue right now, but should be documented for the future.
And it doesn't solve the root of the problem. There might be other plugins that expect cache to be valid at least when their commands start.

from using editor replace range and just uses editor.setValue

I tried to mock this behavior in sandbox vault. That is, to call setValue before custom command. Seems to not update app.metadataCache in any way.
I ran this in Obsidian console:
const dowrap = (x,w)=>{const o = x._old || x.editorCheckCallback; x.editorCheckCallback = w(o); x._old = o; }
dowrap(app.commands.editorCommands['table-editor-obsidian:format-all-tables'],
	(f)=>{
		return (c,e,v)=>{
			console.log(e.getValue());
			e.setValue(e.getValue());
			console.log(app.metadataCache.getFileCache(app.workspace.getActiveFile()));
			return f(c,e,v);
		}
	}
)

..and looked at sections property. It was still outdated, while e.getValue() returns updated document.
I see that docs mention an event emitted when caches are updated: https://docs.obsidian.md/Reference/TypeScript+API/MetadataCache/on_3
I guess this is official "lawful" way to make sure cache is ready.
As for the performance concerns: linting the current file (for me) always happens when I want it to be saved, whether I "save" it, ":w" it, or change focus to another file, I'd want it to be written to the drive. Obsidian will save file anyway, so there shouldn't be much of a slowdown if we add one app.vault.modify ourself.
Or, maybe, not just one. It probably still gets into cache and debounces real filesystem writes.

Whelp. app.vault.modify doesn't update cache. Further tests have shown it does nothing to the cache at all.
The next significant difference between runLinterFile and runLinterEditor is here https://github.com/platers/obsidian-linter/blob/d8f7f0c2bddc8967a22f4f968e772b30de5dcb39/src/main.ts#L343
It opens file in new leaf.
Hypothesis: it triggers full file read, and as a consequence, cache is preheated.
Reality: no. I tried to squeeze in a line like
const file = app.workspace.getActiveFile();
app.workspace.activeLeaf.openFile(file)
  .then(()=>console.log("patched", app.metadataCache.getFileCache(file).sections))

..and caches are still old.
At this point I have only two explanations left.

Maybe activeLeaf.openFile actually checks if the file is the same as the one already opened. Then there's not much we can do about it.
Maybe we get lucky scheduling due to async-lock. And I got lucky with this command every time I tried. Looks suspicious, but at this point I'm ready to believe it.

If latter is the case, moving lock from runLinterFile into runCustomCommands (probably inside the for loop, if I understand locks correctly) should solve this issue. But I can't reliably verify that from Obsidian console.
If that doesn't help (most probably it doesn't), the app.metadataCache.on('changed',...) is the only reliable thing left.

Yeah. It is going to likely have to be an on metadata event based on what I have seen. However that would only apply to single file lints unless I am mistaken.

I would need to keep track of the file names that have be linted directly as a single file lint and then check metadata updates here:
this.plugin.app.metadataCache.on('changed', (file, _, cache) => {
    this.manager?.updateCacheOnExternalFrontmatterUpdate(file.path, cache.frontmatter ?? {});
}),

It would be something like this.

I think I have a fix for this based on the discussions we had here, but I am not sure if it works entirely, so I would appreciate if someone would test the contents of the following main.zip to verify that it does indeed work. It worked for the scenario referenced above where there was an issue with the table not being formatted correctly:
main.zip
@Mikle-Bond @merlinuwe

... formatted correctly: main.zip

Thank you very much. I just tried it with the table of the first comment of this threat (and 3 tables more) and it works. ;-)

... formatted correctly: main.zip

Thank you very much. I just tried it with the table of the first comment of this threat (and 3 tables more) and it works. ;-)

And if I add the missing h, it linters again:

Thank you so much!

Yay! I will see about proceeding with this change. I may modify it slightly to handle all custom commands this way for single and multifile lints.

I would appreciate if someone would test the contents of the following main.zip to verify that it does indeed work.

I hadn't noticed this happening yet, but upon testing the new main.js vs the old, the examples in the comment above are indeed fixed. The new main.js also works when Advanced Tables isn't set to beautify (pad cells with spaces) which is what I use.
Question: Will the modified main.js get updated via plugin update once a new Linter version is released? Or should I revert to the old main.js now?

@pjkaufman Thank you for the test build. I tested it too, and when I tried it, it actually exposed faulty behavior once, and then started to work properly, as people have reported. I tried to find what might've caused that once-in-a-lifetime glitch.
My only hypothesis is that I somehow triggered it right after Obsidian loaded, and it somehow used old main.js once, before loading modified one. Even though it showed a notice that all plugins were loaded and all...
Anyway, after two days I can't reproduce faulty behavior. I give up and call it a day. I figured I should report things, even if I can't understand them, instead of keeping silence and bashing my head against it.
Final conclusion: It works. You're a good wizard, @pjkaufman
@redactedscribe, yes, you can keep modified version. Obsidian doesn't track plugins' integrity (yet) and will update plugin just fine.

I would appreciate if someone would test the contents of the following main.zip to verify that it does indeed work.

I hadn't noticed this happening yet, but upon testing the new main.js vs the old, the examples in the comment above are indeed fixed. The new main.js also works when Advanced Tables isn't set to beautify (pad cells with spaces) which is what I use.
Question: Will the modified main.js get updated via plugin update once a new Linter version is released? Or should I revert to the old main.js now?

When a new version of the Linter is released, it will override your current main.js. This happens when it sees there is an updated manifest version out there. So you should not need to do anything to get a new release.

I have merged the change for this into master. This should affect all custom command usage. Please let us know if this does not work on master or in the next release.


Add PT-BR (Brazilian Portuguese) translation to forms-browsers-local-storage

Translated both the README and the assignment from 5-browser-extension/2-forms-browsers-local-storage to Brazilian Portuguese.

@PabloNunes when you have some time, could you review this translations PR? Thank you!


MediaTypeFormatter Task.StartNew choice?

I am implementing my own MediaTypeFormatter to handle FHIR requests in an independent web api 2 application.  I looked at the Spark implementations and I noticed the usage of Task.Factory.StartNew.  Was this to satisfy the contract of the async method (ReadFromStreamAsync) or was it chosen for a specific reason?  Just bringing this up in case it may cause issue for the application.
https://github.com/furore-fhir/spark/blob/master/src/Spark.Engine/Formatters/JsonFhirFormatter.cs
Lines 42, 68

This is particularly true for ASP.NET; there should almost never be a need to call Task.Run (or even worse, StartNew), certainly not in a MediaTypeFormatter class.
-- Stephen Cleary

Please refer to this article for (not mine) for details:
http://blog.stephencleary.com/2013/08/startnew-is-dangerous.html

Task.Run appears to work just as nice. We'll adjust this for all MediaTypeFormatters.

That is specifically called out as a thing not to use.  You risk deadlocks that may not appear when you do a simple debug in Visual Studio.
A better approach (since the request is technically blocked by the media type formatter) would be to use Task.FromResult to satisfy the contract of returning a Task.

That is what we did in sqlonfhir