New package: SimpleSim v0.1.0

Registering package: SimpleSim
Repository: https://github.com/janneshb/SimpleSim.jl
Created by: @janneshb
Version: v0.1.0
Commit: e473caf5b8509d4cd9055d74b6a00ad198191731
Reviewed by: @janneshb
Reference: https://github.com/janneshb/SimpleSim.jl/commit/e473caf5b8509d4cd9055d74b6a00ad198191731#commitcomment-146301165
Description: Work in Progress :-)
Release notes:

Initial Julia Registry registration!

Hi, congrats on the new package! Unfortunately the name seems a bit too generic. How about SimpleDynamicalSimulation.jl?

Hi, thanks :)
I quite like the alliteration in SimpleSim...
I don't think SimpleDynamicalSimulation is that much more specific. It's mainly longer and therefore less handy.
Also, the package aims mostly at dynamical system simulation similar to DynamicalSystems.jl, but, well, simpler.
But it also supports discrete-time dynamical systems and nested, modular simulations similar to Simulink.
So it is fairly generic. A super specific name wouldn't do justice to the different functionalities I believe.
The package that is currently blocking the merge isn't really an issue, I think, as it addresses a completely different field.
I'd be very happy if I didn't have to rename SimpleSim.jl! :)

I understand the yearning for short and nice-sounding names :) Unfortunately, everyone wants to shotgun those, so we just need to make sure that the packages who actually get them will end up being something of a reference in the field. I think SimpleSim.jl sounds like a one-stop shop for simulation in Julia, and that may be more ambitious than what anyone can achieve alone.
Note that longer package names are rarely a problem, you can always do import LongPackageName as LPN if you want. And including the full word "Simulation" in your package name would probably help people find it by search.

okay, so what's the verdict here?
Is this name acceptable? I'm not trying to claim Simulation.jl or something similar here and feel like this package is big enough to deserve a catchy name.
But if there's somewhat of a unanimous opinion I will try to come up with a new one.

Nevermind, just realized that this will be merged automatically in three days.
Thank you both, have a nice evening :)

No it won't be merged automatically since my comments (and yours) are blocking it for the moment.
Note that I don't have any special authority here: I'm just one of a few people who watch the package registration feed and react to some packages whose names I disagree with. I'd love a second opinion here, for instance from @goerz. If other community members say this is fine, I'll make my comments non-blocking and allow registration to proceed.

Ah okay, yeah maybe let's see what @goerz says.
I'm also not attached to the current name at all cost, but I already got used to it and would really like to keep it.
Also, GitHub is sometimes confusing. How are my comments blocking the merge when I don't have any approval authority on this repo?

Ah, this is a repo specific thing.
Thanks a lot :+1:

The name SimpleSim seems okay to me, personally. That being said, @gdalle isn't wrong that it could be a bit more specific. For sure, Sim is a perfectly fine abbreviation for Simulation in any package name. Adding some form of "dynamics" to the name might make it a more specific. But I also agree with @janneshb: "simulation" pretty much implies "dynamics", so it's not that much more specific. Still, you could go with SimpleDynamicsSim or maybe even SimpleDynSim.
I don't have a special authority on these questions, either. As a "triage member" I have only slightly elevated permissions to override some automatic checks (like the name similarity check in this case). My recommendation would be for @janneshb to sleep a night or two over whether there is something that can be added to Simple and Sim to make the name significantly more descriptive. If after some reflection, they decide that they want to stick to SimpleSim, I would let it pass. But in that case, it would be up to @gdalle to unblock their comments. If no consensus can be reached, a full registry maintainer (not me) would have to decide whether to merge manually over any community rejections.
[noblock]

Thanks for your comment, @goerz
I will think about possible name alternatives for a day or two. If anything, it has to be something else almost entirely as just  adding a Dyn makes things more complicated without taking away much of the "genericism" of the name, as you said as well.
[noblock]

I think SimpleSim.jl sounds like a one-stop shop for simulation in Julia, and that may be more ambitious than what anyone can achieve alone.

That is generally a more serious concern than "descriptiveness" alone. For "nice" package names, I would also encourage them to be somewhat reserved for well-maintained projects (i.e., with backing from someone with a permanent position). But other than that, package names are first-come-first-serve. I'm not entirely decided on whether SimpleSim is a sufficiently "nice" package name to warrant special attention. If @janneshb can already foresee that this will most likely end up abandoned after they graduate from their Master's program later this year, I would urge a longer name. If there's a prospect of the project being carried further by someone at ETH or Imperial, it should be okay.

Right now, this is not an official project from neither ETH or Imperial and there is no one else working on it. But I am in the process of convincing people to ditch their proprietary software, so other people might contribute to SimpleSim.jl in the future.
Either way, after graduating (you really did your homework) I will continue using Julia in either some job or further post graduate studies. I put quite a lot of work into this project and will (most likely) continue using it in personal or professional projects.
But of course I can't promise anything.
[noblock]

Okay, I've brainstormed some name alternatives and consulted the usual LLMs for tips.
But nothing sounds quite as nice as SimpleSim.jl, especially because of the "SiSi" alliteration.
Since I want the name to be catchy and not just descriptive any name alternative would still be "nice" and thereby taking away from possible future projects that want to claim that name.
I think there are a lot of possible plays on words left for future use and SimpleSim is also not incredibly generic (compared to ControlSystems.jl etc).
So, if there are not major objections by anyone else, I'd be happy if this merge could move forward :)
Thank you all
Jannes
[noblock]

[noblock] I’m okay with it

i'm okay with it too, made all my comments nonblocking
[noblock]

thanks guys!
I think this was a super productive discussion and people like you are what keeps projects like Julia alive :-)
[noblock]


[SPARK-40830][SQL] Provide groupByKey shurtcuts for groupBy.as

What changes were proposed in this pull request?
This documents that groupBy(...).as[...] should be preferred over groupByKey(...).
It further provides shortcuts for groupBy(...).as[...] that make it easier to use column-based groupByKey.
Why are the changes needed?
Calling Dataset.groupBy(...).as[K, T] should be preferred over calling Dataset.groupByKey(...) whenever possible. The former allows Catalyst to exploit existing partitioning and ordering of the Dataset, while the latter hides from Catalyst which columns are used to create the keys.
When the dataset is already partitioned and ordered by the grouping columns, Dataset.groupByKey(...) will repartition and order the entire dataset again.
Example:
Calling ds.groupByKey(_.id) hides from Catalyst that column id is the grouping key, while ds.groupBy($"id").as[Int, V] tells Catalyst that ds is to be grouped by (partitioned and ordered by) column id.
The new column-based groupByKey methods make it easier for users to find a way to express the grouping by expressions. Looking at the Dataset API, the user finds groupByKey with Column. The existing groupBy method returns a RelationalGroupedDataset, which provides the as[K, V] method, which allows for the same semantics, but is difficult to find.
The new column-based groupByKey methods further do not require the user to specify the type V of the original Dataset[V], as groupByKey has access to the type / encoder:
ds.groupBy($"id").as[Int, V]

vs.
ds.groupByKey[Int]($"id")

Does this PR introduce any user-facing change?
Note: This breaks compilation when function name is used with existing groupByKey:
Was:
groupByKey(identity)

Now:
groupByKey(identity(_))

It adds these methods:
Scala:

Dataset.groupByKey[K](Column*)
Dataset.groupByKey[K](String, String*)

Java:

Dataset.groupByKey[K](Encoder[K], Column...)
Dataset.groupByKey[K](Encoder[K], String, String...)

How was this patch tested?
Adds tests to DatasetSuite and JavaDatasetSuite.

Can one of the admins verify this patch?


Inform 6 version

I got carried away and made an Inform 6 version which should be compatible (once compiled to bytecode) with 8 & 16 bit Infocom interpreters.

Wow, this is great, now we can try to compile it for the Z-machine and run it on an 8-bit platform.
Shouldn't we rename the objects from ["a key", "a lamp"] simply to ["key", "lamp"] on this implementation? The inventory shows "an a key" and "an a lamp"

I love the idea of it running on the sort of systems I first used. It's making me want to brush off some of my old adventure ideas.
I'll make those changes & share another version with the next pull request.


Set a capability to allow binding to low ports

Description
The cap_net_bind_service capability allows a process to bind to a low
port without root. While Kubernetes lets you allow a capability in the
pod spec, the effective capabilities are wiped when the root -> user
transition is made.
This change setcap's the binary so that it can assert that capability. e.g.
 securityContext:                                                                                |~
   capabilities:                                                                                |~
     add:                                                                                |~
       - NET_BIND_SERVICE

(there is no CAP_ at the beginning; K8s seems to add that)
If you don't want to bind to a low port, don't add the capability and
we're back to the previous behavior. If you want to bind to a low port,
add the capability and configure Ambassador appropriately.
Related Issues
This is a feature addition -- I want to be able to run this as a non root user but still bind to a low port.
Testing
Manual testing.
Todos

[ ] Tests
[ ] Documentation

I am not sure what kind of tests are appropriate. If this PR is accepted I can update the documentation repo, too.

Well, for testing, the simple route would be to modify an existing KAT test to add the capability and then use it.
Is there any downside to adding this capability, that you can think of?

Hi @kflynn, no I can't see a downside. This capability is so specific (bind to a low port) and can only be used if the admin grants it.

@swalberg Thanks, that sounds sane to me. How's your bandwidth looking for a test modification? :smile:

On my todo list for this week ;)

@swalberg Excellent! :smile: Yell if (when ;) ) you have questions.

Just an update, I spent some time getting up to speed on those tests, should be able to figure the rest out next week.

Can you have a peek at my second commit, please? I wrote what I think is a test but it's not failing when I think it should. Do I need to call it somewhere?

Hmmm. I can tell you that the Empty test can't be duplicated in your t_capabilities.py file, but the rest looks like it should definitely fail. What happens when you do
make clobber docker-push test TEST_NAME=LowPort

??

Won't bore you with the details, but that command helped me find a bunch of Python errors in my test. The test is running now, thanks!

Cool! More commits coming, then? :smile:

Either commits or more questions ;)

Either is a win. :smile:

