Mark all included files as dependencies for watch mode

This is a fix for https://github.com/csstools/postcss-sass/issues/19.  I believe this stems from https://github.com/sass/dart-sass/issues/574 - TL;DR dart-sass does not perfectly match node-sass when it comes to the importer option.  In node-sass, all imports are passed to the importer function and can be overridden.  This is a feature that postcss-sass was leveraging to gather dependencies for watch mode.  However, in dart-sass any imports that can be resolved as a relative path do not get passed to importer.  This is why most of our child imports are no longer watched.
The workaround is to do something like sass-loader does here, which is to look at the stats.includedFiles from the dart-sass results, which includes a full list of the files that were encountered during compilation.

Thanks @Antonio-Laguna!  Glad to see some movement on this project again, really appreciate the recent releases!


chore(functions): replace helloGcs sample with helloGcsGeneric

Per b/135560881, we've since replaced what used to be helloGCS with what used to be helloGCSGeneric (and is now helloGCS) to reduce unnecessary duplication.
@labtopia FYI

Looks like functions tests are passing - @TheRoyalTnetennba can you merge if so? Thanks! 🙂


Bash hangs after mv

A brief description
Bash deadlocks after executing mv. Command:
mv ../samples/ .

Expected results
../samples/ will be moved to the current directory.

Actual results (with terminal output if applicable)
Bash Hangs. No terminal output. After a full windows restart, bash still hangs (it shows a completely empty cmd window. Typing doesn't result in any characters shown on screen.

Your Windows build number
14393.576

Steps / All commands required to reproduce the error from a brand new installation
Note: Cannot reproduce due to dead bash, so it hasn't been tested.

In windows: Download Attatch: samples2.zip from https://ocw.cs.ru.nl/NWI-IBC027/PracticalAssignments. Place somewhere in windows home folder.
In windows: Create subdirectory in same folder as samples2.zip
In bash: cd to samples2.zip
In bash: execute command unzip samples2.zip
In bash: cd to subdirectory
In bash: execute mv ../samples2/ .

Bash should not output anything anymore, even after full reboot.

Strace of the failing command
Cannot produce strace due to dead bash.

Required packages and commands to install
sudo apt-get install unzip

Any instructions on how to reset the state of bash would be appreciated.

Known issue. Fixed in insider builds. Please close.  It happens if you mv with a trailing /


Specify Fallback Locale

Hi,
Is there anyway to define fallback locales incase there isn't a value defined for the current locale?

It should automatically fall back to the default locale, if a translation for that is unavailable to the first available translation.

Am 09.04.2015 um 11:44 schrieb Spencer MacDonald<EMAIL_ADDRESS>Hi,
Is there anyway to define fallback locales incase there isn't a value defined for the current locale?
—
Reply to this email directly or view it on GitHub.

Thanks, wanted to check before integrating it.


PhysicsHelper - Updraft effect

I was initially working on the tornado/vortext effect (will still do after that) and I accidentally created an updraft effect. Also looks kinda interesting I think.
http://recordit.co/3X4e5aHJTN
Sorry, that the first Screencast2GIF tool I found.
Example:
var createScene = function () {

    // Scene
    var scene = new BABYLON.Scene(engine);
    scene.enablePhysics();

    // Physics engine
    var physicsViewer = new BABYLON.Debug.PhysicsViewer();
    var physicsHelper = new BABYLON.PhysicsHelper(scene);

    // Camera
    var camera = new BABYLON.FreeCamera("camera1", new BABYLON.Vector3(0, 16, -32), scene);
    camera.setTarget(BABYLON.Vector3.Zero());
    camera.attachControl(canvas, true);

    // Lightning
    var light = new BABYLON.HemisphericLight("light1", new BABYLON.Vector3(0, 1, 0), scene);
    light.intensity = 0.7;

    // Ground
    var ground = BABYLON.Mesh.CreateGround("ground1", 64, 64, 2, scene);
    ground.physicsImpostor = new BABYLON.PhysicsImpostor(ground, BABYLON.PhysicsImpostor.BoxImpostor, { mass: 0, restitution: 1 }, scene);

    // Boxes
    var boxSize = 2;
    var boxPadding = 4;
    var minXY = -12;
    var maxXY = 12;
    var maxZ = 8;
    var boxParams = { height: boxSize, width: boxSize, depth: boxSize };
    var boxImpostorParams = { mass: boxSize, restitution: 0, friction: 1 };
    var boxMaterial = new BABYLON.StandardMaterial("boxMaterial");
    boxMaterial.diffuseColor = new BABYLON.Color3(1, 0, 0);
    for (var x = minXY; x <= maxXY; x += boxSize + boxPadding) {
        for (var z = minXY; z <= maxXY; z += boxSize + boxPadding) {
            for (var y = boxSize / 2; y <= maxZ; y += boxSize) {
                var boxName = "box:" + x + ',' + y + ',' + z;
                var box = BABYLON.MeshBuilder.CreateBox(boxName, boxParams, scene);
                box.position = new BABYLON.Vector3(x, y, z);
                box.material = boxMaterial;
                box.physicsImpostor = new BABYLON.PhysicsImpostor(box, BABYLON.PhysicsImpostor.BoxImpostor, boxImpostorParams, scene);
                physicsViewer.showImpostor(box.physicsImpostor);
            }
        }
    }

    // Updraft
    var origin = new BABYLON.Vector3(0, 0, 0);
    var radius = 8;
    var strength = 8;
    var height = 20;

    setTimeout(function () {
        var event = physicsHelper.updraft(
            origin,
            radius,
            strength,
            height
        );
        event.enable();

        // Debug
        var eventData = event.getData();
        var cylinder = eventData.cylinder;
        addSemiTransparentMaterial(cylinder);
        cylinder.isVisible = true;
        // Debug - END
    }, 1000);

    // Helpers
    function addSemiTransparentMaterial(mesh) {
        var semiTransparentMaterial = new BABYLON.StandardMaterial("semiTransparentMaterial", scene);
        semiTransparentMaterial.alpha = 0.5;
        mesh.material = semiTransparentMaterial;
    }

    return scene;

};

Also did some minor naming changes (radialSphere -> sphere) as long as it's still in beta :)

Howdy!
Thanks a lot, this is really great. Can you please solve the conflicts? You can avoid those conflicts by submitting only the .ts files. the rest of the files are being generated by us during the nightly deployment.

There we go! :)


enable alt-screen

Codecov Report

Merging #1957 into master will decrease coverage by 0.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #1957      +/-   ##
==========================================
- Coverage   74.72%   74.71%   -0.02%
==========================================
  Files          77       77
  Lines      125686   125686
  Branches    28123    28123
==========================================
- Hits        93924    93908      -16
- Misses      31762    31774      +12
- Partials        0        4       +4

Impacted Files
Coverage Δ

src/if_xcmdsrv.c
85.18% <0%> (-1.3%)
:arrow_down:

src/gui_gtk_x11.c
47.23% <0%> (-0.21%)
:arrow_down:

src/channel.c
83.84% <0%> (-0.14%)
:arrow_down:

src/if_py_both.h
76.05% <0%> (-0.14%)
:arrow_down:

src/undo.c
81.48% <0%> (-0.07%)
:arrow_down:

src/evalfunc.c
82.58% <0%> (-0.02%)
:arrow_down:

src/gui.c
45.67% <0%> (+0.05%)
:arrow_up:

src/os_unix.c
52.88% <0%> (+0.14%)
:arrow_up:

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 8ab3c1d...b16d7a8. Read the comment docs.

Yasuhiro Matsumoto wrote:

/* Enable alt-screen. */
vterm_screen_enable_altscreen(vterm_obtain_screen(term->tl_vterm), 1);

Unfortunately, this function has no comment or documentation.
Do you know what it's doing?  If yes, then we should add a comment in
vterm.h
Looking at the code it seems that without this call vterm would crash
when trying to access the altscreen.  That can't be right.
--
There is no right or wrong, there is only your personal opinion.
(Bram Moolenaar)
/// Bram Moolenaar --<EMAIL_ADDRESS>-- http://www.Moolenaar.net   \
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \
\\  an exciting new programming language -- http://www.Zimbu.org        ///
\\            help me help AIDS victims -- http://ICCF-Holland.org    ///

Do you know what it's doing?  If yes, then we should add a comment in vterm.h

This handle alternate screen buffer. You can confirm behavior that less command quit with restore screen which is before run it.

Looking at the code it seems that without this call vterm would crash when trying to access the altscreen. That can't be right.

Sorry, I fixed.


blog.permalink = ":title" always returns the file title rather than the yml title

I've double checked this just to make sure I'm not going mad but I can't find anywhere else this would be set.
So I want my blog permalinks to just be...
'site-url/title'

So I set my permalinks to be...
blog.permalink = ":title"

then in my YML frontmatter I have...
---
title: We're experts
date: 2015-01-01
published: true
author: Kat Neville
---

and my blog file is...
2015-01-01-Were-experts.html.markdown

Yet my blog url's are returning...
site-url/2015-01-01-Were-experts/

when they should be...
site-url/were-experts/

Is there any reason why this would be happening?

Ah, it turns out I wasn't setting my blog sources properly!
blog.sources = "blog/{year}-{month}-{day}-{title}.html"


Find a virus by Kaspersky.

I download gost-linux-386-2.11.1.gz   and scan by Kaspersky.  Then find a virus.
Check whether the virus is falsely reported. If it is false positive, can you submit an application to Kaspersky to block the virus?
DetectName=not-a-virus:HEUR:RiskTool.AndroidOS.Revpn.j
DetectType=Other
Md5Hash=55618c7f29925ac535f6c1da3dea8d70
UniqueFileId=7773835bf1263998eb79b9637d7bfc5241d07b540ebfb540f360196dd7523b17
Sha256Hash=8cbafe65de579259048c2d87078e9906ebfd380002313582dddcadacf839c5f6

https://www.virustotal.com/gui/file-analysis/NzViZTMzOWYzMDIyM2EzMzRiMTM3MDJmMDMzNzAzM2Y6MTY5MjE2OTM4Nw==
This is normal, due to some people misusing gost (used to assist malicious software in establishing control communications), antivirus software now considers gost malicious software.


fix(toc): invalid desktop-only styling

should display none instead.

your pr comments says display none but the code change is display flex

your pr comments says display none but the code change is display flex

The display cascades to flex or none from .desktop-only based on screen width. By removing it from this spot, it no longer overrides the display mode on mobile width.


Add createTable command?

Would it make sense to add createTable to the commands, similiar to the previous createTable command in prosemirror-schema-table?

please check https://github.com/atlassian/prosemirror-utils/blob/master/src/table.js, there is a number of useful methods for tables


paket.bootstrapper.exe does not work on a  macbook