I haven't forgotten about this... My current challenge seems to be that there's a hard coded NodePort to forward port 80 to the pod's 8080 in the AMBASSADOR kat manifest. That's fine, I can add an 82->80 mapping, but I don't see how the port gets set up in the pod. And when I run the test with make DOCKER_REGISTRY=localhost:5000 USE_KUBERNAUT=false KUBECONFIG=~/.kube/config TEST_NAME=LowPort clobber docker-push test it first tries to connect to the service on port 80 which is hard coded to 8080, but I've already told the pod to listen on 80.
Checking 4 url requirements... 2 not ready (http://lowporttest/ambassador/v0/check_ready: Get http://lowporttest/ambassador/v0/check_ready: net/http: request canceled (Client.Timeout exceeded while awaiting headers)) sleeping 10s...

Checking 4 url requirements... 2 not ready (http://lowporttest/ambassador/v0/check_ready: Get http://lowporttest/ambassador/v0/check_ready: read tcp <IP_ADDRESS>:64525-><IP_ADDRESS>:80: read: connection reset by peer) sleeping 10s...

Checking 4 url requirements... 2 not ready (http://lowporttest/ambassador/v0/check_ready: Get http://lowporttest/ambassador/v0/check_ready: read tcp <IP_ADDRESS>:64535-><IP_ADDRESS>:80: read: connection reset by peer) sleeping 10s...

NAME                TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)                                   AGE
kubernetes          ClusterIP   <IP_ADDRESS>        <none>        443/TCP                                   15d
lowporttest         NodePort    <IP_ADDRESS>   <none>        80:30624/TCP,443:31265/TCP,82:30693/TCP   8d
lowporttest-admin   NodePort    <IP_ADDRESS>    <none>        8877:31512/TCP                            8d
lowporttest-http    ClusterIP   <IP_ADDRESS>   <none>        80/TCP,443/TCP                            8d```

Thoughts?

So I think what you want to do is:

change manifests.AMBASSADOR so that

the targetPort in the Service definitions reflects your low port
the Pod definition has your capability

change your Ambassador module to bind on the low port you want

and I think that'll do it. Ambassador will bind on the low port, but Kubernetes will do port-mapping magic so that none of the tests need to change otherwise.

(Sorry for giving you a merge conflict! but you'll want to merge master into your branch anyway to get the shiny new CI goodness.)

When I run your latest, the test fails with
ambassador-listener-81: cannot bind '<IP_ADDRESS>:81': Permission denied

🙁
It looks like the manifest is correct though:
---
apiVersion: v1
kind: Pod
metadata:
  name: lowporttest
  annotations:
    sidecar.istio.io/inject: "false"
  labels:
    service: lowporttest
    kat-ambassador-id: lowporttest
    scope: AmbassadorTest
  namespace: default
spec:
  securityContext:
    runAsUser: 8888
  serviceAccountName: lowporttest
  restartPolicy: Always
  volumes:
  - name: scratchpad
    emptyDir:
      medium: Memory
      sizeLimit: "45Mi"
  containers:
  - name: ambassador
    image: dwflynn/ambassador:swalberg-capabilities-25530155-dirty
    ports:
    - containerPort: 81
    env:
    - name: AMBASSADOR_NAMESPACE
      valueFrom:
        fieldRef:
          fieldPath: metadata.namespace
    - name: AMBASSADOR_ID
      value: lowporttest
    - name: AMBASSADOR_SNAPSHOT_COUNT
      value: "0"
    - name: AMBASSADOR_CONFIG_BASE_DIR
      value: "/tmp/ambassador"
    securityContext:
      allowPrivilegeEscalation: false
      readOnlyRootFilesystem: true
      capabilities:
        add: ["NET_BIND_SERVICE"]
    livenessProbe:
      httpGet:
        path: /ambassador/v0/check_alive
        port: 8877
      initialDelaySeconds: 30
      periodSeconds: 10
      failureThreshold: 30
    readinessProbe:
      httpGet:
        path: /ambassador/v0/check_ready
        port: 8877
      initialDelaySeconds: 30
      periodSeconds: 10
      failureThreshold: 30
    volumeMounts:
    - mountPath: /tmp/
      name: scratchpad

Yea, getting the same here. Trying to get it to run outside of the test again.

bash-4.4$ getcap /usr/local/bin/envoy
/usr/local/bin/envoy = cap_net_bind_service+ep
bash-4.4$ grep Cap /proc/156/status
CapInh:	00000000a80425fb
CapPrm:<PHONE_NUMBER>000000
CapEff:<PHONE_NUMBER>000000
CapBnd:	00000000a80425fb
CapAmb:<PHONE_NUMBER>000000
bash-4.4$ capsh --decode=00000000a80425fb
0x00000000a80425fb=cap_chown,cap_dac_override,cap_fowner,cap_fsetid,cap_kill,cap_setgid,cap_setuid,cap_setpcap,cap_net_bind_service,cap_net_raw,cap_sys_chroot,cap_mknod,cap_audit_write,cap_setfcap

ok it has cap_net_bind.
Ah, it's that allowPrivilegeEscalation: false that prevents the binary to use capabilities. I looked in our k8s environments and I don't see it there. If I set it to true I can bind to 81.

I don't have a problem with a mod to allowPrivilegeEscalation for the LowPort test...

I can't believe it, passing tests (at least locally)! Thanks!
(the test is that a call to http://localhost:80/ returns a 404 from Envoy, I figure the purpose of this test is to make sure Envoy is listening so that should be enough)

BTW, assuming this all passes, I'm happy to squash and write a decent commit message if that's what you'd prefer in the history.

Thanks! I was going to ask you to add docs, but realized that our current docs on running are.. uh... wrong. 😐 😆

Can you point me to the docs you're talking about? Maybe I can make them less wrong.

That would be wonderful! Look at docs/reference/running.md --

Since Ambassador 0.60, the default ports have been 8080 and 8443 -- basically we've defaulted to assuming that you're running non-root without privilege escalation since 0.60, and our default published YAML (in docs/yaml/ambassador) includes a securityContext to run as user 8888.

It would probably be worth a note that if you're running as non-root, you will most likely be required to change AMBASSADOR_CONFIG_BASE_DIR as non-root may not be able to write in /ambassador (this goes double if you have a read-only root filesystem)

Obviously there should be some discussion of using the capability to bind to a low port without being root. :wink:

I would normally say to make the doc change as a PR against the datawire/ambassador-docs repo, but in this case the capability thing is a feature that has yet to ship, so the datawire/ambassador repo is correct.

Many thanks!!


Regex docs

Addresses issue #1268 on adding information on regex functionality to Topic Guide

No worries @RossKen, and thank you!


macOS/clang support

Hey there,
thanks for this nice lib.
I am trying to compile it on macOS with its shipped clang. Unfortunately, this is not working, since some c++20 features are missing within clang and libc++: std::ranges::for_each, std::ranges::copy_if, std::stop_token.
https://en.cppreference.com/w/cpp/compiler_support/20#C.2B.2B14_library_features
My question is, will you consider compatibility with macOS and clang?
If yes, are there any plans on this in the near future?
Or would you accept PRs fixing macOS/clang compilation?
Thanks a lot!

Hey!
Yeah, I know about this problem. To be honest, I don't have such a plans, because...
While std::ranges is pretty easy to fix, I'm really not sure about std::stop_token - some internal logic relies on this heavily. If you can provide some good idea how to adapt it for Apple Clang - you are welcome =) One more thing: concepts - RPP uses them everywhere but Apple Clang has "partial" support for it...

Or would you accept PRs fixing macOS/clang compilation?

Yeah, I'm fully open to any PRs if it would not be too overcomplicated.

Hey there,
thanks for your feedback.
Although, i am pretty experienced with C++ in general, i would rate my knowledge in newer aspects (C++17 and later) somewhat lower. When I will find an easy way to adapt, i will keep you posted.
However, i believe, that clang and/or apple will adapt to C++20 in the near future.
So, any effort from me (and you) might be pointless, that's why i completely understand your decition.
I will continue using rxcpp for now, but i am pretty open to switch over to your lib as soon as it is usable on macOS.
Anyway, awesome effort from your side and keep going. I will have an eye on this :)

Hi @mincequi ,
Yeah, I see. But I’m not sure about your hopes related to Apple/Clang. I can suggest you using gcc or clang (not Apple) instead of Apple Clang if it is applicable in your case

Hi @victimsnino ,
according to the link which i posted above, this is not related to Apple's clang, but the general clang/libc++ combination.
I also tried the stock clang v15, however with no success.
Unfortunately, GCC is not an option, because it is very painful to use on macOS and Homebrew. :(

Sounds strange, because I have ubuntu + clang combination in CI and it works fine
-- The CXX compiler identification is Clang 11.0.0
Are you sure that your clang was stock clang not Apple Clang? I mean, for example, by default if you are trying to use "gcc" on mac, it is just kind of symlink to Apple Clang. For example:
➜  ~ which gcc
/usr/bin/gcc
➜  ~ gcc --version
Apple clang version 14.0.0 (clang-14<IP_ADDRESS>)
Target: x86_64-apple-darwin21.6.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin

In this case to call "real installed gcc" I need to use more specific binary:
➜  ~ gcc-12 --version
gcc-12 (Homebrew GCC 12.2.0) 12.2.0
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

I believe, there can be something similar for clang

Double-checked with "not apple" clang - same errors like for Apple Clang... Strange that ubuntu clang works fine -_-

Ok, maybe this narrows down to libstdc++ vs libc++

Ohhhh, I see, it makes sense =) Looks like I'm not so experienced Mac user =)
Ok, then I would check what I can to do with that

Hi @mincequi ,
I've merged PR to enable macos. Looks like CI passed on MacOS. Could you check if it helps you too?

Hi @victimsnino ,
thanks a lot for your effort. I will try it within the next couple of days.
I have another question, which i came across when working with rxcpp. Is there any kind of combiner, that accepts a dynamically changing list of observables?
e.g. (pseudo code)
list<observable> observables
observable combinedObservable = combine(observables)

The list might also change during runtime.

Not sure if I get your goal. I see two possible solutions but it is about totally different use cases.  Could you provide some more context and example for such a usecase?

Ok, i solved it already. Thanks.
I also did not want to get too off-topic here.
I will come back to you with feedback about my ReactivePlusPlus integration.

@victimsnino compilation and usage is confirmed from my side. I will switch over to ReactivePlusPlus again.
Great stuff, thanks a lot!

@mincequi , cool! Thank you for feedback! Don’t shy to provide any feedback or feature requests :-)

@victimsnino
Thanks for your support. Here we go, with my previously asked question on how to combine an arbitrary number of observables. I made usage of rxcpp's subjects::behaviour in the following way:
class Manager {
public:
    void setValue(const std::string& id, int value) {
        if (!_subjects.count(id)) {
            _subjects.insert( {id, rxcpp::subjects::behavior<int32_t>(0)} );
            _subjects.at(id).get_observable()
                    .timeout(10s, rxcpp::observe_on_event_loop())
                    .subscribe([this](const int32_t&) {
                int sum = 0;
                for (const auto& kv : _subjects) {
                    sum += kv.second.get_value();
                }
                sumValue.get_subscriber().on_next(sum);
            }, [this, id](std::exception_ptr ep) {
                _subjects.erase(id);
            });
        }
        _subjects.at(id).get_subscriber().on_next(value);
    }

    rxcpp::subjects::behavior<int32_t> sumValue;

private:
    std::map<std::string, rxcpp::subjects::behavior<int32_t>> _subjects;
};

This might be done better. However, my current "naive" implementation cannot be done with rpp, due to the lack of behavior subjects. What would you suggest? Thanks a lot!

@mincequi,
If i get it correct, are you trying to keep sum of "last" values by different keys? And do you need to keep map of subjects? If you don't need to keep map of subjects, then you can do something like this:
    rpp::subjects::publish_subject<std::pair<std::string, int>> keyValueSubject{};
    rpp::subjects::publish_subject<int32_t>                     sumValueSubject{};

    keyValueSubject.get_observable().scan(std::map<std::string, int>{},
                                          [](std::map<std::string, int>&& seed, std::pair<std::string, int> newPair)
                                          {
                                              seed[newPair.first] = newPair.second;
                                              return std::move(seed);
                                          })
                   .map([](const std::map<std::string, int>& keyValue)
                   {
                       return std::accumulate(keyValue.cbegin(),
                                              keyValue.cend(),
                                              0,
                                              [](int val, const auto& pair) { return val + pair.second; });
                   })
                   .subscribe(sumValueSubject.get_subscriber());

    sumValueSubject.get_observable().subscribe([](int32_t sum) { std::cout << "sum is " << sum << std::endl; });

    keyValueSubject.get_subscriber().on_next({"first", 1});
    keyValueSubject.get_subscriber().on_next({"second", 2});
    keyValueSubject.get_subscriber().on_next({"first", 3});

    // sum is 1
    // sum is 3
    // sum is 5

Only one difference from "behavior" in this case: it would not send "last" value on subscribe immediately.
Anyway i've added it for me #300

@victimsnino
Yes, this looks nice and emitting "last" value on subscribe is not needed.
But yes, i somehow need that timeout and the specific source shall be removed from accumulation.

@victimsnino
Sorry for my late replies. I am quite busy atm.
But yes, this exactly does the trick for me. Thanks a lot!
Once i have a useable state, i will let you know about my project.

...ok, as you might have guessed, i am missing another operator ;)
This time, i would like to request the time-based debounce operator.
Do you believe, this could be easily added?

Yeah, sure, no problem =) Currently I'm implementing operators mostly by user's requests (to be sure that someone using it :-) )
To be sure that we have same understanding:
you need operator which emits emission if no any other emissions since emission during X interval? Like this:

Reason why I am asking: people often confused between debounce/throttle and sample =)

@victimsnino
Yes, I definitely need the debounce operator. throttle is not the thing I need.

@mincequi, debounce implemented =)

Tested and working :)

I'm closing this issue due to original issue resolved.
If you have any other issues/feature requests and etc, then create new one for them =)


Doc.noun_chunks documented but DNE

See http://spacy.io/docs/#api . In v0.89, the Doc class is documented to have a noun_chunks generator that returns base noun-phrase Span objects. This functionality appears to be unimplemented as tested empirically.
>>> doc = nlp(u'The sentence in this example has three noun chunks.')
>>> doc.noun_chunks
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: 'spacy.tokens.doc.Doc' object has no attribute 'noun_chunks'

I also tried code inspection: a grep on this repo for the phrase noun_chunks turns up zero hits.

Ah, thanks.
This is in a branch, and should have been labelled "Coming soon" in the docs. I'll fix the docs. I expect the next release to finish testing quite soon.

spaCy v0.90 now pushed to PyPi, and features this method.


I wanted to add a search bar in the webpage

Idea Contribution

[X] I have read all the feature request issues.
[X] I'm interested in working on this issue
[X] I'm part of GSSOC organization

Explain feature request
I wanted to add a search bar as whenever a user comes up to the webpage it is required by him to search the topics he wants to know about rather than opening each and every topic and searching about it.

Explain your solution
So i wanted to create a search bar which will help user to search his wanted topic.
Any alternative approaches/features
No response
Additional Context
No response

Currently the website is still in development (redesigning). Read this #998


taprpc: add missing cli autogen docs

Adds some missing tags in the proto files that prevented parts of our API docs page from showing CLI commands when one exists.
Right now this page, https://lightning.engineering/api-docs/api/taproot-assets/taproot-assets/fetch-asset-meta , shows no Shell example even though the command exists.
Also fixes some help comments.
I don't think we can easily add a lint for these comments since some RPC endpoints intentionally don't have a matching CLI cmd, like the PSBT endpoints.

We should really fix that race unit test flake... @Roasbeef can you override merge (without queue) please?


⚠ Mobitopup has degraded performance

In 355318d, Mobitopup (https://napcard.voz.tech) experienced degraded performance:

HTTP code: 200
Response time: 3467 ms

Resolved: Mobitopup performance has improved in 0c397df after 417 days, 2 minutes.


enroll face mqtt

it would be great to enroll faces and then after a face detection publish as face1, face2 etc

I would love to see this too. But I guess that would require lot's of work to implement.

The face detection works on the device and detects faces but not individual faces.  That kind of processing would require cloud processing which means uploading your face to Google cloud for their machine learning library for example.   Not sure if other solutions that would be less complex or so not require training.

I am a supporter of minimally giving any data "out" from my smart home. If the function of recognition of specific faces be implemented, I believe that it will be correct if it is optional and disabled by default.

Yeah, this isn't going to happen because you would also need your own Firebase account to use this feature, it is not a feature you would implement or want to implement for all users.


Implement a method to sign-in silently

Purpose

$subject

If the IDP is in a 3rd party domain then with upcoming third party cookie changes to browsers this will not work. For example if the Identity Server is in a different domain than the application then the commonAuthId cookie will not be sent in the prompt none call, so even if there is a actual session the server will see that there is no session and a error response will be sent back.
3rd party cookie blocking is already in place in Safari, so if u test this flow in safari you can see how it is impacted.
If going forward with this, let's properly document the limitations.

If the IDP is in a 3rd party domain then with upcoming third party cookie changes to browsers this will not work. For example if the Identity Server is in a different domain than the application then the commonAuthId cookie will not be sent in the prompt none call, so even if there is a actual session the server will see that there is no session and a error response will be sent back.
3rd party cookie blocking is already in place in Safari, so if u test this flow in safari you can see how it is impacted.
If going forward with this, let's properly document the limitations.

A warning message has been added to the README file.


x/build: add new ppc64 power10 builder

OSUOL has made available a VM running debian unstable in addition to the existing power10 ppc64le VM image.
This is helpful to verify power10 specific code in BE mode.

It would be nice if support for the ppc64 and ppc64le versions of FreeBSD could be added.
I want to use the github-act-runner for kernel module testing for OpenZFS.
When I should test compile some things - I can do this.

Hi, I think this is complete now.

Should I open a new issue for building FreeBSD ppc64 and ppc64le ?

@mcmilk, yes. This issue related to setting up a specific CI instance.
Supporting Go on FreeBSD/ppc64{le,} would first require creating proposal type issue. That's a bit more work.

@pmur  - I just found this: https://github.com/golang/go/issues/56001 - so I will ask there, if FreeBSD may also be added like OpenBSD


New renderer

WIP

bevy_ecs_tilemap definitely won't work with wasm as-is. I'll try to throw a PR over in that direction today.


🐞 - TuiInputFilesDirective always provide capture attribute

Playground Link

Description
I have a problem with file input like this.
<tui-input-files>
  <input tuiInputFiles accept="image/*" />
</tui-input-files>

On mobile devices it always opening the camera instead of file dialog.
This is because TuiInputFilesDirective always add the capture attribute.
Problem 1
fileInput.capture cannot be a null (on mobile browser). Even if there is no attribute, there is an empty string in capture.

So, result of expression input.capture ?? this.options.capture always is ''.
Problem 2
@HostBinding cannot remove attribute, even if associated getter returns null | undefined. In this case, @HostBinding transforms result to string and set it's to the attribute. For example: if getter capture returns null, input element has an attribute capture="null".
Profs:

According documentation if capture attribute is present (even if empty), then the camera will be opened instead the file dialog.
Angular version
15.2.7
Taiga UI version
3.24.0
Which browsers have you used?

[X] Chrome
[ ] Firefox
[ ] Safari
[ ] Edge

Which operating systems have you used?

[ ] macOS
[X] Windows
[ ] Linux
[ ] iOS
[ ] Android

Addition to Problem 2
The problem is not with HostBinding. The problem is that on mobile devices property capture is always a string.
input.capture = null;
console.log(input.capture); // 'null'

So, if we change HostBinding('capture') to HostBinding('attr.capture', then all works.


request for 3.0.2 package to reflect dependency updates

Just want to kindly ask if it will be possible to release an npm/yarn package, that reflects the changes of the current github/package.json
It would be great, not having to run npm audit fix --force for each project using grunt with load-grunt-config :-)
Thanx
# npm audit report

lodash  <=4.17.20
Severity: high
Prototype Pollution - https://npmjs.com/advisories/1523
Command Injection - https://npmjs.com/advisories/1673
fix available via `npm audit fix --force`
Will install<EMAIL_ADDRESS>which is a breaking change
node_modules/load-grunt-config/node_modules/lodash
  load-grunt-config  0.17.1 - 0.19.2 || >=2.0.0-rc1
  Depends on vulnerable versions of lodash
  node_modules/load-grunt-config

2 vulnerabilities (1 low, 1 high)

@db-developer done.

Thank you very, very much. Really cool!
[...] added 605 packages, and audited 606 packages in 51s

48 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities


Is this a clumsy setup?

Hey,
So, node, angular, couchdb is not really my cup of tea (not linux either...), but here's what I did:

At Cast dev console I created application id and registered my chrome cast devices.
Started a virtual Ubuntu Unicorn.
Copied gscreen content to ~/gscreen, cd gscreen
sudo apt-get install npm
sudo apt-get install nodejs-legacy
sudo apt-get install couchdb -y
sudo npm install (in the gscreen folder)
sudo npm run create-config
sudo nano public/js/gscreen-config.js
Add my chromecastApplicationId
sudo nano /etc/couchdb/default.ini (set to 5985 because couchdb has 5984 in use already)
sudo nano config.json (set to 5984).
sudo couchdb &
ctrl-c
sudo npm start
Ready for testing the gscreen app!

I'm not really happy about step 10-14, not sure how to do this properly (I want couchdb and npm to run as a service/in the background somehow).
It works, but figuring out how the cromecasts, the cast console, the sender and the receiver are working together was a pain...
Anyone knows how to make this setup a more production like setup?
/T

I have dockerized greenscreen and couchdb in my fork of greenscreen which makes setting up easy. If the project maintainers are open to the idea might as well submit a PR here for review.
For time being check this out: https://github.com/shreyu86/greenscreen

Sweet! I think...? :)
How does this affect the setup procedure? Could you add some setup
instructions for those not familiar with this docker thing, thx!
Den 23 sep 2015 18:29 skrev "Shreyas Karnik"<EMAIL_ADDRESS>
I have dockerized greenscreen and couchdb in my fork of greenscreen which
makes setting up easy. If the project maintainers are open to the idea
might as well submit a PR here for review.
For time being check this out: https://github.com/shreyu86/greenscreen
—
Reply to this email directly or view it on GitHub
https://github.com/groupon/greenscreen/issues/44#issuecomment-142654718.

@tobefound I will write a tutorial for setting up greenscreen with docker.

Can't wait!! Thx!
Den 23 sep 2015 20:20 skrev "Shreyas Karnik"<EMAIL_ADDRESS>
@tobefound https://github.com/tobefound I will write a tutorial for
setting up greenscreen with docker.
—
Reply to this email directly or view it on GitHub
https://github.com/groupon/greenscreen/issues/44#issuecomment-142686692.

As I said, my setup works but only for a limited time... then something shuts everything down and I have to set the configuration to a different couchdb port.
I want to try out the docker thing or if there's another way to secure a stable running environment.

@tobefound We use greenscreen in docker with hosted couchdb at https://cloudant.com/. It's for free as long as your usage of couchdb is less than $50, which we never reached.
https://github.com/tomologic/docker-greenscreen

Has anybody tried setting it up on c9.io?


data: project addition by Yash Kumar Shrivas

Add a new project to the list
I'm in GSSOC'23
I want to add a new project to the list which is Weather Website link-https://yashkshrivas4491.github.io/WeatherWebApp/

This project is about building a web application to show a weather forecast using weather API from external services Open weather map.
Here you will be able to search for a specific location in the world and also it will automatically detect your current location in the beginning (for that you need to allow location) and will display all the important weather details.

Features
Easily Fetch data from API.
Zero dependencies.
Background image changes according to the country's input.
It show humidity , wind , temperature.
if you enter wrong country's name than it show no data available.
Code of Conduct

[X] I agree to follow this project's Code of Conduct

assigned to @YashkShrivas4491

Completed. Thanks for your contributions 🎉 ❤


Multiple runs, adding new components, creates a broken Schematics file.

1.0.16
How / what
The merge doesn't work correctly when first running JLC2KiCadLib with a set of components, then adding components anywhere in in the list of parameters.
Result
At the end of the file, there's a end-paren ), but instead of removing it, then adding the new symbol, you get lines looking like this:
) (symbol ...

instead of
(symbol ...
)

As a result, KiCad doesn't pick up the added symbols, since they're outside of the (kicad_symbol_lib ...) s-exp.
Removing the ) and placing it at the end makes the lib work, w/ KiCad finding the newly added symbol.

Hi, I could not reproduce the issue.
Can you  please give me the arguments you used ?


[timeseries] Ensure that TimeSeriesDataFrame index is sorted before train_test_split

Issue #, if available: Fixes #4257
Description of changes:

Make sure that the TimeSeriesDataFrame index is sorted before generating the train/test split.

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

Previous CI Run
Current CI Run


Is this electron-only? Is plain browser supported?

As far as I know the main usecase is kubectl, and kubernetes is server software. Isn't browser supported at all? If so, why?

hello, thanks for the question! indeed kui can be deployed to a hosted environment. you can develop in this mode by using npm run watch:webpack at the top-level. in this mode, the browser client can talk to a proxy (see packages/proxy) which in turn executes the native binaries such as kubectl or oc or helm.
there are also scripts that will build production webpack bundles that target a hosted environment. we are refining the docs here. i'll ping you when they are ready.
we are considering coding up an Operator that will manage this hosted environment.

hello! we now have a documentation page covering builds for a hosted application: https://github.com/IBM/kui/wiki/Building-for-Production#scripts-to-aid-in-building-a-hosted-kui


status_date in item_ext table stored as text instead of date

The folio_derived.item_ext table in metadB is storing status_date as long text rather than as date/time.  This causes issues with existing queries (as it is a change from Orchid).  Can it be instead stored in the appropriate date format?

As long as we are updating this table, it would also be good to have effective_shelving_order field from the folio_inventory.item__t table in Metadb added (from Joanne Leary)


Waveshare 2" 320x240 compatibility?

Hi,
I recently saw this waveshare 2" IPS screen https://www.waveshare.com/2inch-lcd-module.htm
It looks very similar to the adafruit 2" IPS screen https://www.adafruit.com/product/4311
except that the waveshare module doesn't have the sdcard slot.
Both have the same controller too: ST7789
Will the driver be compatible with the waveshare display?
My plan is to use it with a rpi-zero-2 W
Thanks

I am not aware of anyone having tried that display with the driver. There are several other ST7789-based displays that have been used though with a ST7789 driver backend, so it is possible that it can work.

Hi,
I just bought the Waveshare 2inch LCD Display.
On their wiki page about this display they offer a modified version of the fbcp-ili9341 library with predefined header files for the 2inch-waveshare display:
sudo apt-get install cmake -y
cd ~
wget https://www.waveshare.com/w/upload/8/8d/Waveshare_fbcp-main.7z
sudo apt-get install p7zip-full
7z x Waveshare_fbcp-main.7z
cd waveshare_fbcp-main
mkdir build
cd build
cmake cmake -DSPI_BUS_CLOCK_DIVISOR=20 -DWAVESHARE_2INCH_LCD=ON -DBACKLIGHT_CONTROL=ON -DSTATISTICS=0 ..
make -j
sudo ./fbcp

It works on my Raspberry 3 with Raspberry Pi Desktop Bullseye. For me it was neccessary to disable the new graphic engine dtoverlay=vc4-kms-v3d in /boot/config.txt (see #75) and change the DMA Ports as described here https://github.com/juj/fbcp-ili9341/issues/184#issuecomment-759343283

@juj as one can see on the photo, the image on the display has some offset (starts in the middle and has overflow to the right). Any idea why that happens or how to fix this?
I allready tryed arround with offset values, but with no success...
https://github.com/juj/fbcp-ili9341/blob/4aa3b97f4d295e3301651bd3dc3d314b25f2531e/gpu.cpp#L434

Hi guys, after hours of trial and error I have now managed to get the waveshare 2inch LCD display to run correctly on the Raspberry 3B with Raspberry OS Bullseye. In the end, I used the standard fbcp-ili9341 (not the modified version of waveshare). However, some modifications were necessary:
install fbcp
sudo apt-get install cmake
cd ~
git clone https://github.com/juj/fbcp-ili9341.git
cd fbcp-ili9341

vc4-kms-v3d
For me it was necessary to disable the new graphics engine dtoverlay=vc4-kms-v3d in /boot/config.txt (see #100)
config.h
Customize config.h
#define GPIO_TFT_DATA_CONTROL 25
#define GPIO_TFT_BACKLIGHT 24
#define GPIO_TFT_RESET_PIN 27
#define DISPLAY_NATIVE_WIDTH 240
#define DISPLAY_NATIVE_HEIGHT 320

#define DMA_TX_CHANNEL 7 //Change the DMA ports to some free ports
#define DMA_RX_CHANNEL 5
#define STATISTICS=0 //Disable statistics overlay (optional)

st7735r.h
In st7735r.h I had to comment out line 19-20 to read the display size from config.h:
#if defined(ST7789) || defined(ST7789VW)
//#define DISPLAY_NATIVE_WIDTH 240
//#define DISPLAY_NATIVE_HEIGHT 240

st7735r.c
In st7735r.c I had to comment out line 95 to remove the offset at the top:
#ifdef ST7789
    // The ST7789 controller is actually a unit with a graphics memory area of 320x240, but only a part of 240x240
    // of it is displayed. So if we wanted to swap the above line address mode, writes in the Y=0...239 range would actually be in the
    // memory in the range of line addresses Y = 319-(0...239) = 319...80. To see this range, we have to scroll the view by +80 units in Y
    // direction so that the contents of Y=80...319 are displayed instead of Y=0...239.
    if ((madctl & MADCTL_ROW_ADDRESS_ORDER_SWAP))
      //SPI_TRANSFER(0x37/*VSCSAD: Vertical scroll start address of RAM*/, 0, 320 - DISPLAY_WIDTH);
#endif

Compile and execute:
mkdir build
cd build
cmake -DSPI_BUS_CLOCK_DIVISOR=20 -DST7789=ON ...
make -j
sudo ./fbcp-ili9341

Sorry, this is because I accidentally masked an initialization statement，
Not long ago I discovered and fixed this problem

bruh I cannot get this to work. . .I have followed every guide and rewired I dont know how many times configured vanilla fbcp repo and even tried the waveshare and im getting no life out of the display

bruh I cannot get this to work. . .I have followed every guide and rewired I dont know how many times configured vanilla fbcp repo and even tried the waveshare and im getting no life out of the display

hi bro
Can you provide your hardware and connection diagram?
Have a nice day

I know this thread is old but it seems like you guys got the display to run.
I did too but Im having a major issue. When I push my desktop on the display (via startx) or any application it works for a few seconds. Then the screen goes blank/black again and I have to restart the application/desktop.
I have no clue why this is happening. I disabled in the config file the spi and removed all dtoverlays. As in the waveshare wiki instructed I added this to the file:
hdmi_force_hotplug=1
hdmi_cvt=hdmi_cvt=640 480 60 1 0 0 0
hdmi_group=2
hdmi_mode=1
hdmi_mode=87
display_rotate=0

Is anybody still "here" and has an idea what is going on? I would appreciate the help cause I cant find a solution nor a thread/post where somebody had similar problems. Thanks!

I know this thread is old but it seems like you guys got the display to run. I did too but Im having a major issue. When I push my desktop on the display (via startx) or any application it works for a few seconds. Then the screen goes blank/black again and I have to restart the application/desktop. I have no clue why this is happening. I disabled in the config file the spi and removed all dtoverlays. As in the waveshare wiki instructed I added this to the file:
hdmi_force_hotplug=1
hdmi_cvt=hdmi_cvt=640 480 60 1 0 0 0
hdmi_group=2
hdmi_mode=1
hdmi_mode=87
display_rotate=0

And I tried changing the DMA channels but that didnt change anything...
Is anybody still "here" and has an idea what is going on? I would appreciate the help cause I cant find a solution nor a thread/post where somebody had similar problems. Thanks!

If everything works normally at the beginning, it should be the reason for the backlight control.

I know this thread is old but it seems like you guys got the display to run. I did too but Im having a major issue. When I push my desktop on the display (via startx) or any application it works for a few seconds. Then the screen goes blank/black again and I have to restart the application/desktop. I have no clue why this is happening. I disabled in the config file the spi and removed all dtoverlays. As in the waveshare wiki instructed I added this to the file:
hdmi_force_hotplug=1
hdmi_cvt=hdmi_cvt=640 480 60 1 0 0 0
hdmi_group=2
hdmi_mode=1
hdmi_mode=87
display_rotate=0

And I tried changing the DMA channels but that didnt change anything...
Is anybody still "here" and has an idea what is going on? I would appreciate the help cause I cant find a solution nor a thread/post where somebody had similar problems. Thanks!

If everything works normally at the beginning, it should be the reason for the backlight control.

That means? I checked the connection and its connected to GPIO 24 which fbcp says too...

https://github.com/juj/fbcp-ili9341/assets/38922171/fdea9c2b-d737-496b-b1af-6472def05228
Here is a clip of what exactly happens. In the video FBCP is already running and I simple use "sudo FRAMEBUFFER=/dev/fb0 startx" to display the desktop on the display.

WhatsApp.Video.2024-04-18.at.18.07.52.mp4
Here is a clip of what exactly happens. In the video FBCP is already running and I simple use "sudo FRAMEBUFFER=/dev/fb0 startx" to display the desktop on the display.
It seems to be a software/connection issue because with my Arduino it works flawlessly...

It seems that you use auto-start at power on. It is recommended not to set auto-start on power on during the debugging stage.
It is recommended to configure VNC first to see your desktop .

WhatsApp.Video.2024-04-18.at.18.07.52.mp4
Here is a clip of what exactly happens. In the video FBCP is already running and I simple use "sudo FRAMEBUFFER=/dev/fb0 startx" to display the desktop on the display.
It seems to be a software/connection issue because with my Arduino it works flawlessly...

It seems that you use auto-start at power on. It is recommended not to set auto-start on power on during the debugging stage. It is recommended to configure VNC first to see your desktop .

I dont. When the rpi is booted up I connect via ssh and start both fbcp and startx manually.
VNC isnt working because the default dtoverlay for the display is deactivate. At least I get a gray-/blackscreen if I try to use VNC with
# dtoverlay=vc4-kms-v3d

Closing KMS will not affect VNC work under normal circumstances.

Well in my case it does. Removing that line (or using # to comment it) results in a gray/black screen. If I undo this change it works again normaly.
But it actually doesnt matter because I dont need a hdmi/vnc connection. I only need to get the SPI display up and running.

Hey, what about performance of this display?


SAK-30138 - New Admin tool to manage the Academic Sessions (Terms) from the UI

Moving Academic Term Manager over from https://github.com/sakaicontrib/AcadTermManage into core. Since there weren't many commits, I just pulled most of it in as one commit from @hsteller .
The other commits I did were to make it compatible with Sakai 20 and add in niceties like icons, admin workspace placement, etc.

So I checked this all out in WAVE and all the labels are fine except for the endDate startDate. It looks like the yui date picker adds this input dynamically and it's not bound to the label.

I tried to switch from the (no longer maintained) YUI date picker to a jQuery UI  one (via the wicket component on https://github.com/jonespm/sakai/commit/e34947dec2158a327f1b819ab4c7836e6fd1badc rather than the javascript) and the label worked and the date picker worked. However the 2 digit year didn't work with the jQuery date picker and it also wasn't localized correctly when switching languages. I tried to pass a pattern and options as parameters but it didn't seem to change anything. :(
It would be nice if it was using the same date picker as the rest of Sakai but I don't know how to get this to work. I feel like we could create another issue to do this afterward if this was desired, since this is admin only it's seems like a minor issue. Maybe it has to use the Sakai lang-datepicker.js? It would be nice if that was a wicket component.

I would vote for just removing the date picker entirely and using a well-labeled input box....

It seems like at least with this wicket library only the Kendo UI datepicker is localized, not the jQuery UI one. The Kendo UI date/time picker  actually looks pretty nice. But in any case, we could remove the YUI and just have a plain text field.
I tried to hook it up like the initDatePickers method in GradebookNG
 and I saw that javascript triggered without error but nothing seemed to happen, probably something simple missing.
That's the piece that would be nice to be turned into a custom component for any wicket app.

I should be able look at this again this weekend if nobody gets to it first, either removing the YUI as @ottenhoff suggested or getting it to work with the jQuery-UI one. This is not something we're aiming for 19 so no real rush. Though it could get in since to a minor release since it doesn't need any new tables. (The SQL is just there to optionally add it into the Admin Workspace)

I think @ottenhoff suggestion about just removing the datepicker makes sense as this is only an admin tool (no users will see it) and if someone ends up incorporating the sakai date picker at some point in the future then that's fine.

Thanks Earle I agree with all of the suggestions. I'm *probably * going to be too busy until mid-March to address all of these issues. I didn't commit this code initially, just trying to pull over @hsteller contribution from contrib.
I also thought it would be better placed in admin-tools but nothing in there had api's or impl's just the tools so it would need a little moving around. I also thought about renaming the package but it wasn't highest priority, I just wanted to get it imported and working retaining authorship then it "seems" easier to reorganize.
If anyone else wants to add to this PR or re-do it before I get back to it I'm fine with that. Otherwise just let it hang out here. This isn't going into 19.0 so no rush.

If you want to just close this and I can re-open when I have time to work on it again that's fine too . . .

now worries it can sit out there with the WIP label!

I updated this with reviews mentioned here this afternoon.
I created the following in-case someone wants to add the Sakai date-picker later.
https://jira.sakaiproject.org/browse/SAK-41997

@ern I've addressed the issues in your review and Codacy issues. I can't see anything more to do here before user testing.

Thanks Matt for finishing this 🥇


update Identity versions April 2020

@mitchdenny
What is the java - parents - ci below?
It is failing for unknown reason.

@mitchdenny
What is the java - parents - ci below?
It is failing for unknown reason.

Parents is a new pipeline going in to support parent POM publishing via unified publishing. Still a WIP.


Disable udp download if http download is available

Hey, so we wanted to do something about udp downloads for a while. This is a proposal where UDP downloads will only be proposed if HTTP downloads are not set up.
I'm also fine with nuking the feature though. Downloading things at 15kB/s is just terrible. And according to @cu-kai, if we increase the maximum bandwidth, « but.. if more than one person starts doing this [downloading over udp], the server feels it ». Our UDP protocol is just terrible at downloads. This was apparently done because some people used an old tremulous client at the time, something we don't do.
Note: in the current state this received little to no testing. This can come later once people say if they like the idea or not.
Fixes https://github.com/Unvanquished/Unvanquished/issues/1926.

How about making a sv_udpDownloads cvar to enable it or not, instead of having it randomly depend on HTTP cvars

If we have a cvar for that, then we can't disable udp download as soon as www download is setup. That kind of defeats the point of this: making udp downloads obsolete should there be any other option. I'd rather know if my http download setup is borked that having it fallback immediately to something that is almost unusable.

If we have a cvar for that, then we can't disable udp download as soon as www download is setup.

What do you mean? You could set the cvar to disable UDP right next to where you set the one for HTTP url

I'd rather know if my http download setup is borked

You mean by seeing people disconnect from the server?

To me the UDP download is simply too slow to be usable, meaning we don't use it and we never use it and every tutorial giving instructions to enable download would document http download. Our downloadable content is too large for UDP download.
If we don't know how to make UDP download faster, we better remove it entirely, as it is simply unused and will never be.
To make autodownload standalone, I would favor embedding a minimalistic http server we would run on the same port than UDP port but as TCP port. This would also be reusable for other things like downloading levelshot for map vote screen or things like that.

A minimal HTTP server isn't a bad idea I suppose.


nav pixel fixes

[x] main menu labels should be 13px semibold (now they're 16 regular)
[x] active item should be white, with the icon white (now it's blue4)
[x] my own username should be 14px (currently 16), get pushed down to 4px away from the avatar and turn white when active.

@keybase/react-hackers

:mag_right: The commits 8ca7e6037d55...615b874a465a introduced some visual changes:

Changed: Tab_Bar-Custom_Buttons_1 (before) (after)

Changed: App_Tab_Bar-Normal (before) (after)

:+1:


Wrong assumptions about C types

In Crystal's codebase wrong assumptions are made about C types. The type int is just mapped as Int32, etc. The same assumptions are recommended in the documentation (introduction).
Why am I saying this is wrong? There are very few, if any, C types that have their exact byte size specified in the standard.
What does the C++ standard state the size of int, long type to be?
Of course, there are some assumptions that are true for current major systems (say, Windows, Mac and Linux), so let's list them.
Signed-ness won't be mentioned here, because it should be obvious.

char is 1 byte
short is 2 bytes
int is 4 bytes
long long is 8 bytes
size_t is the same number of bits as the OS bit-ness (4 or 8 bytes)
long

Mac, Linux: same as size_t
Windows: 4 bytes

float is 4 bytes
double is 8 bytes

Reference
(Here are some of these things implemented in code)
I've definitely seen a few cases where one of size_t/long is mapped as one of Int32/Int64 in Crystal's codebase. So, many things are broken now, not just in perspective.
Short-term fix: make sure the definitions of SizeT and LongT are correct and always use these.
This will need to be done if we expect Crystal to work on Windows.

But, I don't think it's a good idea in general to directly use Crystal's IntXX types for C bindings, because that works only by coincidence with the current de-facto standards. So if Crystal wants to support another platform has has some different choices, not only will there be a ton of work required to fix up the Crystal compiler for them, but additionally (almost) every library that uses C bindings will break. You probably realize that this is not something that can be solved reasonably.
My suggestion is to simply provide aliases for every C numeric type, even if they are trivial. Trivial for now, that is, because they easily may change in the future. In addition, less thinking is required to use straightforwardly named aliases.
A great example of such aliases
The sooner this is done, the better.

There's a worse example: getchar, which returns an int, is set to return a char.

You may think, why doesn't everything fall apart when things like this are used? Well... one function argument (not sure if last one or first one) is "allowed" to have wrong size. Same position in stack, little-endian architecture...

I agree. We could have top-level aliases like CInt, CChar, CLong, etc., and even CString (aliased to CChar* or just UInt8*). We can mention them in the C bindings docs, and of course use them in the standard library. And as a plus, like @BlaXpirit says, it will make it easier to write C bindings because one wouldn't need to think "Ok, char* is UInt8*, int is Int32", etc, just put a "C" before it.
@waj thoughts?

Yes, like the getchar mapping. I think that's a leftover from early days, I searched its uses and it's not used at all so we could remove it (and also putchar).

I'm not sure I'd introduce them to the toplevel, I wouldn't mind having to write LibC::Int, LibC::SizeT etc, after all it's intended for bindings only.

+1 for me. I also agree with @jhass too.

+1
not polluting the toplevel seems right, yet, I would allow just Int SizeT inside a lib declaration.
May be we should avoid other types in a lib actually. It seems that every desired type used should be this C built-in types or declared in another lib.

I just added the type aliases (69c6254) and changed a few declarations. Change all the existing declarations might be a tedious job, so I suggest we fix them as needed.
I'll update soon the function definitions of LibGMP so we can support 32bit. PR for other libraries are welcome! :-)

@waj Thanks! This is very useful for #1075

After the above commit, in which I went through all libs to make sure they are mapped to the correct types, and this one I'm closing this.
@BlaXpirit thanks for brining this issue. I believe writing C bindings now will much easier and less error-prone.


Suggestions made by enr1c

List of suggestions / bugfixes i am going to do, suggested by u/enr1c0wastaken (Creator of flute textures and the original idea)

Fix the damn targeting system
The recall command having priority over anything else
Attack & Sit/Stand range (Might be due to old version)
Glow effect on any wolves of the same color as the flute (Maybe when sneaking?)
Remove ALL the temporary assets (sounds, texutres, etc.)
Possibly unique sound for each flute, i included this in the description on accident but is a good idea
Commands have a different sound than just playing the flute normally

~Fix the damn targeting system~ DONE
The recall command having priority over anything else
~Attack & Sit/Stand range (Might be due to old version)~ DUE TO OLD VERSION
Glow effect on any wolves of the same color as the flute (Maybe when sneaking?)
Remove ALL the temporary assets (sounds, texutres, etc.)
Possibly unique sound for each flute, i included this in the description on accident but is a good idea
Commands have a different sound than just playing the flute normally


large package refactoring + separation of spanner read/write converter

Major refactor to be more Spring Data idiomatic:

repository: move implementation and factory classes into repository.support (Closes #445)
mapping:

move conversion related classes to convert
separate responsibility of reading and writing from the ObjectMapper (renamed to SpannerConverter) into MappingSpannerWriter and MappingSpannerReader

Thanks, yeah, I fixed those. Travis is failing due to the flaky pubsub emulator issues currently. I'm trying to get it to pass via restarting.


Feature request: Auto-select Search on load

Is your feature request related to a problem? Please describe.
When the page loads and you know what you want, you need to click on the "Search" box before you type.
Describe the solution you'd like
I suggest an extremely small usability change - That the search box is selected by default so that you may immediately start typing from a bookmark.
Describe alternatives you've considered
Making it one of the first boxes that get selected when "Tab" is pressed after page load

This has been implemented in #705. The input is auto-focused initially, but the search bar is the next element in the tabfocus list. After that, operation arguments come next.
Remember you can also use keyboard shortcuts to jump to specific places. They can be found in the 'About/Support' pane.


GWT3Export does not work when annotation added by XMLMapper annotation processor

Following https://github.com/treblereel/mapper-xml/pull/81 on XMLMapper I get a model class like the following:-
@XmlAccessorType(XmlAccessType.FIELD)
@XmlType(name = "", propOrder = {
    "header",
    "miningBuildTask",
    "dataDictionary",
    "transformationDictionary",
    "model",
    "extension"
})
@XmlRootElement(name = "PMML")
@JsType
@GWT3Export
@XMLMapper
@Configuration(additionalAnnotation = {
    @Configuration.ConfigurationAnnotation(JsType.class),
    @Configuration.ConfigurationAnnotation(GWT3Export.class)
})
public class PMML {

    @XmlElement(name = "Header", required = true)
    protected Header header;
    ...
}

The important things to understand are:-

The class PMML is a DTO that has a (un)marshaller generated by the @XMLMapper annotation
The PMML DTO needs to be exposed through JsInterop and the boiler-plate J2CL @GWT3Export generated.

This worked fine.
However the generated (un)marshaller also needs exposing through JsInterop and J2CL boiler-plate generated.
This is why I now add the @Configuration annotations.
However when I attempt to J2CL compile the application I receive the following error:-
/home/manstis/workspaces/git/manstis/marshaller/marshaller-api/target/gwt3BuildCache/0.17-SNAPSHOT/marshaller-api-b8fb723b2f15496d22b830c894a5776cbc13fb79/closure-inputs/com/anstis/pmml/model/PMML_XMLMapperImpl.impl.java.js:64:
Originally at:
/home/manstis/workspaces/git/manstis/marshaller/marshaller-api/target/gwt3BuildCache/0.17-SNAPSHOT/marshaller-api-b8fb723b2f15496d22b830c894a5776cbc13fb79/closure-inputs/com/anstis/pmml/model/PMML_XMLMapperImpl.native_js:1: ERROR - [JSC_UNDEFINED_VARIABLE] variable com_anstis_pmml_model_PMML_XMLMapperImpl is undeclared
  1| const _PMML_XMLMapperImpl = com_anstis_pmml_model_PMML_XMLMapperImpl
     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

/home/manstis/workspaces/git/manstis/marshaller/marshaller-api/target/gwt3BuildCache/0.17-SNAPSHOT/marshaller-api-b8fb723b2f15496d22b830c894a5776cbc13fb79/closure-inputs/com/anstis/pmml/model/PMML_XMLMapperImpl.impl.java.js:66:
Originally at:
/home/manstis/workspaces/git/manstis/marshaller/marshaller-api/target/gwt3BuildCache/0.17-SNAPSHOT/marshaller-api-b8fb723b2f15496d22b830c894a5776cbc13fb79/closure-inputs/com/anstis/pmml/model/PMML_XMLMapperImpl.native_js:3: ERROR - [JSC_UNDEFINED_VARIABLE] variable PMML_XMLMapperImpl is undeclared
  3| goog.exportProperty(_PMML_XMLMapperImpl, 'INSTANCE', PMML_XMLMapperImpl.$static_INSTANCE__com_anstis_pmml_model_PMML_XMLMapperImpl);
     ^^^^^^^^^^^^^^^^^^

2 error(s), 0 warning(s)

The files are in the following ZIP:-
PMML_XMLMapperImpl.zip

See https://github.com/manstis/marshaller/blob/main/marshaller-api/src/main/java/com/anstis/pmml/model/PMML.java#L70
If you clone https://github.com/manstis/marshaller and uncomment the line; you'll get the error.
With the line commented everything is OK (but the marshaller is not automatically plumbed into the JavaScript world).

@manstis hmm, interesting, let me take a closer look ...

@manstis must be fix in https://github.com/treblereel/gwt3-processors/commit/ecd7e02ad898f504c6e523e4ffb8d76d8507ecea

@manstis updated version has been released to sonatype

Great. Thank-you @treblereel. I can confirm it works fine now.


Prompt engineering for chat model that are too verbose

Chat models tend to be verbose which is a problem with some of our scenarios.
For example with the MMLU scenario, we expect one single letter as the answer. However some models like anthropic/claude-v1.3 like to justify themselves first (like ChatGPT). therefore instead of answering A they will answer something like Given the context, [...], the answer is A. Once truncated, all that is left here is Given which is not a valid response.
For Anthropic, the way we deal with this right now is by adding a PROMPT_ANSWER_START.
Here is what a question looks like with `PROMPT_ANSWER_START = "The answer is":
Human: The following are multiple-choice questions (with answers) about anatomy.

Question: What is the embryological origin of the hyoid bone?
A. The first pharyngeal arch
B. The first and second pharyngeal arches
C. The second pharyngeal arch
D. The second and third pharyngeal arches
Answer: D

[...]

Question: The mucosa of the hard palate is
A. keratinised and has submucosa and minor salivary glands posterolaterally.
B. non-keratinised and has submucosa and minor salivary glands posteromedially.
C. keratinised and lacks submucosa and minor salivary glands.
D. non-keratinised and lacks submucosa and minor salivary glands.
Answer:

Assistant: The answer is

This needs to be tested. One problem is that the choice of PROMPT_ANSWER_START is tricky and mostly depends on the scenario. For example the coice of "The answer is" does not work well for summarization tasks. Also, the model can be quite sensitive, fro example "The answer is" gives quite good results but "The answer is:" gives terrible results.
I feel like as we are gonna have to deal with more and more chat models we should have a general way to deal with this.

I think we should take a step back and rethink adapters.  The current AdapterSpec was designed for in-context learning, but if we're doing zero-shot instruction following, I think we might want a completely different set of fields.
In particular, we probably want a general way to construct a prompt with explicit instructions on the output format (e.g., The answer is one of ...).  We could ask for the answer in an <answer>...</answer> tag.  Sometimes people use JSON format to structure their prompts too.
I would say that if there is not a reasonable way to get these instruction following models to be performant, then we should just just skip them for the old HELM and work on the new HELM.

This is more or less solved by the additional instructions in #2670.


Update fs2-core to 2.4.1

Updates co.fs2:fs2-core from 2.3.0 to 2.4.1.
GitHub Release Notes - Changelog - Version Diff
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Ignore future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "co.fs2", artifactId = "fs2-core" } ]

labels: library-update, semver-minor

Codecov Report

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

@@          Coverage Diff           @@
##           master    #117   +/-   ##
======================================
  Coverage    0.00%   0.00%
======================================
  Files          24      24
  Lines         234     234
  Branches        9       9
======================================
  Misses        234     234

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 7969631...2d88031. Read the comment docs.


List of deleted photos?

Detailed description of the problem
When Lychee deletes a photo, does it scrub it completely from the database, or is it possible to get a list of deleted pictures?
Steps to reproduce the issue
Delete a photo.
Output of the diagnostics (Settings => Diagnostics)
n/a
Browser and system
Chrome browsing to a Ubuntu 16.04 server.
Rational
I have enabled an S3 system, sorta :).
I have two additional upload directories - uploads.local and uploads.s3. Local is stored on the ec2's hard drive. S3 is a read-only rclone fuse mount of an S3 bucket. I then use unionfs to mount uploads.s3+uploads.local onto uploads.
When a file gets uploaded, unionfs stores it on the local file system, since the s3 directory is read-only. A cron job runs every minute and moves all files in the uploads.local directory into the s3 bucket.
The problem is, you can't delete a file from the s3 bucket this way. I want to keep the s3 bucket read-only. If there was a way to extract deleted photos from the database somehow, or from a log file, I could clean them up manually. I don't mind if I have to grep a log file somewhere, I just need a list of deleted pictures.
Is this possible?
Sidebar: I needed to do the unionfs mount because rclone's S3 fuse file system doesn't support opening files as read/write. If Lychee didn't do this, I could just mount the S3 bucket directly. Is read/write needed for resizing the images?
Thanks for an amazing product. It's amazingly well-put together.