### Description
Please provide a succinct description of your issue.
Repro steps
Please provide the steps required to reproduce the problem

Step A

Step B

If possible then please create a git repository with a repro sample or attach a zip to the issue.
Expected behavior
Please provide a description of the behavior you expect.
Actual behavior
Please provide a description of the actual behavior you observe.
Known workarounds
Please provide a description of any known workarounds.

The bootstrapper is a really really old way of using paket, and it should be invoked with mono.
Have you tried using the dotnet CLI tool for paket instead? dotnet tool install paket should be all you need to get started.

I used "mono" in front and it worked.


How do I calculate or get the progress when decompressing a split RAR archive?

I decompress a single split RAR archive consisting of 10 rar-files with SharpCompress like this:
private static double percentage;
private static long totalSize;

public static void ExtractRAR(sourcePath, targetPath)
{
	DirectoryInfo dirInfo = new DirectoryInfo(sourcePath);
	List<FileInfo> files = dirInfo.GetFiles("*.rar").OrderBy(o => o.FullName).ToList();

	try
	{
		IArchive archive = ArchiveFactory.Open(files[0]);
		Extraction.totalSize = archive.TotalSize;

		foreach (IArchiveEntry entry in archive.Entries.Where(entry => !entry.IsDirectory))
		{
			archive.CompressedBytesRead += Archive_CompressedBytesRead;
			entry.WriteToDirectory(targetPath, new ExtractionOptions() { ExtractFullPath = true, Overwrite = true });
		}
	}
	catch (IOException ex)
	{
		MessageBox.Show("Error: " + ex.Message);
	}

	private static void Archive_CompressedBytesRead(object sender, CompressedBytesReadEventArgs e)
	{
		Extraction.percentage = ((double)e.CompressedBytesRead / (double)Extraction.totalSize) * 100;
		MessageBox.Show(Extraction.percentage.ToString());
	}
}

It is successfully extracted but the output I get from the progress is more than confusing. It repeats a value of "10,9...", then come some "0" and inbetween a "21,8,...". It does not count further to "32,7" etc. What is wrong here!?

Okay, got it:
I do not need to calculate the substreams (or whatever he is doing within archive.CompressedBytesRead) but the actual size of the files he is extracting.
Corrected code:
public static void ExtractRAR(sourcePath, targetPath)
{
	DirectoryInfo dirInfo = new DirectoryInfo(sourcePath);
	List<FileInfo> files = dirInfo.GetFiles("*.rar").OrderBy(o => o.FullName).ToList();

	try
	{
		IArchive archive = ArchiveFactory.Open(files[0]);
		double totalSize = archive.TotalSize;
		double proceededSize = 0;
		double percentage;

		foreach (IArchiveEntry entry in archive.Entries.Where(entry => !entry.IsDirectory))
		{
			entry.WriteToDirectory(Helper.GetRegValue("\\Paths", "ExtUP"), new ExtractionOptions() { ExtractFullPath = true, Overwrite = true });
			proceededSize += entry.Size;
			percentage = (proceededSize / totalSize) * 100;
		}
	}
	catch (IOException ex)
	{
		MessageBox.Show("Error: " + ex.Message);
	}
}

This "issue" can be closed :)


Fixing Metrics bug in ScriptFunctionInvoker