This issue will be closed because I'm not actively working on Lychee anymore. The repository of Lychee will stay available, but the main development continues under the Lychee Organisation. A fork maintained by the community. Important issues have been migrated. Feel free to re-add your issue(s) when necessary.


Use a local keyword registry to make validate thread-safe

This makes validating a schema thread-safe. I was focused on fixing that call path specifically, and not addressing thread-safety throughout the entire code base, so there is may be more global variables being used elsewhere. This PR introduces a a struct to represent a keyword registry, and loading of the registry and validation occurs in instances of a keyword registry, avoiding the use of global package variables.
This is the patch that we have been using for https://github.com/getporter/porter for 6+ months to be able to validate a schema in a thread-safe manner when registering custom validators.
I was mostly interested in getting this to work without making any backwards incompatible changes to this library's existing API. For example, I kept the package level functions that manipulate package variables, such as RegisterKeyword, which requires the use of locks. If you are okay with making a breaking change, and removing global state, that would simplify the patch quite a bit.
This is a fix for #80 , but is limited to validation. There are probably more spots that would need to be refactored as well.

Again, very appreciated. This will take a bit more time to review as I have to be more thorough with it and do some testing, but at a glance looks like a step in the right direction.

@Arqu Just checking if you've had a chance to look at this and had any feedback?

Sorry, been pretty booked for the past while. I'll aim to have a go at it within the next 10 days.

Oh great! I'm excited to not have to have a fork of golint anymore! 🎉 I just pushed a fix for the golint errors.


Paid option for faster builds

Would be useful if there were a paid account option to speed up build time, avoid having to wait in the queue and instead have your builds kicked off immediately.

+1

Thanks for the suggestion! We have some premium stuff in the works, stay tuned. :)

Curious if the premium stuff will be lumped within the "add-on" category?  I am currently a paid subscriber of the add-on service and will continue to do so if the premium stuff is included

Curious if the premium stuff will be lumped within the "add-on" category?  I am currently a paid subscriber of the add-on service and will continue to do so if the premium stuff is included


word break is not working

word break is not working please help me

can you post a jsfiddle? i can check it out.


Weather Checker

Hello, I want to contribute a simple website made using HTML, CSS, and JS that allows users to view the current weather of several cities.

assigning this to you @ishubham010


RFC: Replace Swig with Twig

Swig is no longer maintained: paularmstrong/swig#628

Its arguably inferior to Twig.js, which is actively maintained and supports cacheing and a host of other improvements over swig.

This RFC is a proposal to replace swig with Twig as an option for templating language. If accepted, i will do the PR as this is very important for my team.