Hotfix: Adding the same try/finally pattern to ScriptFunctionInvoker as used for the other invokers (C#, Node, PowerShell) to ensure that the function End event is raised in all cases.
I've checked all the other invokers and they don't have this issue.

:shipit:


[KYUUBI #4761][DOC] Deploy & Develop Kyuubi Web UI

Why are the changes needed?

Close #4761
How was this patch tested?

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

[ ] Add screenshots for manual tests if appropriate

[ ] Run test locally before make a pull request

Codecov Report

Merging #4775 (369cc7c) into master (0b72a61) will decrease coverage by 0.06%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##             master    #4775      +/-   ##
============================================
- Coverage     57.98%   57.93%   -0.06%
  Complexity       13       13
============================================
  Files           581      581
  Lines         32423    32423
  Branches       4309     4309
============================================
- Hits          18801    18784      -17
- Misses        11822    11832      +10
- Partials       1800     1807       +7

see 11 files with indirect coverage changes
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

https://github.com/apache/kyuubi/pull/4768/files#diff-d53927957e727c585d886364d9a70c69723d47169185468c7eb3b5e5cf178a80 Please try these documentation style guidelines to polish to content and representation

For a non-programming API, we do not need to add notices like experiential or something else. It breaks nothing in feature releases.

This passage appears to be more colloquial and falls short of the level of formal text. It still requires further refinement to avoid redundant content and colloquial expressions.

The text appears to be more colloquial and is way from the level of formal docs. It still requires further refinement to avoid redundant content and colloquial expressions.

Thanks for reviewing this. I will do further improve.

Thanks for the response. I would suggest to do the following polishment,

use objective descriptions over subjective ones, e.g.It's suggested. When ... over If you want ....

prevent repeating phases, e.g. recommendations for pnpm
provide decisive suggestions to related descriptions and discussion, e.g. concise  code samples for using pnpm following the recommendation

Thanks for your suggestion, made the modification. If there's anything wrong, please let me know.


Introduce a fast path for GPR_TIMESPAN in grpc_timespec_to_millis_round_up/down.

We are always converting the clock type of the input to
the clock type of g_start_time. This makes sense for real
clock values but resutls in uncessary now() calls for GPR_TIMESPAN.
GPR_TIMESPAN is simply a delta and there is no need for a conversion.
We can simply add it to g_start_time and get the millis.
By avoiding extra syscall, this results in a much faster deadline
support for RPCs, when the deadline is expressed in duration
rather time point.

That all said, I think this patch is broken and can't be applied. It saves a now call but it returns
now(monotonic) + timespan - g_start_time
I changed it to g_start_time + timespan, which results in invalid values because it misses the time passed since g_start_time. I think I should revert this patch. Sorry.


fix: fix panic caused by removed_resource.is_none (fix #11955)

closes #11955
Fixes a panic caused by an assert when the resource random id has been used already

Added a file in .changes. From the contributing guide it seemed like this was unnecessary for bug fixes, but I might have misread it.


New runtime.kita.ts and ESM support

[x] Parser tests
[x] Generator tests
[ ] Fixed kita create templates
[x] Moved Kita plugin to runtime
[ ] ESM tests
[x] Circular import tests
[ ] Migration guide

well we're fucked. ts-json-schema-generator package is now ESM-only, (released in a non breaking version btw XD). I converted the entire kitajs codebase to ESM to keep it working but everything falls apart when the ts-plugin needs to be CJS because the tsserver is written in CJS and as cjs cannot import esm (for now), the @kitajs/ts-plugin cannot import any other kita esm package.


Fix version module capitalization

Makes rubocop -V include this extension. This is also the case for the other 3 extensions from the readme, but I'll leave that up to you.

Good catch 👍


Missing expiration

I noticed a ever-increasing number of keys in my cluster. It looks like the redis sliding window stats keys are never set to expire
In RedisConcurrencyManager and RedisFixedWindowManager none of the keys have expiration.
I don't think this is expected is it?

Yes, we should fix this

@cristipufu thanks for merging the PR. when are you planning to release it?


Configurable snapshots directory for colocated tests

The React community seems to be moving towards colocating tests with components. I appreciate the changes to the default testRegex that looks for any .test.js file.
However, using this colocation method means a bunch of scattered __snapshots__ directories throughout the codebase. Since snapshots seem to be more for machine readability than human readability, I would tend to throw them all in a single top-level directory (like you might have for build/dist files). What are your thoughts on making the snapshots directory configurable?

snapshots are colocated with tests and they are definitely not meant to be for machine readability. They are meant to be reviewed by humans, both the author of a test and the code reviewers.

Jest also ensures that there are never any stale snapshots in the system. This means we both need a way to map from a snapshot to its associated test and back. This seems kinda hard to configure via string values in the JSON config :(

Thanks for the quick reply!
I understand that the snapshots are meant to be read and reviewed. It just seems a bit messy to have __snapshots__ littered throughout the codebase when I want to have tests colocated with components. This may also come from a pattern of grouping components by functionality, rather than having a components directory (e.g. user/Profile.js and layout/Nav.js).
In the meantime, I've just started dropping tests into __tests__ to get the __snapshots__ into a single place but this isn't my ideal.
I also understand this is a bit hard to configure. My thought was to define some top level directory for __snapshots__ and have the directory structure within it match the path to the component from that top level.
It might just be me that finds this messy. Curious to hear from others that colocate tests with components and have multiple directories of components.

Currently my directory looks a bit like this:
js/
  user/
    __snapshots__/
      Avatar.test.js.snap
      Profile.test.js.snap
    Avatar.js
    Avatar.test.js
    Profile.js
    Profile.test.js
  layout/
    __snapshots__/
      App.test.js.snap
      Nav.test.js.snap
    App.js
    App.test.js
    Nav.js
    Nav.test.js

The __snapshots__ in this way feels a little messy to me (but this may just be me).
As an alternative, my thought was a directory structure like this might be easier to understand/comb through:
js/
  __snapshots__/
    user/
      Avatar.test.js.snap
      Profile.test.js.snap
    layout/
      App.test.js.snap
      Nav.test.js.snap
  user/
    Avatar.js
    Avatar.test.js
    Profile.js
    Profile.test.js
  layout/
    App.js
    App.test.js
    Nav.js
    Nav.test.js

but that is the opposite of colocating snapshot files with their tests, isn't it?

I'm proposing that the snapshots don't necessarily need to be colocated with tests. I find it more important that tests are colocated with components. Having all three colocated feels messy, mostly due to the several __snapshots__ directories that are created/scattered throughout the codebase (at least in the way I've chosen to organize my components).

I'm not religiously opposed to this if you want to do all the work necessary to support this, find a way to make this maintainable and test it well.

We can also help on our discord channel and happy to review code, of course :)

I think my main argument is that the snapshots are auto generated and aren't meant to be modified manually, nor really imported directly into the codebase. So it doesn't feel right to have them intermixed within the code which you are actively editing/maintaining/importing.
I'm not particularly married to this idea either :) Just wanted to propose it to see what others thought. If I'm not alone in this, I may take the time to mock up a PR and see what it might look like.

I'm sure you find many people that share your opinion. Testing is like a religion to people and I'm happy to support all kinds of doing this as long as it integrates well with Jest and is well tested itself.

This is something where we'll need some help from the community. I think a good way to support this is by adding a config option resolveSnapshots that points to a module with two functions:
exports.resolveSnapshotFile = testPath => snapshotFilePath;
exports.resolveTestFile = snapshotFilePath => testPath;

this way we can call these methods to resolve the snapshot path from a test path and the other way round and it will enable use to keep snapshot files consistent.

I'm gonna close this given the inactivity. If somebody would like to work on this, I'm happy to reopen this and review a PR :)

I have the same problem as #1653.
preprocessor approach is not good in case of

TypeScript and IntelliJ IDEA.

TypeScript on CI server.

Because IntelliJ IDEA has built-in very fast TS compiler. So, during editing no compiler output. And you add "Compile TypeScript" task to run configuration — output will be dumped from memory to FS. No need to use slow (because ts must operate on the whole project, — opposite to babel) runtime preprocessor.

Because on CI server in any case you compile all sources before test run — again because TS / tslint operates on the whole project, not on individual file.

Well, as a workaround, out/__snapshots__ can be added to VCS.

👀
Following this to work on it in a short future

Actually at this point I don't really think I want to support this feature. It adds unnecessary complexity and gives almost no value.

So. How did end it?. I really like to have each test with its component. But I'd prefer to get all snapshot file in a unique folder, not around the code.

Yeah, I think would be good to have this feature.
I'm not 100% happy with my snapshots all over the project. :(

And I don't like either to replicate the project structure on test folder...

+1, I would also like to have all snapshots moved to one folder.

Cool, I'll try to work on it this weekend and propose a PR.
Then we move this discussion there.

Great!
Let me know if I can help you. I've been thinking about complexity.
The main problem is what happens if there are Test with same file name. Probably best option would be to get relative path of test file and replicate folder structure on snapshot folder.

@cpojer told me that @ljharb was interested on this feature too.

@lucasfeliciano @luispuig Any progress on this? Do yout want some help with something?

I didn't try...

Just looking at this myself. To be honest, I kind of despise this double underscore padded directory name thing. Guido has a lot of answer for! These things are making their way to Javascript as well now :). I happen to think they look a right mess, but sure... subjective.
I'm personally in the directory per component camp, and sit my unit tests as a sibling to component code using the component.test.js convention.
I think it would be quite nice to have capability to configure the snapshots to also be generated as siblings to the component and tests. They are, after all, just resource files and are to my tests what css files are to the component (which I also keep as siblings).
The magic seems to happen here.. https://github.com/facebook/jest/blob/master/packages/jest-snapshot/src/utils.js#L96
I'm wondering how difficult it would be to pass this hardcoded directory name through from the package.json config (making current value default for backwards compatibility). I'm still too much of a JS newb to really know exactly how that process works.
In any case, opening support for *.test.js style, but not supporting the same sibling structure for snapshot files does feel like a bit of an inconsistency.

Hi,
I was just thinking on this. I get why main developers doesn't want to change this feature.
If you use a testing folder yo git everything on same folder. But if your work on different proyecta it's worse to move componentes becouse you got to copy the component and the test on a different folder.
But if we use the test with the component it get full of snapshot folders.
To maintain a different folder for snapshots needs to care a lot about the directory structure becouse we can have 2 tests/components with same name on different folders. And again, to share de component, the snapshot is part of the test.
I got a cuestión. Would be posible that jest uses the same test-file to Store the snapshots? This would be great and satisfy the 2 trends.

@luispuig
I get why the developers might advise in the docs and FAQ that moving the snapshots out from under the component in the structure is a bad idea that you should probably not do. Personally, I would not do this anyway, because I would agree with them on this point.
A style that is quickly becoming the norm though, is to place unit test files as siblings to the code under test. This is why jest now supports *.test.js files.
I actually don't get why they wouldn't want to change it. We are talking about a testing tool that imposes a hardcoded opinion over the structure of the user's source tree.
The intention presumably is consistency with the tests idea, but this is a very different thing. Actually, in isolation, if the snapshot directory name were to be imposed, a dot folder would be a better choice because it contains, "stuff you rarely need to mess with", obviously this is distinct from tests, which are code under maintenance by the user.
I'm fairly new to the JS world to be honest (I have 20 years of JVM development xp), and it does feel like the "standards war" is still ongoing in this ecosystem. In any case though, a testing library is not really a suitable battleground for that kind of thing in my opinion. If a tool like, "create-react-app", were to configure jest in an opinionated way my gripe would be softer, because those kinds of templating apps are reasonable places to fight the standards war. People that use those things are in someway consenting to having somebody else's opinion over structure applied to their project. I still might complain that it would be nice if I could override it (without "ejecting"), but I feel that the case would be weaker.
...but a testing library that applies it's opinion over the structure of my git repo... nope. Can't get behind that really.

@Wesley hall
I agree with you. Keeping the snapshot file with the test file is the best practice.
Getting the whole structure full of snapshot folders is what's bothering me. I suggest to put the snapshots inside the test file instead of creating a snapshot folder on test file level. Would it be possible?

That's my view too.
In a post above I pasted a link to the line in the code where the __snapshots__ exists as a hardcoded string.
Since jest has the capability of being configured from the package.json file (https://facebook.github.io/jest/docs/configuration.html), what I would tend to do is add a new configuration key called, "snapshotDirectory", that allows for configuration of this. Personally, I would be happy with this value being expressed relative to the test (so the behaviour we are both describing would be configurable by specifying either "." or ""), and leaving the current value as the default.
I might try to pull together a pull request on this over the weekend, but I am not really familiar with the mechanism used to pass these configuration values down. If you, or anyone reading, knows how this is done, i'm definitely all ears on that, otherwise i'll figure it out.

I should say, I don't think they can be put inside the test file, if this is what you meant. There are mechanisms within jest to update the snapshots etc. I wouldn't really want the system changing some portion of the my unit test js file. I would put them still as separate files but as simple siblings to the test js file.

Maybe it's not possible, but it would be great.
I really don't like that behavior. I eve prefer filename.test.js.snapshot
The proposal of config a relative path won't work becouse each file is in diferente place on the structure. Maybe is ok for what I just sayed. But honestly, I prefer to have no option to config it. It's better to have a convention and push community to use it. It reduces fatigue and it makes sharing code easier.

@luispuig
I think (more of less) the "filename.test.js.snapshot" thing is what I am talking about anyway. Essentially, just write the exact same files that are being written now, as siblings to the test files rather than in the __snapshots__ subdirectory.
I think I have decided that I will probably just fork jest, and simply remove the subdirectory hardcoded string in the line of code I linked about, that will do the trick. Wont be configurable, but i'll just use this forked version. It'll be easy enough to rebase over each future release of jest unless they make a change to support this behaviour in the core branch.
I don't imagine I stand much chance of getting this merged back in, but if anyone is reading this and finds themselves particularly interested in this minor fork, I can probably make it public somewhere.
Thanks

@wesleyhall please file the PR to jest if you write the code; it will help the discussion if a tested, clean PR exists that allows the location of snapshots to be configured.

@ljharb
Having had a bit more of a look at this, I actually think it might be a relatively straightforward change.
The engine of the whole snapshot affair is the SnapshotState class defined in State.js inside the jest-snapshot package. If you look at the constructor (https://github.com/facebook/jest/blob/master/packages/jest-snapshot/src/State.js#L48), you'll see that the snapshot path attribute is set from a constructor argument. Only if it's "falsey" does it go off to the "getSnapshotPath()" function which is where the hardcoding of the __snapshots__ directory gets applied. If a path is passed to the constructor it seems it will use that instead.
The object is constructed by the initializeSnapshotState function in the jest-snapshot index.js file (https://github.com/facebook/jest/blob/master/packages/jest-snapshot/src/index.js#L58), which takes the snapshot location as an argument and passes it on to the constructor.
This function is exported, and seems to be only called within the jest-jasmine2 package, inside a file called setup-jest-globals.js (https://github.com/facebook/jest/blob/master/packages/jest-jasmine2/src/setup-jest-globals.js#L115).
Notice that the third argument there is an empty string. That's the snapshot path, so essentially this is getting passed through all the way to the SnapshotState constructor, and since the empty string is 'falsey', "getSnapshotPath()" is called every time.
That exported function in setup-jest-globals.js has access to the config object as an argument though, so I imagine, it might just be a matter of replacing the empty string with something like, 'config.snapshotDirectory'. The function also has access to the testPath (the path to the file being tested), so it should even be possible to support snapshot parts relative to the test location with a "/some/location" style format similar to how "" is used in some other configuration values.
With this, we would have the capability to set both project and test relative snapshot directories, and could default the value to an empty string to maintain backwards compatibility with the existing behaviour.
The problems I am having are two-fold. Firstly, the config system for accepting these arguments is fairly complex, and I am struggling to see how it all fits together. Secondly, I am not exactly a JS veteran and getting a functional local test environment for my changes is proving to be what I generally call, "a ball-ache".
I know it sounds a bit lazy, but assuming my analysis above is somewhere close to correct, I imagine that somebody who works with this codebase regularly and already has a functional local development setup would probably find the change a relatively straightforward thing to do. Most of the work seems to be in adding the config option and passing the value through.
I do think it would be a nice feature, so maybe i'll find the time and patience to figure out the config engine in the coming weeks and get the PR in if nobody with better working knowledge of the codebase is driven to pick it up. You might have to bear with me though.

@wesleyhall Thanks! (http://nvm.sh and nvm install node should theoretically get you a functioning environment unless you're on Windows)

@ljharb :) Well, not a vet but I can get a little further than that ;).
It's more about the yarn link stuff, and getting my local version to properly reflect in a separate project that I can use to test the changes. The contributor docs talk a little about this and linking up the jest-cli module. This didn't work for me at the first attempt, but probably something silly and obvious.
The bigger problem is probably the complexities in the jest-cli and jest-config modules. The configuration options are mentioned and referenced in numerous places. My IDE finds at least 6 different source files that have objects with the snapshotSerializers key. These files are not commented so it's fairly hard to tell what each of them are for and what I need to change to support a new config option. I'll have to deep dive a bit, but i'll have a crack at it when I get chance.

Don't let the number of results scare you when you search for a config key like that. You probably get results for the src and build directories, along with the types for the key.
I have most of the code changed to add this functionality. I need to actually test it then write some tests. I won't continue if you would like to dig in deeper and solve this yourself, and I can help point you in the right direction.

@weslyhall @wyze
Thanks a lot for your work. I really believe this important feature will close the discussion on a good mood.

@wyze
No, please by all means continue. I can look at your PR and see how close (or far) I was :).
I haven't really looked much into the whole flow stuff yet, so there are some gaps in my experience here. Really only started any serious JS work in January of this year, so yeah, n00b :). 20 years on the JVM though. It's all just zeros and ones at the end of the day ;).
I might stick around and learn from the assembled crowd of wizards.
Thanks for your help.

No problem!
I've been working with Reason lately and starting to get to writing snapshot tests for my components, but the problem was when the .re files get converted to .js they are output in another directory. So my snapshots end up in a directory that is in my .gitignore because they are generated test .js files.
This option is exactly what I am looking for so I can store my snapshots in a directory with my tests that are written in .re and checked into Git.

@wyze
Excellent. Thank you again.
Small suggestion having looked at the PR. One of the things I actually wanted to do was get rid of the __snapshots__ directory by configuration. It's all subjective of course, but I don't really like these double underscore directories. The PR looks like it still requires this style though.
If you restore the:
this._snapshotPath = snapshotPath || getSnapshotPath(testPath);
In the SnapshotState constructor, and perhaps rename the function to something like getDefaultSnapshotPath, then I think we would now have complete control over the snapshot directory. Could still, of course, drop the __snapshots__ directory into the config value if you wanted to follow that as convention but just locate them in another place, but would not be forced to.
Perhaps I should be making these comments on the PR itself, but it's just a thought :).

@wyze
Just realised I misread that a bit. The snapshot path attribute should be the full file path not just the directory of course.
Could also change:
path.join(snapshotPath || path.dirname(testPath), '__snapshots__'),
from the getSnapshotPath function to something like:
path.join(snapshotPath || path.dirname(testPath) + '__snapshots__'),
I.e. take the specified path if given, or instead take the testPath with __snapshots__ appended.

I have a directory structure that currently looks like this:
app/
    components/
        Foo/
            __snapshots__
                component.test.js.snap
                reducer.test.js.snap
            component.js
            component.test.js
            reducer.js
            reducer.test.js
        Bar/
            __snapshots__
                component.test.js.snap
                reducer.test.js.snap
            component.js
            component.test.js
            reducer.js
            reducer.test.js

If putting them into a single root snapshots folder is out of the question, would something like below this be more acceptable?
app/
    components/
        Foo/
            component.js
            component.test.js
            component.test.js.snap
            reducer.js
            reducer.test.js
            reducer.test.js.snap
        Bar/
            component.js
            component.test.js
            component.test.js.snap
            reducer.js
            reducer.test.js
            reducer.test.js.snap

Our app is plugin/feature based, so each component is in a separate directory, which contains several files related to it.

@lukescott  we have a modified version we're using that puts the snapshots next to the test as your comment says, simply by removing the snapshots from this line: https://github.com/facebook/jest/blob/master/packages/jest-snapshot/src/utils.js#L94

I mean, they're still technically JS files, so something like:

component.js
component.test.js
component.snap.js

That doesn't address my use case fwiw; I want nothing but tests in one root dir, nothing but production code in another root dir, and nothing but snapshots in another root dir - nothing should ever be colocated.

I'm colocating tests with my code and I've found placing tests under a spec directory helps hide the snapshot directories from your source code, but still keeps it closely tied to the test files. Might be useful for those who don't want to immediately seeing the snapshots directories n your project.
app/
    components/
        Foo/
            spec/
                __snapshots__/
                    component.test.js.snap
                    reducer.test.js.snap
                component.test.js
                reducer.test.js
            component.js
            reducer.js

@cpojer Will you merge a PR implementing your suggested approach?

by adding a config option resolveSnapshots that points to a module with two functions:

exports.resolveSnapshotFile = testPath => snapshotFilePath;
exports.resolveTestFile = snapshotFilePath => testPath;

@cpojer we can also implement it via two regex patterns for the 1:1 mappings.
Right now we have in jest-resolve-dependencies
import {replacePathSepForRegex} from 'jest-regex-util';

const snapshotDirRegex = new RegExp(replacePathSepForRegex('/__snapshots__/'));
const snapshotFileRegex = new RegExp(
  replacePathSepForRegex('__snapshots__/(.*).snap'),
);
const isSnapshotPath = (path: string): boolean =>
!!path.match(snapshotDirRegex);

We can get snapshotFileRegex & snapshotFileRegex from jest config.

@aminroosta i'd love to see that PR; it'd be great to get it open and in a good state where we could advocate for jest to merge it!

Let's say I have service A and service B that expose identical REST API. I want tests for both services and I want to use snapshots feature to store some filtered JSON response returned by service A and service B.  Let's say I have written tests once that may hit one service at time (A or B). I can run them against service A, get snapshots, then I can run them against service B and get new snapshots. It turns out that service A and service B may produce different snapshots for some known reasons. So it sounds reasonable to specify different snapshots locations depending on what service is tested. Because I can't do it through Jest config, I have to maintain copy of the same tests stored in the different folder, but I really want to have just one test and two different snapshots.
I hope this sounds like a real use case to get it supported. I can see it is a rare case, but I think it is related to other cases that people brought here. Thanks!

@joshduck they don't wanna see ↑

@cpojer Disagree, for React Native projects, which we can have more than one platform, is really useful. Check the rendering of the component on iOS, Android, and whatever else show up. Just a way to override the 'SNAP' extension would help a lot already.

This is really unfortunate if you're using a setup where you have source files (e.g. TypeScript) which are checked in and output files (e.g. the corresponding JS) which aren't checked in. The snapshot files end up in a normally-.gitignore'd directory.

So much clutter without this function...

Snapshots are driving my project. Without this function I’m forced to build my own solution, which eliminates the need of using Jest... Bummer.

I don't like the idea of having snapshots directory colocated with every test too and I would rather prefer to have an option to place all of them in a single directory e.g. on the top level. To me, it's just a visual thing and IMHO hundreds of snapshots dirs scattered on a files tree looks really messy. Fortunately, there's a simple workaround for this in VS Code - just exclude snapshots directory from the files explorer in your settings like this:
    "files.exclude": {
        "**/__snapshots__": true
    }

This way snapshots directory will be hidden in the files explorer in your VS Code. I guess sth similar is also possible in Jetbrains' IDEs.

I spent a few hours looking into this, put up a PR #6143 based on a previous suggestion for anyone that's interested.

Seems like you are moving foward with this @viddo. Thanks for your work on this, I'd really like to see this get merged.

Thanks @viddo! 😍

@SimenB This isn't available for me with 24.0.0-alpha.4 even though it should be there.
> jest -v && jest --coverage --config jest.config.js

24.0.0-alpha.4
● Validation Warning:

  Unknown option "resolveSnapshotPath" with value (testPath, snapshotExtension) =>

In case others find it helpful, here is the contents of my snapshotResolver.js implementing @assertchris 's suggestion:
// https://jestjs.io/docs/en/configuration.html#snapshotresolver-string
module.exports = {
  testPathForConsistencyCheck: 'some/example.test.js',

  resolveSnapshotPath: (testPath, snapshotExtension) =>
    testPath.replace(/\.test\.([tj]sx?)/, `${snapshotExtension}.$1`),

  resolveTestPath: (snapshotFilePath, snapshotExtension) =>
    snapshotFilePath.replace(snapshotExtension, '.test'),
}

This results in
component.ts
component.test.ts
component.snap.ts

// jest.config.js
module.exports = {
... ...
snapshotResolver: './snapshots/snapshotResolver.js',
... ...
}
// snapshotResolver.js
module.exports = {
resolveSnapshotPath: (testPath, snapshotExtension) =>
testPath
.replace(/.test.([tj]sx?)/, .test${snapshotExtension})
.replace(/src([/\]components)/, 'snapshots'),
resolveTestPath: (snapshotFilePath, snapshotExtension) =>
snapshotFilePath.replace(snapshotExtension, '.js').replace('snapshots', 'src/components'),
testPathForConsistencyCheck: 'src/components/some.test.js',
}


Implement DataProvider

This adds a DataProvider component according to #28.
To resolve the dependency for geostyler-geojson-parser correctly this lets the package point to a special branch with-dist-folder, which contains the compiled version of the GeoJSON parser. See https://github.com/terrestris/geostyler-geojson-parser/pull/5 for more information.
The PR also contains a demo GUI to show the capabilities of the DataProvider.
The demo UI is currently not runnable due to #32 (but can easily be fixed in local checkout).

The failing tests are related to the fact that the package geostyler-geojson-parser points to this github-branch. While using npm link in the local setup everything is fine. Maybe we have to publish the geostyler-geojson-parser via npm to make this runnable in a sustainable way.

I just added another commit, which includes the published packages for geostyler-data models
and the geostyler-geojson-parser from npmjs.org.
Since now Travis is green we might think about merging this PR.

Thnaks @KaiVolland!


Publishing assets for customization

Is it possible to modify the /canvas navbar?
I would like to modify the component navbar to add a link to the internal area of my application.
Is there any way to publish the views related to /canvas or to change at least the navbar?

The navbar is not editable at this time. What link were you wanting to add if it was?

A link to my application's home page, something similar to:
<a class="dropdown-item" href="{{ route('home') }}"> Application Name </a>
I would add this link to the menu dropdown. I did this for /blog but as I don't have access to the /canvas navbar I couldn't

Good to know, thanks for the info.
Because this topic has been brought up multiple times...

https://github.com/cnvs/canvas/issues/490
https://github.com/cnvs/canvas/issues/604

... I'm going to go ahead and work on a solution. My thought right now is that I'd add an optional config variable where you can specify the path of your frontend. If that exists, then Canvas can use that to add links to various parts of the navigation or posts. I'll tag this when I push the feature.

Another, perhaps simpler approach is to allow resources to be published (optionally) or at least views, so we could customize other aspects as well.

The problem with publishing views is that an upgrade path becomes very un-wieldy. If someone were to customize the views, any future upgrades would be difficult since it would mean overwriting much of the customization.

I would love to edit the assets to make it fit more into the main site. Even if that would make upgrading harder, since it was my decision I don't see that as a problem.

Publishable assets gets my vote: anyone who wants to edit will be doing so knowing they are moving from the core and surely will expect upgrades to be more involved.

That sounds reasonable enough.
That being said, I'm not actually aware of any packages that do this. Supporting the base installation, (ie. assets being read from the vendor directory) as well as a customizable app experience seems problematic, since you'd have the freedom to write/compile the assets and those would, theoretically,  not compile into the vendor directory.
How do you propose supporting both those scenarios?

Isn't the normal practice for the package to firstly use it's own assets, stored within vendor, then use any published assets if the command has been run?
Would another option be to allow for specifying options in settings for each visual component that can be edited? Not that you'd want to give every component over, but perhaps the main ones (nav, body, footer)? Couple this with being able to publish the "vanilla" versions you provide and it becomes pretty powerful (though with the same restriction I mentioned earlier of upgrades being more involved).
Caveat: I've never developed a package, so might be missing something fundamental here.

From what I understand in the docs, that logic pertains to the blade files. You are able to override package views, however the only "view" for Canvas is a layout file, and it's simply a wrapper for the Vue SPA.
I don't believe there's a way to override the packaged CSS/JS with Laravel at this time. That being said, I could be wrong and would love to have anyone inform me otherwise.
I'm not totally against the idea of customizing certain aspects or components of the app, however it'll just take some thoughtful brainstorming before pushing something like that out.

Searching i found a possible solution... look this, [Public Assets] (https://laravel.com/docs/7.x/packages#public-assets) @austintoddj .
As i understand it, the problem would be publish the assets of package (Vue CSS/JS).
Using the service provider's publishes method is possible copy the files to "development director" and would be optional feature.
Whoever wishes this, run the command php artisan vendor:publish --tag=canvasVue. When package update, the developer run the same command with the parameter --force to overwrite the assets and then just modify again according your need.
I would be happy to implement this feature, for now I will update my fork and test this.
Another future possibility that I thought was just as you separated part of the package with Studio, we can do the same with the Front-end of the internal part. I thought of a structure similar to:

cnvs / canvas (Back-end) -> Laravel files
cnvs / studio (Front-end Public) -> Vue files, from the viewing side, as is already done
cnvs / editor (Front-end Private) -> Vue files, from the internal area

We can also allow the developer to publish the assets of any of the packages and modify them.
This also allows for a future implementation of Themes for Canvas (A developer can make his modified package available from the "studio" or "editor"), for that it would be enough to use these packages as a standard to be followed.
P.S.: I'm Brazilian, sorry for grammatical errors

alternatively could we have a config item to set the name of the layout blade? That way we should be able to at least fit it into a page framework keeping our own navbar etc...

Closing since the original question has been answered.


Installation guide for dapr on k8s arm cluster is missing

Installation guide for dapr on arm device is missing.

[ ] Provide the guide to deploy dapr in k8s arm cluster using helm.
[ ] Add caution to dapr cli init --kubernetes

Supporting multi-arch images. Not needed.


TIMX 350, 351, 358, 346 - full app functionality via CLI

Purpose and background context
This PR combines the work of the following tickets into a single PR, resulting in an "MVP" of sorts for this application, where only the CLI is required to create a job, run a diff, and view the results in a webapp:

https://mitlibraries.atlassian.net/browse/TIMX-350
https://mitlibraries.atlassian.net/browse/TIMX-351
https://mitlibraries.atlassian.net/browse/TIMX-358
https://mitlibraries.atlassian.net/browse/TIMX-346

For reviewing, it is recommended to review commit-by-commit, which correlate 1:1 with the tickets.  Thanks again to reviewers for enduring a large PR in the name of wrapping up this first pass at the app, with plenty more improvements to come that will not be thusly grouped.
Comments have been added in the code itself for areas of interest or woth some extra attention.
Performance and resource management (CPU, memory) is quite good, but still room for improvement.  Created fake transformed records in the amount of 10 million, and the core functions after run_ab_transforms handled this volume very well.  But -- related to this open TIMX spike work -- the bottleneck remains Transmogrifier.
While this app could quite readily handle 20 Alma files @ 1gb each @ a total of 3m+ records, the run_ab_transforms are still time consuming.  It's difficult to make an estimate: each file may take 1+ hours to transform, but theoretically this app would be performing them all in parallel.  While faster, it also relates to TIMX-356 which will investigate how many parallel containers is feasible.  These tunings are non-trivial.  Transmogrifier is somewhat slow because it does not consume many resources, so it's possible that quite a few could run in parallel as-is.  But should we tune Transmog to consume more resources and thus transform faster, we may need to limit this app in how many parallel containers run.  Exploration opportunities abound!
Paradoxically, this app will help test future performance improvements to  Transmogrifier!  And, should we shift to Parquet output from Transmog, this app can also be beneficial in testing that (with the additional work of it supporting transformed files in parquet format vs current JSON files).
How can a reviewer manually see the effects of these changes?
1- Set AWS credentials
Retrieve production AWS TIMDEXManagers keys and set in .env, e.g.:
AWS_ACCESS_KEY_ID="ABC..."
AWS_SECRET_ACCESS_KEY="DEF..."
AWS_SESSION_TOKEN="XYZ..."

2- Create new Job
pipenv run abdiff --verbose init-job \
-d output/mvp \
-m "test of full CLI workflow" \
-a 395e612 \
-b cf1024c

This creates a Job directory with job.json:
{
  "job_directory": "output/mvp",
  "job_message": "test of full CLI workflow",
  "image_tag_a": "transmogrifier-mvp-395e612:latest",
  "image_tag_b": "transmogrifier-mvp-cf1024c:latest"
}

3- Run diff on set of input files
pipenv run abdiff --verbose run-diff \
-d output/mvp \
-i "s3://timdex-extract-prod-300442551476/alma/alma-2023-02-19-daily-extracted-records-to-index.xml,s3://timdex-extract-prod-300442551476/libguides/libguides-2024-04-03-full-extracted-records-to-index.xml,s3://timdex-extract-prod-300442551476/dspace/dspace-2024-10-11-daily-extracted-records-to-index.xml"

After completion, should see a similar file structure in Job folder:
output/mvp
├── job.json
└── runs
    └── 2024-10-15_19-44-05
        ├── collated
        │   └── records-0.parquet
        ├── diffs
        │   ├── has_diff=false
        │   │   └── records-0.parquet
        │   └── has_diff=true
        │       └── records-0.parquet
        ├── metrics
        │   └── metrics.parquet
        ├── run.json
        └── transformed
            ├── a
            │   ├── alma-2023-02-19-daily-transformed-records-to-index.json
            │   ├── dspace-2024-10-11-daily-transformed-records-to-index.json
            │   └── libguides-2024-04-03-full-transformed-records-to-index.json
            ├── b
            │   ├── alma-2023-02-19-daily-transformed-records-to-index.json
            │   ├── dspace-2024-10-11-daily-transformed-records-to-index.json
            │   └── libguides-2024-04-03-full-transformed-records-to-index.json
            └── logs.txt

Observations on the core functions:

calc_ab_diffs

produces a dataset under run/diffs
this contains the full A/B records and their JSON diff
this suggests we could delete the transformed and collated data, as all is contained here

calc_ab_metrics

produces a dictionary of aggregate counts of fields and sources that differ from the diffs
if/when more metrics are found helpful, added to this function, and they will filter into that data
also produces a metrics/metrics.parquet file (single file) that is a "sparse matrix" of all records in the run, and a boolean 1 or 0 if that record has a diff for each TIMDEX field (columns)

this provides quick and efficient querying via DuckDB, and is what supports the metrics JSON that is derived

4- View job via webapp
pipenv run abdiff --verbose view-job \
-d output/mvp

Some observations on the webapp:
Job (root) Page

note that the input files are shown in the table for the "Runs"

Run Page

note the run data at the top has a metrics section, but also broken out into own viewer
transform logs are available as a collapsible click (see TIMX-368 for possible changes here)
under "Diff Metrics" the analysis section has some quick counts for diffs by field or by source
the "Record Links" section at the bottom will provide links to view records that have diffs in those dimensions

e.g. the link for dates will show max 100 records per source that have diffs for that field
e.g. the link for contributors shows that both dspace and alma had one record each with a diff for this field

Record Page
Example: record alma:9935037356906761

summary at the top has some cursory information about the record; good place for future extension
record versions "A" and "B" available in their entirety; pulled from diffs parquet dataset
"Side-by-Side Diff" section at the bottom shows exactly how the two differ
currently a known bug (TIMX-367) where the A/B records don't render if they have yet-known-which special characters in the record anywhere

Includes new or updated dependencies?
YES
Changes expectations for external applications?
NO
What are the relevant tickets?

https://mitlibraries.atlassian.net/browse/TIMX-350
https://mitlibraries.atlassian.net/browse/TIMX-351
https://mitlibraries.atlassian.net/browse/TIMX-358
https://mitlibraries.atlassian.net/browse/TIMX-346

Developer

[X] All new ENV is documented in README
[X] All new ENV has been added to staging and production environments
[X] All related Jira tickets are linked in commit message(s)
[X] Stakeholder approval has been confirmed (or is not needed)

Code Reviewer(s)

[ ] The commit message is clear and follows our guidelines (not just this PR message)
[ ] There are appropriate tests covering any new functionality
[ ] The provided documentation is sufficient for understanding any new functionality introduced
[ ] Any manual tests have been performed or provided examples verified
[ ] New dependencies are appropriate or there were no changes

@ehanson8 , @jonavellecuerdo - please note newly created ticket TIMX-369 which requests better error handling in the CLI command run-diff.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>1
Details

168 of 217 (77.42%)  changed or added relevant lines in 6 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-7.0%) to 90.662%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

abdiff/webapp/app.py
15
31
48.39%

abdiff/webapp/utils.py
15
48
31.25%

Totals

Change from base Build<PHONE_NUMBER>7:
-7.0%

Covered Lines:
534

Relevant Lines:
589

💛  - Coveralls


CREATE GRAPHIC DESIGN

CREATE GRAPHIC DESIGN - BANK

You need to decide what to contribute and follow the procedure before contributing okay.. you can re-do so.


Implement the DynamicLookupProtocol proposal.

This is an implementation of the DynamicLookupProtocol that I am proposing for inclusion in Swift.  It has no known implementation problems, but I absolutely welcome feedback on the implementation approach.
The approach is straight-forward.  It does not bloat any core data structures and is not invasive into the compiler.  High points of the patch:

Add the new protocol to the standard library.
When ConstraintSystem::performMemberLookup is about to fail a value member lookup, check to see if the base type conforms to DynamicMemberLookupProtocol.  If so, add the subscript(dynamicMember:) implementations to the candidate set as a new OverloadChoice::DynamicMemberLookup kind.
CSApply handles OverloadChoiceKind::DynamicMemberLookup by calling buildSubscript().
Add a test case handling many weird cases I could think of.

@swift-ci please test

Build failed
Swift Test Linux Platform
Git Sha - 3d0399452f8963b14074fe843bfb164b0ca08fa6

Build failed
Swift Test OS X Platform
Git Sha - 3d0399452f8963b14074fe843bfb164b0ca08fa6

I'll be out of town for the next few days, but I'll take a look at the test failures and fix them when I get back.

I'm generally concerned with how long some of the functions like CSApply's buildSubscript() are getting. If you could split it up a bit it would be great

Thank you for the detailed feedback @slavapestov!  When I get a chance to come back to this later this week or early next week, I'll pull in changes for your feedback into the next version of the patch.  I appreciate it!

I'm closing this, moving forward to PR 13361 which incorporates Slava's feedback and another change.  Thanks!


/v1/incidents option consistency with /v1/911-calls

Describe the feature
Could we please get the switches available on 911-calls added to the incidents GET API call too. Including the new filter for IDs which has helped me cut out lots of inefficient code.

[ ] department
[ ] division
[ ] assignedUnit
[ ] includeEnded - this would show active and inactive incidents respectively the same behaviour as 911 calls

Additional Context
No response

includeEnded is already supported using activeType:

active: return only active incidents
inactive: return only inactive incidents
all: return all incidents

department
division

Will not be supported because there's no direct saved item in the database. I could check where an assigned unit has these options though, but that could slow down the API request

department
division

Will not be supported because there's no direct saved item in the database. I could check where an assigned unit has these options though, but that could slow down the API request

That's okay! The most important one was understanding activeType and assignedUnit - I agree we don't want to add anything that slows the API request 😄

Cool, will close this now then :)


Webpack support

ability to compile scss files to css and also combining multiple JS together

Nice 👍 👍

what will be the js lib to be adopted  vue or react ,angular

I believe this is consistent with the bast_boilerplate repo


Autogeneration of odin grammar documentation

OK, I(REALLY)DK how to test this.... but this PR adds the ability for the RuleReader to generate two diff documentations automatically.
NOTE: MUCH of this code was written by @jastier -- I wish there was a better way to credit him in this PR than just mentioning him :/
The first is a view that is based on the Rules, one block per rule.
The second view aggregate this information by Type of Mention (i.e., label).
Each generated file is a markdown file.
entrypoints in RuleReader:

exportRuleSchemasFromMaster
exportRuleSchemasFromSimple
exportExtractionSchemasFromMaster
exportExtractionSchemasFromSimple

Here is a sample of the Rule view:
Odin Rule Schemas

rule: agree_token_match

attribute
value

type
TokenExtractor

labels
[Agreement, Communicate, SimpleActions, Action, EventLike, Concept]

priority
2

keep
true

rule: agreement2

attribute
value

type
TokenExtractor

labels
[Agreement, Communicate, SimpleActions, Action, EventLike, Concept]

priority
2

keep
true

argument name
label(s)
quantifier
required?

source
Concept
?
false

target
Concept
?
false

And here's a sample of the Extraction view:
Odin Extraction Schemas

You

Attribute
Value

rules
you_token_capture

label hierarchy
[You, Entity, Concept]

priorities
1

keep
true

No arguments

ChangePriority

Attribute
Value

rules
[change_priority2, change_priority]

label hierarchy
[ChangePriority, ComplexActions, Action, EventLike, Concept]

priorities
3+

keep
true

actions
removeResearcher

Arguments

name
label(s)
quantifier(s)
required?

target
[Victim, Person]
none
true

person
[Entity, Entity]
?
false

MakeCommitment

Attribute
Value

rules
commit_to_something

label hierarchy
[MakeCommitment, Commitment, ComplexActions, Action, EventLike, Concept]

priorities
7+

keep
true

actions
removeResearcher

Arguments

name
label(s)
quantifier(s)
required?

target
[Action]
none
true

person
[Self]
?
false

FYI @jastier  @adarshp @remo-help

@kwalcock if you need me to add tests please let me know what they should look like.  I'm hesitant to add soemthing and it be like "I expect the string to == this" bc that's kinda a bad test, but other than that I am at a loss.
Otherwise, if we don't need tests, then this is done.

This is great, thank you @jastier and @BeckySharp !

Thank you Becky!
On Thu, Jun 10, 2021 at 10:29 AM Adarsh Pyarelal @.***>
wrote:

This is great, thank you @jastier https://github.com/jastier and
@BeckySharp https://github.com/BeckySharp !
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/clulab/processors/pull/502#issuecomment-858815125,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ACD6H4ZPQDB7U5D3XMD2GD3TSDY7LANCNFSM46NLMJ3Q
.

Thanks for adding the test.  I'd like to dub it the safety blanket test.  It makes me feel more secure.  More to follow...

Thanks also for the uncommas ;-)

This seems like a great idea.  I really like that there is no additional library dependency to deal with.  It might could (double modal verb construction (c) @kwalcock) do with a MarkdownTable class, but some other time.  I will eventually add a
class Test extends FlatSpec with Matchers

somewhere so that it doesn't need to be repeated ad infinitum.  This seems not too many steps away from generating Scala code in addition to the markdown.  I look forward to thinking about what might be done with that.  If nobody has second thoughts, I will merge shortly.

I didn't notice any main that generates documentation, so it probably belongs to the projects that use processors.  The test earns bonus points if it demonstrates how they should go about it.  It seems to. +1


Add Tags to the AmplifyApp

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Describe the solution you'd like
A clear and concise description of what you want to happen.
Additional context
Add any other context or screenshots about the feature request here.

@akanungo22 we'll take the feature request to add app tagging in the console. In the meantime you might see if our TagResource API could work for you. https://docs.aws.amazon.com/amplify/latest/APIReference/API_TagResource.html

Thank you.. I have been tagging the apps using aws cli, as of now.

From the AWS console, tagging is not visible. I added the tags using AWS CLI and in my Amplify Cloudformation template, but that is not reflecting in the AWS console.


Bound wisp consuming itself doesn't unbind it, and permanently locks you out of using Bind Wisp

On the Hexxycraft server, I made a bound wisp self-destruct via casting Consume Wisp on itself, and I'm now unable to bind a new wisp.
Initially, casting Familiar's Reflection returned an entity reference to the wisp, despite the fact that it seemingly no longer existed. Patterns like Compass Purification and Manager's Purification worked exactly as expected on this entity reference, ie returned the relevant information with no mishap.
In an attempt to properly unbind the wisp, I manually cast Consume Wisp on the entity reference returned by Familiar's Reflection. Doing so caused my casting grid to hang (ie the Hermes Gambit I used to trigger the effect turned grey), and when I closed and reopened the grid the Hermes I'd drawn was just gone. I drew it again, which seemed to work, resolving without mishap and turning all the remaining entity references to the wisp into NULL.
However, after doing this, I'm still unable to bind a new wisp - trying to do so fails silently, without even ending the overall cast if done partway through a hermes/wisp execution. Casting Familiar's Reflection mishaps, giving the following message in chat:

I appear to now be permanently locked out of using Bind Wisp. Is there anything I can do?

not going to close this till 0.2.17 has actually been tested on the server to confirm that it's fixed, but I think I fixed this properly

I think this is fixed now? reopen if not


map-matching SNAPSHOT versions

Is there a SNAPSHOT version for map-matching following the corresponding GraphHopper one and according to the master version in pom.xml?
i.e. 0.7-SNAPSHOT in https://oss.sonatype.org/content/groups/public/com/graphhopper/

Currently not automatically deployed but you should be able to always use the latest master from GH core.

Sorry Peter, I didn't understand. I use the latest master from GH.
I'm asking how we can use the latest master from map-matching without building the code.

I'm asking how we can use the latest master from map-matching without building the code.

Sorry, I meant with "not automatically deployed" that you would need to build it yourself from code. (There is no such process yet like it is the case for GH)

This depends a bit on this issue https://github.com/bmwcarit/hmm-lib/issues/4 although this is currently in the works ...

Will now deployed regularly with the core if no errors. For now this is just a workaround using hmm lib as if it were 'our' module.

BTW: should we rename graphhopper-map-matching to graphhopper-map-matching-core similarly like we renamed graphhopper to graphhopper-core? Although this is not that important as it does not really conflict

should we rename graphhopper-map-matching to graphhopper-map-matching-core similarly like we renamed graphhopper to graphhopper-core?

You mean the artifactId in the pom ?

YEs

Yes that could change, its folder has the -core already.

Ok, done


Fix RulePredicates#setIsMeetingRequest setter

Currently the setter refers to the wrong field, so RulePredicates instances can't be modified correctly.

Hi @milesk-amzn, I'm your friendly neighborhood Azure Pull Request Bot (You can call me AZPRBOT). Thanks for your contribution!

This seems like a small (but important) contribution, so no contribution license agreement is required at this point. Real humans will now evaluate your PR.

TTYL, AZPRBOT;

Current coverage is 10.43% (diff: 0.00%)

Merging #586 into master will not change coverage

@@             master       #586   diff @@
==========================================
  Files           550        550
  Lines         20436      20436
  Methods           0          0
  Messages          0          0
  Branches       2626       2626
==========================================
  Hits           2132       2132
  Misses        18151      18151
  Partials        153        153

Powered by Codecov. Last update 0e1ba52...1b29931


⚠ Bofrost.at has degraded performance

In 9ae6c03, Bofrost.at (https://www.bofrost.at) experienced degraded performance:

HTTP code: 200
Response time: 1492 ms

Resolved: Bofrost.at performance has improved in e40cda8 after 35 minutes.


Add a video driver using mplayer

Also contains the 3-digits FPS change :)
Thanks to the flexible usage of the palette, we can pre-compute once the palette in YCbCr and then directly use that as pixel values.
This is not as fast on MRI as FFI, maybe pack is expensive?

@mame Do you have any opinion or plan to merge this?

Sorry, I overlooked this PR!  Merged, thank you!

Thank you!


luci-app-samba: Shared directory help text.

forum.lede-project.org member metropetro had trouble understanding how to configure Samba.
I would like to add some help text to the UI.  Example at: https://forum.lede-project.org/t/creating-a-laymans-configuration-instruction-for-samba/868/11 .
Here's my proposed code in luci-app-samba/luasrc/model/cbi/samba.lua :
s = m:section(TypedSection, "sambashare", translate("Shared Directories")
, translate("Please add directories to share.  Each directory refers to a folder on a mounted device."))
I'd like to add a help.gif icon before it.  But, I'm not sure of the proper syntax.  Could someone point me to appropriate documentation or examples?
Thanks, Bob

Replaced by https://github.com/openwrt/luci/pull/1265


docs: mention templates in contributing section of README

@bcoe Do you mind giving a summary for this 250 file change? Not sure what this is doing. Thanks.


CLI: sync report logic \w Linguist

Fixes #204 by adjusting Enry CLI app behavior according to Linguist upstream.

[x] change defaults to show only programming and markup
[x] fix -mode=bytes and make it default, fixes https://github.com/src-d/enry/issues/215

Here is the output of enry from this PR and linguist 7.3.0
$ enry /tmp/linguist-django/django/
95.86%	Python
1.85%	JavaScript
1.65%	HTML
0.63%	CSS
0.01%	Shell
0.00%	Smarty
0.00%	Makefile

$ linguist /tmp/linguist-django/django
95.86%  Python
1.85%   JavaScript
1.65%   HTML
0.63%   CSS
0.01%   Shell
0.00%   Smarty
0.00%   Makefile

@creachadair thank you for detailed review! All feedback was addressed and it's ready for another round.
Meanwhile, I'll going to look into CI failures.

CI failure looks irrelevant - they did pass before but then, after the doc update it started to fail on multiple runs.
If no objections, going to fixing those in a subsequent PRs.


[QA]  Avatar gets stuck inside GP bar

Explorer Alpha build versions:

v0.21.0

Issue Description:
When interacting with the GP bar, the avatar can get stuck after jumping or running through the bar multiple times. This issue causes the avatar to be immobile, requiring a respawn to resolve the situation.
STR:

Launch the explorer.
Go to the GP bar.
Run through the bar and jump on it a few times.
Observe if the avatar gets stuck inside the bar.

Current behavior:
https://github.com/user-attachments/assets/b6d309d6-0149-4d18-a644-269e9874cc12
Player LOGS:
Player.zip

@ShibuyaMartin can you please take a look at Genesis Plaza colliders?

fixed

Checked on windows and Mac and we cannot replicate the issue. Closing it now! ✔


possible config derp?

Minecraft version & Mod Version:
1.12.2                      1.12.2-1.15.3
Single player or Server:
single player
Describe problem (what you were doing / what happened)
ores are spawning in the nether even when configs are turned off as far as i know
Crash log (if any):
doesnt crash but is odd
cyclic ores
https://pastebin.com/Wa9qit3L
cyclic magic
https://pastebin.com/tAKn6apw
(If this is a suggestion and not a bug report, delete all this and just write your suggestion!)

Excuse me,can you upload your game screenshots to github?I'll try to find a method to solve your issue.

i was told only to upload the configs so thats wat i did

also what screenshots and ill try to get them for you

I'd like to see your world's Nether or End screenshots.

Looks like globalOverride=false is set, which disables only all the modded ores. In other words, this only applies to blocks in THAT standalone config file.
In the second config file on line 781 it has
"Nether Ore"=true
and also
B:"End Ore"=true
on 775

umm nether might be possible but the end is not even doable atm cause new world and not even found the portal yet

as requested above lol

also i found out if you silk touch the ores then they drop as normal which imo is ok just hope it doesnt change hehe

In newest versions, silk touch drops the raw ore and not the items ( silk touch enchant). Looks like configs are working fine as well, so thanks for the report!


Support displaying Dockerfile content in Harbor UI

We set up a Harbor in our virtual machine environment and build/push images to Harbor projects.

But now we can only see some images basic information for this images
Can we support push and upload the dockerfile to harbor and display it in a single page just like the Docker hub does.
For the management of images, I think there are great benefits to display dockerfile

We may support adding description to the images, however, we may not support dockerfile as currently are not sure how to verify if the image and dockerfile matches.

duplicate of #1088 . close this for now.


Updated LGSM documentation and added a script to automate the entire process

I updated the article to include a link to my automation script to install everything with 1 command. [Minus the cfg.tf part.]
I updated the LGSM configuration documentation as the LGSM project changed how they did their configuration.

Sweet thanks, merging now.


MiniGame. In ModelViewer.cpp USE_VERTEX_BUFFER =1 crashes driver.

If you use verterx buffers to render by changing USE_VERTEX_BUFFER to 1
in ModelViewer.cpp, line 39, you will get this error on an NVIDIA GTX 970 Ti.  Driver 361.43
D3D12: Removing Device.
D3D12 ERROR: ID3D12Device::RemoveDevice: Device removal has been triggered for the following reason (DXGI_ERROR_DEVICE_HUNG: The Device took an unreasonable amount of time to execute its commands, or the hardware crashed/hung. As a result, the TDR (Timeout Detection and Recovery) mechanism has been triggered. The current Device Context was executing commands when the hang occurred. The application may want to respawn and fallback to less aggressive use of the display hardware). [ EXECUTION ERROR #232: DEVICE_REMOVAL_PROCESS_AT_FAULT]
Exception thrown at 0x00007FF8D1211F08 in ModelViewer.exe: Microsoft C++ exception: _com_error at memory location 0x0000003E146FD030.
Exception thrown at 0x00007FF8D1211F08 in ModelViewer.exe: Microsoft C++ exception: _com_error at memory location 0x0000003E146FD1C0.
Exception thrown at 0x00007FF8D1211F08 in ModelViewer.exe: Microsoft C++ exception: _com_error at memory location 0x0000003E146FD030.
Exception thrown at 0x00007FF8D1211F08 in ModelViewer.exe: Microsoft C++ exception: _com_error at memory location 0x0000003E146FD1C0.

You also need to set USE_VERTEX_BUFFER to 1 in ModelViewerVS.hlsl and DepthViewerVS.hlsl.  I set all 3 instances to 1 and everything renders fine on that driver for me.  If I only set the one in the .cpp file then the device will be removed.

I just saw that.  This is poor coding practice.  There should be a single include file that set this.

There is a line in the shaders:
"#elif USE_ROOT_BUFFER_SRV"
but this is not defined in any shader code.  This also should be in a shared header file.

Can i run on Geforce  GT  630  Card ?   Nvidia Web   says that  DX  12 api is supported,  when i  have downloaded  and  tried   to  run  some  kind of  Exception  is popping up on  my monitor , i could not  figure out reason is Driver  or GPU does  not  supported  but  i  think  first  one more  relevant, because  if  issue  is  GPU i think  different  error would be shown and more clear  error  would  pop up. What  u  think pals ?! :)

We left some optional code paths in MiniEngine for our benefit (like validating driver functionality), but we don't expect people to arbitrarily turn on these other code paths.  Perhaps this extra code is a distraction and we should remove it from the GitHub branch of MiniEngine.  I thought this particular code split was educational because it shows three different ways to stream vertices:  a vertex buffer, a buffer pointer, and a buffer descriptor.  But it's not well documented, as you noticed.  Control flow #defines should be in one place for easy changes.  I'll make the changes.  Thanks.


Fixed 2 broken tests

Fixed 2 failed tests:

divide by zero
host_function_not_found

Interestingly for me with the following toolchain which is the same as this project's CircleCi config
nightly-2020-04-17-x86_64-apple-darwin 1.42.0-x86_64-apple-darwin
there is no failures for these tests.
@royyang-centrality what is your toolchain setup?

@alexsednz I think i'm using a later version of the compiler.
I find it strange as well


Can't disable internal keyboard

I found the interface to disable any device in device tab.
but my apple keyboard can't not disabled.

sorry my fault
Disable the built-in keyboard while one of the following selected devices is connected
that meaning is just select one of keyboard which I want to use


Examples in misc config-manager.ts requires update

Describe the bug
To Reproduce

npx ts-node config-manager.ts
error:

config-manager.ts:10:46 - error TS2339: Property 'generateAddress' does not exist on type 'typeof import

it's an outdated example, I'll update it


Highlight problem for cpp code

Thanks for such an awesome tool! It's really creative.
The generated HTML seems to miss some token, could you please have a look(The DO_NOT_TAKE_OWNERSHIP token should be marked as copied)?

The left file content:
// Copyright 2001 - 2003 Google, Inc.
//
// Google-specific types

#ifndef BASE_BASICTYPES_H_
#define BASE_BASICTYPES_H_

#include "kudu/gutil/integral_types.h"
#include "kudu/gutil/macros.h"

// Argument type used in interfaces that can optionally take ownership
// of a passed in argument.  If TAKE_OWNERSHIP is passed, the called
// object takes ownership of the argument.  Otherwise it does not.
enum Ownership {
  DO_NOT_TAKE_OWNERSHIP,
  TAKE_OWNERSHIP
};

// Used to explicitly mark the return value of a function as unused. If you are
// really sure you don't want to do anything with the return value of a function
// that has been marked WARN_UNUSED_RESULT, wrap it with this. Example:
//
//   scoped_ptr<MyType> my_var = ...;
//   if (TakeOwnership(my_var.get()) == SUCCESS)
//     ignore_result(my_var.release());
//
template<typename T>
inline void ignore_result(const T&) {
}

#endif  // BASE_BASICTYPES_H_

The right one:
// Copyright 2001 - 2003 Google, Inc.
//
// The following only applies to changes made to this file as part of YugaByte development.
//
// Portions Copyright (c) YugaByte, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
// in compliance with the License.  You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software distributed under the License
// is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
// or implied.  See the License for the specific language governing permissions and limitations
// under the License.
//
// Google-specific types

#ifndef BASE_BASICTYPES_H_
#define BASE_BASICTYPES_H_

#include "yb/gutil/integral_types.h"
#include "yb/gutil/macros.h"

// Argument type used in interfaces that can optionally take ownership
// of a passed in argument.  If TAKE_OWNERSHIP is passed, the called
// object takes ownership of the argument.  Otherwise it does not.
enum Ownership {
  DO_NOT_TAKE_OWNERSHIP,
  TAKE_OWNERSHIP
};

// Used to explicitly mark the return value of a function as unused. If you are
// really sure you don't want to do anything with the return value of a function
// that has been marked WARN_UNUSED_RESULT, wrap it with this. Example:
//
//   scoped_ptr<MyType> my_var = ...;
//   if (TakeOwnership(my_var.get()) == SUCCESS)
//     ignore_result(my_var.release());
//
template<typename T>
inline void ignore_result(const T&) {
}

#endif  // BASE_BASICTYPES_H_

Thanks for the report. Are you getting that result consistently? I tried it on my machine and it's highlighting that token.
My guess is this is happening because of the gap between noise_threshold and guarantee_threshold. If guarantee_threshold > noise_threshold, the algorithm may miss small gaps like this but is guaranteed to detect any section with more than guarantee_threshold overlapping tokens. Winnowing does this for speed concerns.
By default, noise_threshold = 25 and guarantee_threshold = 30. Try setting the latter to 25 (add -g 25 to the command) and see if that solves the issue. The original winnowing paper is quite old and I think for most use cases speed isn't really an issue, so I might just set that to be the default in the next version.

Thanks, after changing the -g and -n values to be the same, it's fixed.

Is the current version 0.4.6 producing the correct highlights?


Update README.md to correct reference to example of pattern system

Not quite right! The default value of the name_pattern uses data patterns, meaning, it takes an input.
"{pubdate::%Y-%m-%d} {rss::episode::title}"
here the input of pubdate is the format of the date, and the inpiut of rss::episode is the 'title' tag of in the xml file.
But the section youre changing here is to demonstrate unit patterns. these take no input, and are the same no matter what episode is downloaded. So the download_path default is "{home}/talecast/{podname}", here home always refer to your home directory, and podname uses the name of the configured podcast, they are the same no matter what the episode is.
if you know a way to rephrase to make it less confusing then please make a code suggestion ^^

Doh! I think I was just skimming too fast. I thought that sentence was talking about the table below, but now I look at it, it's clear that it was talking about the table above.
To make it super-clear, you could make "Unit Patterns:" and "Date Patterns:" headings, but you already have three levels of headings and I suspect you don't want to add a fourth level :)


chore: Updated prisma/reflector package to latest version

This pr on fixes the Safari compatibility issue with the datasourceBlockPattern regex.
This PR just updates the version of the library to contain this change.

Wow I messed that up somehow https://github.com/prisma/templates-node/commit/b3c18a51e35a855e1a957a8fe641404005f939e8 ... only the lock file was changed??


[Bug]: Could you make 7.4.2 compatible i cant use without php 8

What happened?
cant install and run with php 7.4.2
How to reproduce the bug
try to install and run with php 7.4.2
Package Version
1
PHP Version
7.4.2
Which operating systems does with happen with?
Windows
Notes
that is i just want to know if the package could be made to run in older php versions

manage to install with the command php /usr/local/bin/composer install --ignore-platform-reqs and in the composer.json ````{
"require": {
"kambo/langchain": "0.2.0-alpha"
},
"config": {
"platform": {
"php": "7.4.2"
}
}
}

cuz chatgpt train data only before the year of 2021, how can i get the newest infos on web?i assume langchain is a propriate way to achieve this goal,can u implement using the php coding?

@frankchieng you will have to implement the browsing feature by yourself.

Required package "kambo/langchain" is not present in the lock file.
This usually happens when composer files are incorrectly merged or the composer.json file is manually edited.
Read more about correctly resolving merge conflicts https://getcomposer.org/doc/articles/resolving-merge-conflicts.md
and prefer using the "require" command over editing the composer.json file directly https://getcomposer.org/doc/03-cli.md#require-r

@Razikale365

PHP 7.4 is already at its EOL.


Add syntax highlighting for R code?

The easiest way to do this is probably via react-syntax-highlighter, but I couldn't find an existing theme that I felt matched the style of the rest of the site well enough: https://github.com/remarkjs/react-markdown#use-custom-renderers-syntax-highlight

Thanks for your work!
Syntax highlighting would be very helpful. Here is a react-syntax-highlighter demo that lets you flip through common themes: https://react-syntax-highlighter.github.io/react-syntax-highlighter/demo/
There is a couple I like with other languages but not with R. It seems like the R grammar for highlight.js is not very expressive.
Nonetheless I find non-highlighted code hard to read quickly, so I think any theme would be helpful.


Includes have random order

Hi all, I'm having trouble testing my JSONAPI response as the order in included changes randomly 😢
What is the logic there and is there a workaround for it? I'm using MarshalOnePayload.
Cheers

The reason why the order is seemingly random is because the underlying data structure is a map. When iterating over a map in go you will find that the order changes every time you execute the code. For instance given a main.go file with:
package main

import "fmt"

func main() {
	groupOfTen := map[string]string{
		"BE": "Belgium",
		"CA": "Canada",
		"FR": "France",
		"DE": "Germany",
		"IT": "Italy",
		"JP": "Japan",
		"NL": "Netherlands",
		"SE": "Sweden",
		"CH": "Switzerland",
		"UK": "United Kingdom",
		"US": "United States",
	}
	for k, v := range groupOfTen {
		fmt.Println(k, v)
	}
}

The first time I ran this file:
$ go run main.go
FR France
IT Italy
JP Japan
CH Switzerland
US United States
BE Belgium
DE Germany
NL Netherlands
SE Sweden
UK United Kingdom
CA Canada

The second time:
$ go run main.go
IT Italy
NL Netherlands
SE Sweden
CH Switzerland
UK United Kingdom
US United States
CA Canada
FR France
JP Japan
BE Belgium
DE Germany

The third time:
$ go run main.go
BE Belgium
NL Netherlands
SE Sweden
CH Switzerland
CA Canada
FR France
DE Germany
IT Italy
JP Japan
UK United Kingdom
US United States

And so on and so forth. Every time you execute the file you should expect a varying order. In go you should not rely on a map if you required ordered data - there are other data structures for that.
The underlying data structure for the included key that this library produces is a []*Node (see here and here). However this  []*Node slice is populated by iterating over the Relationships which is a map[string]interface{} (see here). This random iteration order over Relationships is what is producing the behaviour you have described. This behaviour is expected and is JSON API specification compliant.
The tests you are writing should be resilient to this kind of change in ordering. If you provide me with a code sample I will be able to point you in the right direction.

Thanks for the nice explanation, I'm quite new to Go(and i love it), so still need to learn a lot about it.
type Restaurant struct {
	ID    uint    `jsonapi:"primary,restaurants"`
	Name  string  `jsonapi:"attr,name" valid:"required"`
	Menus []*Menu `jsonapi:"relation,menus"`
}

type Menu struct {
	ID           uint   `jsonapi:"primary,menus"`
	Name         string `jsonapi:"attr,name" valid:"required"`
	RestaurantID uint
	MenuItems    []*MenuItem `jsonapi:"relation,menuItems"`
}

type MenuItem struct {
	ID          uint    `jsonapi:"primary,menuItems"`
	MenuID      uint    `jsonapi:"attr,menuId"`
	Name        string  `jsonapi:"attr,name" valid:"required"`
	Ingredients string  `jsonapi:"attr,ingredients" valid:"required"`
	Price       float32 `jsonapi:"attr,price" valid:"required"`
}

I'm using gingko as my testing framework + the gomega matchers, which is pretty awesome, especially as I'm mainly a Ruby developer used to the Rspec goodies.
showUrl := fmt.Sprintf("%s/restaurants/%d", testServer.URL, restaurant.ID)
response, body, err := request.Get(showUrl).End()
Expect(err).To(BeNil())
expectedPayload := `
    {
        "data": {
            "type": "restaurants",
            "id": "1",
            "attributes": {
                "name": "Test"
            },
            "relationships": {
                "menus": {
                    "data": [
                        {
                            "type": "menus",
                            "id": "1"
                        }
                    ]
                }
            }
        },
        "included": [
            {
                "type": "menuItems",
                "id": "1",
                "attributes": {
                    "ingredients": "Tomato",
                    "menuId": 1,
                    "name": "Shopska salad",
                    "price": 15.5
                }
            },
            {
                "type": "menus",
                "id": "1",
                "attributes": {
                    "name": "Lunch"
                },
                "relationships": {
                    "menuItems": {
                        "data": [
                            {
                                "type": "menuItems",
                                "id": "1"
                            }
                        ]
                    }
                }
            }
        ]
    }
`
Expect(response.StatusCode).To(Equal(http.StatusOK))
Expect(body).To(MatchJSON(expectedPayload))

For every few test runs the menus and menuItems switch positions which breaks it.

Actually, I think I can unmarshal the response body and compare it to the record from the database 🤔

I got it working like this, i think it's good enough. I'm still open to suggestions though
showUrl := fmt.Sprintf("%s/restaurants/%d", testServer.URL, restaurant.ID)
response, _, _ := request.Get(showUrl).End()

restaurantFromResponse := new(repositories.Restaurant)
jsonapi.UnmarshalPayload(response.Body, restaurantFromResponse)

Expect(response.StatusCode).To(Equal(http.StatusOK))
_, restaurantFromDb := repositories.Restaurants.FindByID(restaurant.ID)
Expect(*restaurantFromResponse).To(BeEquivalentTo(restaurantFromDb))

What you have done will work - I'd recommend also catching the errors from request.Get and jsonapi.UnmarshalPayload and doing Expect(err).To(BeNil()).
This solution assumes that your test code has access to the structs with jsonapi annotation (ie repositories.Restaurant). If you did not have access to these structs I would recommend doing something along the lines of:
package main

import (
	"encoding/json"
	"reflect"
)

func JSONStringsEqual(s1, s2 string) (b bool, err error) {
	b = false
	var i1, i2 interface{}

	if err = json.Unmarshal([]byte(s1), &i1); err != nil {
		return
	}
	if err = json.Unmarshal([]byte(s2), &i2); err != nil {
		return
	}

	b = reflect.DeepEqual(i1, i2)
	return
}

Then from your test you would do:
Expect(JSONStringsEqual(body, expectedPayload)).To(Equal(true))


Don't key client config in DB on federation id

There should only be one.

@elsirion can you explain further with a bit of context

This was actually already fixed:
#[derive(Debug, Encodable, Decodable, Serialize)]
pub struct ClientConfigKey;

impl_db_record!(
    key = ClientConfigKey,
    value = ClientConfig,
    db_prefix = DbKeyPrefix::ClientConfig
);

#[derive(Debug, Encodable, Decodable, Serialize)]
pub struct ClientConfigKeyV0 {
    pub id: FederationId,
}


[Automation] Generate Fluent Lite from Swagger elasticsan#package-preview-2024-06

[Automation] Generate Fluent Lite from Swagger elasticsan#package-preview-2024-06

/azp run java - elasticsan - mgmt - tests

API change check
APIView has identified API level changes in this PR and created following API reviews.
com.azure.resourcemanager:azure-resourcemanager-elasticsan

/azp run java - elasticsan - mgmt - tests

/azp run java - elasticsan - mgmt - tests


MINOR: Collection/Option usage simplification via methods introduced in Java 9 or later

Relevant methods:

List.of, Set.of, Map.of and similar.
Optional: isEmpty, stream.

Committer Checklist (excluded from commit message)

[ ] Verify design and implementation
[ ] Verify test coverage and CI build status
[ ] Verify documentation (including upgrade notes)

Lots of test failures - will investigate them.

I removed the change to use the toList collector because it has two behavioral changes: the resulting collection is immutable and the ordering may be different. This should be ok in most cases, but it caused some test failures and perhaps a bit risky to do the change wholesale across the codebase.


[WIP] Fixed PHP required version

Finishes #260 and #263.
ping @stof @javiereguiluz @jzawadzki

To handle future Symfony versions, we could change this logic as follows:
Define an array with the exact Symfony version which changed the PHP requirement:
$requiredPhpVersions = [
    '3.0.0' => '5.3.3',
    '10.0.0' => '5.5.9',
];

This array is read like: "if your Symfony version is less than the array key, then you need the PHP version defined as the array value":

foreach ($requiredPhpVersions as $symfonyVersion => $phpVersion) {
    if (version_compare($installedSymfonyVersion, $symfonyVersion, '<')) {
        return $phpVersion;
    }
}

In the future, if we decide to require PHP 7.0.0 starting from Symfony 4.0.0, then we'd define this array:
$requiredPhpVersions = [
    '3.0.0' => '5.3.3',
    '4.0.0' => '5.5.9',
    '10.0.0' => '7.0.0',
];

Sounds good to me, even if the matching key/value is not accurate.

@HeahDude I agree ... it'll work, but it doesn't look right. Let's wait for more ideas.

Agreed. For the record I'm fine with handling a new constant for each major version of symfony, considering that a single major tag of this bundle should not be compatible with more than two major symfony versions at the same time.

@fabpot updated and rebased on 4.0 branch.

👍

Thank you @HeahDude.