Continued from https://github.com/keystonejs/keystone/issues/2784

I didn't know that Swig isn't maintained anymore, thus it makes sense to remove it.
I'm not sure if replacing it with Twig is the way to go here though, because that's another templating language setup that we have to maintain. (which is a pain since we don't use those templating languages)
Maybe @JedWatson has some comments here?

well, Swig is based on the original Twig templating language, as is Twig.js. so in likelyhood there would be no change other than the implementation of the loading of templates and render method. Swig deviates from the standard Twig syntax in some instances.
Also, would it change your mind if I vowed to maintain the templates? If no, i certainly understand and harbor no ill will.

I vowed to maintain the templates

You know that goes, can't force anybody to maintain open source in their free time. :)
I appreciate the offer, and I understand the reasoning. I don't mind either way, but lets have @JedWatson have the last call since he's been the main dev behind the generator.

less is more. I'm starting to question the value of providing so many templating language choices in the generator at all. How about ejs, or pug. And document very very well how to swap out the templating language for anything else?

Agree with @morenoh149, that'd make sense imo.

@morenoh149 which is all great if Keystone uses your favorite templating language, but if it doesn't you're SOL. As for your comment "how about ejs or pug":
Well, how about Twig?
Twig is good for traditional MVC developers who want a feature complete templating engine completely seperated from the controller/model, with security on by default. its the same as swig except for the swig author(s) deviated from the spec of Twig in some ways, and Twig has compiled template cacheing, as is in my opinion a better codebase. the current swig views should be compatible with Twig already.

No you're not, swapping in your favorite templating language isn't hard. We only provide three implementations for fun, but putting in your templating language of choice is actually pretty easy. (do a diff on our different implementations)

@r3wt Paul Armstrong recommends nunjucks in that deprecation issue, which we also have. I haven't had a chance to compare it with Swig / Twig closely, what's your view on that? Is having nunjucks good enough or does Twig present a compelling reason to support another template in the generator?
As you can tell from the other maintainer comments, we've had a fair bit of overhead in the project because we've had so many variations on template languages (including less/sass) to maintain equity between.
Having said that, handlebars has really been the painful one... it was contributed and not fully functional, it's been haunting me ever since (and isn't even something I need/use/want, which sucks a bit) - it's also the most different from the other three, which makes maintaining it hard.
If you're really up for contributing + maintaining the Twig templates, I'm more happy for that than @mxstbr or @morenoh149 have sounded, but want to make sure you know what you're getting yourself into :)

@JedWatson I already have this underway locally. so far i've only needed to make a few minor changes to keystone.js.
var Twig = require('twig');
keystone.init:
'view engine': 'twig',
'twig options':{ method: 'fs' },
'custom engine':Twig.render,

I'm currently working on editing the templates. can you clarify the shape of the template arguments being passed into the render mechanism? i don't seem to be getting any variables in my template.

I should clarify the reason i use Twig.js:

Mature based on Symfony's Twig Template Language, since 2009.
Active Development.
good perf in node
Portable to PHP (and Python(Jinja) and Ruby(Liquid) with minimal effort)

it does have some drawbacks:

high perf cost for initial render
no autoreload of templates
implementation lacks 100% coverage.

If you've got it done anyway, I'd love to see a PR! :+1:

I'm working on cleaning it up and testing. I'll submit the PR when i get home from church.

@mxstbr Ok, so i've opened a PR. i'm unsure how i can test this? Could you offer some advice. I'm literally brand new to generators and modules in general, so i'm unsure how i could test this?

I don't actually know either! Running the generator, choosing Twig and verifying that everything works as before would be a good one…

@mxstbr ok, so i've been testing and i've ran into some potential issues:

macros cannot be called from the context of other macros, so flash messages arent working.
utils appears to not be imported, or if it is, utils.isObject() is not working as expected. in order to use a function in twig js, Twig.extendFunction(name,fn); should be used. I'm going to hack on this later this evening. i won't submit another PR until i've solved all issues.

so flash messages arent working.

Are you using the latest master version of keystone? Flash messages don't exist anymore…

I'm using whatever comes with generator-keystone!

The generator still loads in 0.3x unsurprisingly. But if flash is lacking in the 4x line you can ignore that. Actually it may be cool to release a generator that loads 4x at the same time 4x is released!

My PR fails. attempting to select twig in the generator results in jade being selected. debugging now.

https://github.com/keystonejs/generator-keystone/commit/988fa0b8a0645624435b16bb5ec5758db14c8d30 and https://github.com/keystonejs/generator-keystone/commit/8371ccf16cf063e6856b39a5f39d180bad4a07dd

Does anyone know about the status of template autoreloading? Just started a new Keystone project with the Twig update after finishing one with Swig, and the lack of template reloading is a pretty big hang up for development...

As a temporary solution for those who have the same problem, adding the following to nodemon.json will make it restart on twig template changes:
{
  "ext": "twig"
}


Astro with Contextual Editing

Discussed in https://github.com/tinacms/tinacms/discussions/3399

Originally posted by apolo-damasco November 12, 2022
Hi, I just wanted to start this request because I know that many people are interested in this and would like to have a way to track the news on this topic.
@perkinsjr I see on discord that you are looking into this. Would you mind writing here if you ever manage to make it work?
Thank you!
Looks like the community came up with a way to get this working (on an old Astro release) - https://github.com/tinacms/tinacms/discussions/3399#discussioncomment-6453841
Sounds similarish to the way that you get it working with NextJs + App router

[ ] Get contextual editing working with current stable Astro

The following are to be achieved in other PBIs

[ ] add a starter project
[ ] update docs
[ ] add blog post

need to break up into smaller issues when we pick up the work

It would be nice to have this in Astro-components (SSR) as an option, so I don't have to write React components just because I need the contextual editing. I know live editing is not really possible if you can't update client side, but you sanity has something similar where the router refreshes the view when you finished updating the input field (after 1s or so).

Not sure if this will help at all, but I was researching for a project with Storyblok CMS and they have made live editing with Astro work and explained the technical approach a bit in this post: https://www.storyblok.com/mp/announcing-live-preview-for-storyblok-astro#how-it-works-under-the-hood
Obviously Storyblok is very different from Tina so this might not be relevant at all but I thought maybe this could be interesting.

Not sure if this will help at all, but I was researching for a project with Storyblok CMS and they have made live editing with Astro work and explained the technical approach a bit in this post: https://www.storyblok.com/mp/announcing-live-preview-for-storyblok-astro#how-it-works-under-the-hood Obviously Storyblok is very different from Tina so this might not be relevant at all but I thought maybe this could be interesting.

Thank you for the hint <3

Hey all
On https://github.com/tinacms/awesome-tinacms a community member has done up a sample site using Astro + live editing with the caveat that you need to use react - https://github.com/klrfl/simple-blog-with-tina
Making it work without react is a goal for this if it is possible.
If you haven’t voted already - check out our poll for extending framework support
https://github.com/tinacms/tinacms/discussions/5247

Hey all
On https://github.com/tinacms/awesome-tinacms a community member has done up a sample site using Astro + live editing with the caveat that you need to use react - https://github.com/klrfl/simple-blog-with-tina
Making it work without react is a goal for this if it is possible.
If you haven’t voted already - check out our poll for extending framework support #5247

I will check out this one, thank you <3
I have tested the approach that was mentionend on discussion: https://github.com/tinacms/tinacms/discussions/3399#discussioncomment-6453841, But I do not know why it didn't work :/
and I already vote 🚀
in case I have some progress I post here :)

I guess it could help some projects, but in my case it is a bit different, and I couldn't make this work :/
I guess the main problem is how my current theme uses getCollection from astro: https://github.com/satnaing/astro-paper/blob/main/src/pages/posts/[slug]/index.astro#L11-L18
and his approach is using few things from tinacms: https://github.com/Klrfl/simple-blog-with-tina/blob/main/src/pages/posts/[...slug].astro#L7-L29
just few hints in case someone is playing arround with this.
you should add

tina() in your configs: https://github.com/Klrfl/simple-blog-with-tina/blob/main/astro.config.mjs#L8
page: https://github.com/Klrfl/simple-blog-with-tina/blob/main/astro.config.mjs#L8 and https://github.com/Klrfl/simple-blog-with-tina/blob/main/src/pages/posts/[...slug].astro#L34-L36
add useTina: https://github.com/Klrfl/simple-blog-with-tina/blob/main/src/layouts/PostLayout.tsx#L15-L19

The upcoming Astro 5 release will introduce custom loaders to the content collections API. This allows us to query the Tina API directly in the collections config file and populate the data for getCollection().

src/content/config.ts

import { defineCollection, z } from "astro:content";
import type { LoaderContext } from "astro/loaders";
import client from "tina/__generated__/client";

const postsCollection = defineCollection({
  loader: async (context: LoaderContext) => {
    const postsResponse = await client.queries.postConnection()

    // TODO: Get all pages - this only pulls the first...
    return postsResponse.data.postConnection.edges
    ?.filter((post) => !!post)
    .map((post) => {
      return {
        ...post?.node,
        id: post?.node?.id,
        tinaInfo: post.node?._sys
      };
    })
  },

  schema: z.object({
    // ...
  })
})

export const collections = {
  'posts': postsCollection
}

I've had some success adapting the demo mentioned in this thread to retrieve data this way. It’s not perfect though, I'm not sure what the best way to pass props into useTina() would be. It seems that a content loader can only return strings, which makes it difficult to pass a query directly from getCollection(). For now, I’m making a query from the Astro page template.

src/pages/posts/[...slug].astro

---
import Layout from<EMAIL_ADDRESS>import PostLayout from<EMAIL_ADDRESS>import { getCollection } from "astro:content";
import client from "tina/__generated__/client";

export async function getStaticPaths() {
	const posts = await getCollection("posts");

	return posts.map((post) => {
		return {
			params: { slug: post.data.slug },
			props: {
				title: post.data.title,
				getTinaProps: async () => client.queries.post({ relativePath: post.data.tinaInfo.relativePath }),
			},
		};
	});
}

const { title, getTinaProps } = Astro.props;
const tinaProps = await getTinaProps()
---

<!-- -->

The post content React template is unchanged except for a few data-tina-field attributes.

src/layouts/PostLayout.tsx

Note that Tina needs to be running at build time too:
{
  "scripts": {
    "dev": "npx tinacms dev -c \"astro dev\"",
    "build": "npx tinacms dev -c \"astro build\"",
  },
}

I made some small tweaks to the branch @kauhat's made.
https://github.com/blanchardjeremy/astro-tina-visual-editing
Mostly I just wanted to rename the repo so it was more searchable. Because it took me a while digging around to find an example that got visual editing working AND worked with tinaField
Thanks!


Vite dev middleware overrides cors headers

Environment

Operating System: Darwin
Node Version:     v18.16.0
Nuxt Version:     3.8.0
CLI Version:      3.9.1
Nitro Version:    2.7.0
Package Manager<EMAIL_ADDRESS>Builder:          -
User Config:      devtools
Runtime Modules:  -
Build Modules:    -

Reproduction
https://github.com/samydoesit/repro-nuxt-cors-options by @samydoesit (https://github.com/unjs/nitro/issues/1095#issuecomment-1779823612)
it has to run locally, for more readable reproduction, you can also change test-handler.ts to this:
export default defineEventHandler((event) => {
  setResponseHeader(event, 'x-custom', '123');
  setResponseHeader(event, 'access-control-allow-credentials', 'true');
  setResponseHeader(event, 'access-control-allow-origin', 'protocol://test');
  return '...';
});

http OPTIONS :3000/test Origin:'protocol://test' responds when using nuxt in development mode:
HTTP/1.1 204 No Content
access-control-allow-methods: GET,HEAD,PUT,PATCH,POST,DELETE
access-control-allow-origin: *
connection: close
content-length: 0
date: Thu, 26 Oct 2023 16:37:23 GMT
vary: Access-Control-Request-Headers

When running nuxt (nitro server alone) in production:
HTTP/1.1 200 OK
Connection: keep-alive
Content-Length: 3
Date: Thu, 26 Oct 2023 16:38:21 GMT
Keep-Alive: timeout=5
access-control-allow-credentials: true
access-control-allow-origin: protocol://test
content-type: text/html
x-custom: 123

Describe the bug
It seems the vite dev server overrides those headers (thanks for the investigation from @danschalow in https://github.com/unjs/nitro/issues/1095#issuecomment-1781075661)

As a workaround, one might use nuxt.config to customize vite.server.cors:
export default defineNuxtConfig({
  vite: {
    server: {
      cors: {
        origin: true,
        methods: ['GET', 'HEAD', 'PUT', 'PATCH', 'POST', 'DELETE'],
        preflightContinue: true,
        optionsSuccessStatus: 204,
      },
    }
  }
})

Response:
HTTP/1.1 200 OK
access-control-allow-credentials: true
access-control-allow-methods: GET,HEAD,PUT,PATCH,POST,DELETE
access-control-allow-origin: protocol://test
connection: close
content-length: 3
content-type: text/html
date: Thu, 26 Oct 2023 16:40:54 GMT
vary: Origin, Access-Control-Request-Headers
x-custom: 123

Additional context
Using routeRules cors allows overriding access-control-allow-origin but not the rest as it early handles headers:
export default defineNuxtConfig({
  routeRules: {
    '/test': { cors: true }
  }
})

HTTP/1.1 204 No Content
access-control-allow-methods: GET,HEAD,PUT,PATCH,POST,DELETE
access-control-allow-origin: *
connection: close
content-length: 0
date: Thu, 26 Oct 2023 16:42:54 GMT
vary: Access-Control-Request-Headers

Logs
No response

thank you! ❤
we can track in https://github.com/nuxt/nuxt/issues/22512.


stacktrace is not produced on aarch64

I built and test apache/kudu on aarch64, and there are some tests failed because the stacktrace is not produced, I debug it and find 'HAVE_LIB_UNWIND'=1, and seems it uses libunwind lib to get the stack trace(maybe in stacktrace_libunwind-inl.h), but it failed. I saw the comment in utilities.h, it says the first way to get stacktrace of libunwind is still in development? so the function of libunwind to get stacktrace dosen't work? or it doesn't work on aarch64? Please help me to fix this, thanks.

libunwind fixed the issue.