Azure pipelines support to Automate RBAC role addition

We are using azure app configuration for our azure functions with managed identity.
And we need to add '*DataReader' role in app configuration for our web app principle to be able to access the App configuration after app provisioning.
Awaiting suggestions.

The document below uses App Service as an example, but it's the same idea for Azure Functions.
https://docs.microsoft.com/en-us/azure/azure-app-configuration/howto-integrate-azure-managed-service-identity

@zhenlan I'm able to create a function and it's working fine with a Managed identity like - I added app service principle as 'App configuration data reader' but my concern here is to automate the same using Azure DevOps which is missing in the document.
Compared to Azure key-vault, which we were using earlier, it was really easy to add access policies of consumer app service using ARM, but app configuration lacks here..if you can shed some light on the best way or direct me to the relevant document.
I tried exploring but I'm afraid that some existing methods require AD role write permission for Service connection principle used in the Azure pipeline to do the RBAC assignment.

Hello @hem-sharma. Did you consider to user the Azure CLI in the devops pipeline to create the role assignment? The doc I linked mentions the required permissions "Microsoft.Authorization/roleAssignments/write and Microsoft.Authorization/roleAssignments/delete". There is no way around that. The permissions would need to be present for the service connection principle.

Many thanks, @jimmyca15, Any place where "assigning permissions to the service principle associated with Service Connection (Azure DevOps)?

Sorry @hem-sharma I don't understand the question. It looks like it wasn't completed.

@jimmyca15 I mean this by: how can I allow such permissions to a Service Connection in DevOps, for e.g.

So there are only two options.
-> Manage service connection roles

-> or Manage Service Principal

As of now, I assigned an owner role (which can manage the RBAC additions) to the app (created with the service connection) but still, I'm facing 403 issues.

@hem-sharma sure, from the image it would be.
Manage service connection roles -> Role Assignments -> Add Role Assignment -> App Configuration Data Reader

Able to add RBAC role by using poweshell after adding the service principle of service connection (used in pipeline) as owner of Azure subscription, though it fails after adding role in b/w So I've made the weird solution to put command in a try/catch to silently continue for the time being. It seems like powershell command tries to list role post assignment which fails due to lack of permissions other than owner role. Still exploring a concrete solution...

@hem-sharma sure, from the image it would be.
Manage service connection roles -> Role Assignments -> Add Role Assignment -> App Configuration Data Reader

@jimmyca15 This one is for accessing App configuration, but my need is to assigning RBAC role using DevOps which requires certain permissions to do so.

To accomplish that you need to assign a role that is capable of creating role assignments such as user-access-administrator.


RDS Filtering on db-cluster-id

Fixes: https://github.com/spulec/moto/issues/5091

@bblommers I updated the Database templates to return back cluster identifiers, should be good for another run now.

@bblommers forgot to set the cluster in setup_class() when testing, should be good now? 🤞

Seems good to go now, let me know if there's anything else you'd like here.


i cant choose the model

when im in the ui and i try to change the checkpoint, it does an error, how can i solve this?

the checkpoint is the model, right?

Yes, it is. The issue might be a particular model in question. Which ones do you have selected?

also, is there any video explaining the features or configs to this colab? i really wanna get into ai image gen but idk how to start because there is a lot


Error: str is undefined

Getting this error when I press backspace after selecting some object.

Error: str is undefined
link/scope.inputChangeHandler@http://localhost:9000/bower_components/angucomplete-alt/angucomplete-alt.js:695:1

angucomplete-alt 2.0.2

Error only appears if maxlength is less than length of selected element title.

Why do you want the maxlength to be less than the size of possible input string length?

It just happened and I didn't understand what was the reason of the exception. At least it should fail with the correct error message.

To me this is happening regardless of max value. If I type a character and then delete it, it gets to that place inputChangeHandler and tries to get str.length but str is null.
It might be something in my config or callbacks that is messing it up, but the default templates send searchStr to that function, and scope.searchStr is set to null in various places in the code.
There were several pull requests and commits that seem to try to handle this for specific cases, but it seems that all it needs is some fool-proofing, perhaps like this (I can submit pull request if you agree and I am not missing something here)
scope.inputChangeHandler = function(str) {
  var strlen = str ? str.length : 0;
  if (strlen < minlength) {
    cancelHttpRequest();
    clearResults();
  }
  else if (strlen === 0 && minlength === 0) {
    scope.searching = false;
    showAll();
  }
  // etc.

Do you see errors in this example too?
http://ghiden.github.io/angucomplete-alt/#example10

No, I do not get the error in any of the examples. It seems to be caused by some of the listeners I have that affect the search string. If I change the template from ng-change="inputChangeHandler(searchStr)" to ng-change="inputChangeHandler(searchStr || '')" it works fine.
Still, seeing that other places in the directive already do stuff like ...!scope.searchStr || scope.searchStr.length... it seems that it should not be assuming that searchStr will never be a null.

This could happen if your 'title' field (not the 'search' field) is longer than the limit. It was my case.

I'm also experiencing this issue.


[release/1.6] Prepare release notes for v1.6.22

Thanks! If you have time, can you also prepare a PR for 1.7.3 ? We need to release both as there were some changes backported to both branches, including some new types (such as https://github.com/containerd/containerd/pull/8826); we must make sure that those changes also appear in the 1.7 version, otherwise a project using such code that specifies containerd 1.6.22 as minimum version would break on projects using go 1.7.x with no "solution" for such projects 😅

Thanks! If you have time, can you also prepare a PR for 1.7.3 ? We need to release both as there were some changes backported to both branches, including some new types (such as #8826); we must make sure that those changes also appear in the 1.7 version, otherwise a project using such code that specifies containerd 1.6.22 as minimum version would break on projects using go 1.7.x with no "solution" for such projects 😅

No problem, I'll do it tomorrow during my day.

Thanks!

Can you add the mailmap suggestions to .mailmap
INFO[0032] Mailmap suggestion: "Kazuyoshi Kato<EMAIL_ADDRESS><EMAIL_ADDRESS>has multiple emails
INFO[0032] Mailmap suggestion: "Andrey Epifanov<EMAIL_ADDRESS><EMAIL_ADDRESS>has multiple emails

and squash the PRs to a single commit with the release notes.
After ttrpc update, content LGTM


Can't find easy tables

Hi, I'm trying to do what the documents says in order to create an app. In step 3 there's usage of easy-tables that I can't find anywhere in the azure function. Can you please help me?

Hello, @Narden56, sorry for misleading. As per this article, easy tables and easy API are removed since Nov 11, 2019.

Is there an alternative?
Get Outlook for iOShttps://aka.ms/o0ukef

From: Dmitrii Chichuk<EMAIL_ADDRESS>Sent: Monday, January 6, 2020 10:46:23 AM
To: Azure/azure-mobile-apps<EMAIL_ADDRESS>Cc: Narden Shhadi<EMAIL_ADDRESS>Mention<EMAIL_ADDRESS>Subject: Re: [Azure/azure-mobile-apps] Can't find easy tables (#66)
Hello, @Narden56https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FNarden56&data=02|01|narden.sh%40campus.technion.ac.il|779825875f684627c1a108d79284e97b|f1502c4cee2e411c9715c855f6753b84|1|0|637138972508581268&sdata=bU%2F0uteNhsecu9VGbceuUq3PC4MY3jdoPN0FyqsQotY%3D&reserved=0, sorry for misleading. As per this articlehttps://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fazure.microsoft.com%2Fen-us%2Fupdates%2Fremoving-easy-tables-and-easy-apis-from-azure-app-service%2F%3Fcdn%3Ddisable&data=02|01|narden.sh%40campus.technion.ac.il|779825875f684627c1a108d79284e97b|f1502c4cee2e411c9715c855f6753b84|1|0|637138972508581268&sdata=QeiPWVLBrH1SiFO%2FOvsNwJVj%2BPYSdhnJaQd7mGPn5fA%3D&reserved=0, easy tables and easy API are removed since Nov 11, 2019.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FAzure%2Fazure-mobile-apps%2Fissues%2F66%3Femail_source%3Dnotifications%26email_token%3DANVVSUNYXZET4VNAKDUT5ADQ4LVV7A5CNFSM4KC4ICI2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEIEZYWA%23issuecomment-571055192&data=02|01|narden.sh%40campus.technion.ac.il|779825875f684627c1a108d79284e97b|f1502c4cee2e411c9715c855f6753b84|1|0|637138972508581268&sdata=C99todkutAQM9aXhZ%2BSxn9usxtDyzTHuoxyMX1YjO5Q%3D&reserved=0, or unsubscribehttps://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FANVVSUNUTD2KK6KF2C4VQMLQ4LVV7ANCNFSM4KC4ICIQ&data=02|01|narden.sh%40campus.technion.ac.il|779825875f684627c1a108d79284e97b|f1502c4cee2e411c9715c855f6753b84|1|0|637138972508591266&sdata=R0l3MSfgvCifQ53IHVc3ua8cl5E%2BoeUy7znL5dG3ws4%3D&reserved=0.

@Narden56 Is that a question for Azure Functions? Then you are on a wrong repository.
https://github.com/Azure/Azure-Functions/issues
There is no alternate solutions to take over easy tables and easy APIs. Sorry.

Hello, @Narden56!
We haven't heard from you in a while, so I close this conversation. Should you still have any questions, please contact us again.


[User Story] NEXT View User history

[User Story]
NEXT View User history

Epic Title

User Story Title
NEXT View User history

T-shirt size: S(mall), M(edium), L(arge)
TBD

Story Points - Fibonacci (1,2,3,5,8,13)
TBD

User Story
[Value Statement] "As a user of a certain type (specify), I want to do something (action) so I can provide business value"

Description
A short description

Business Need (the why):
from epic, if needed

Details
All the details needed to accomplish the story. Tasks - can be linked

Additional User Story
linked

Acceptance Criteria/Tests
The list of tests or criteria to be used to validate the story has been completed. May still need UAT or SIT / integration testing with other stories.

Failure
if any, fold in negative tests

Definition of Done
e.g.Passes all regression tests, Passes testing per acceptance criteria, Approved by UI team, Able to show feature in demo

UX/UI Details and/or mockups
if UI change, a mockup or description of what to change, attach image/file

Applications or Systems impacted
upstream/downstream applications/systems

Dependencies
non story dependencies

Assumptions
if any

Performance Considerations
Will the work performed as part of this story impact system performance. If there is potential for a performance hit, where would you expect it to manifest in the system.

Security Considerations
E.g., does this story involve working with Personal Identifying Information (PII)? Note any such security sensitive aspects.

QA Considerations
what might be hard to test or test setup criteria

Acrhitectural/System or Component Impacts
if we're adding something new or significantly changing architecture flag for architect review

Reverse Engineering Required
to document areas not known well by dev team

Questions/Clarifications
Create new issue (add label: question) in this repo and link to this issue

A feature discussed during 9/13/18 meeting on additional user stories. Created for visibility to the project. Put in archive to restore at a later date.

Closing issue so that it doesn't appear in KanBan To do for now.


Heart attack possibility using DNN has been done.

Related Issuse

Info about Issue or bug

Closes: #[issue number that will be closed through this PR]
Describe the changes you've made
A clear and concise description of what you have done to successfully close your assigned issue. Any new files? or anything you feel to let us know!
Checklist:

[x] My code follows the style guidelines of this project.
[x] I have performed a self-review of my own code.
[x] I have commented my code, particularly in hard-to-understand areas.
[ ] I have made corresponding changes to the documentation.
[x] My changes generate no new warnings.

Screenshots

Original
Updated

original screenshot
updated screenshot

@mentors can you verify the PR?


Add "notWhitespace" assertion

The PR adds Assert::notWhitespace method.
This assertion is needed to check if a string has at least one not-whitespace character. Such assertions are useful for user input checking when something non-empty (in terms of whitespace) should be inputed.
Hope it'll be useful for someone else too 😄

I'm not sure but may be notWhitespace should return false for an empty string?

Tell me more about this scenario. The assertion checks if a string contains a whitespace. So Assert::notWhitespace('a b'); will throw an exception. I didn't understand the example above, could you elaborate?

Actually this assertion checks if a string contains whitespace only characters.
Consider the following example: one should apply some assertion on a city name.  It's must be a not empty string (Assert::stringNotEmpty) with a minimal and maximum length (lengthBetween). The name could contain spaces if it consists of several words, but it definitely cannot be a string with only whitespace characters.
Such a problem could be solved using regexp assertion as well, but a special assertion could increase code readability. Also, I believe it's a common enough task to create a special assertion for it.

Okey, I see and I understand. notWhitespaceOnly is a better name, yes.
Im not sure that it is needed however. What you have forgotten is to trim your inputs.
function foo($inputVar) {
  $var = trim($inputVar);
  Assert::stringNotEmpty($var);
}

@Nyholm I've updated the name of the assertion.

Now about why I believe this assertion is useful. There are some problems in the snipet you've provided:
  trim($inputVar);

assumes that the $inputVar is a string (which is not necessary true). In a perfect world I have to do something like:
Assert::string($intputVar);

before trim it. Next, the message provided by Assert::stringNotEmpty will be misleading: I pass a not empty string (containing only spaces) but get an exception which tells me that the string is empty. Thus, in perfect world I have to use something like:
Assert::stringNotEmpty($var, 'The argument must contain at least one meaningful character');

Next, in most cases I don't care about trailing an leading whitespace in the string. I just want it not to be whitespace only. Thus $var from your snipet is just a temp variable which is needed only for validation purpose.
The "ideal" snipet could looks like:
function foo($inputVar) {
  Assert::string($inputVar)
  Assert::notEmpty(
    trim($inputVar),
    'The argument must contain at least one meaningful character'
  );
 // Real code goes here...
}

I don't mean that it's too complicated logic, but copying this snipet again and again made me sad.

So, notWhitespaceOnly assertion has two main purposes:

Reduce duplication in assertion logic
Improve readability of code.

I believe these reasons are important enough to introduce a new assertion.

Found myself needing this today. I want Assert to catch empty strings but I can't find a way to do it. Works for '' but not '  ', for example. I want Assert to catch this case so I don't have to call trim() beforehand.

@Nyholm - The following works for my use case. Thanks for the tip!
Assert::allNotEmpty(array_map('trim', $arrayVar));


Appending elements to an empty OAStackView looses top constraint

Consider this example:
let stackView = OAStackView()
for view in view {
    stackView.addArrangedSubview(view)
}

As a result of this code the OAStackView has lost constraint between self and first subview.
As far as I understand, the part responsible for this is in OAStackView.h:198
NSArray *constraints = [self constraintsBetweenView:self andView:previousView inAxis:self.axis];
[self removeConstraints:constraints];

When adding second subview, it removes constraints from the first subview, including OAStackView-to-first-subview constraints and never sets them back.

+1


feat: add paste handler to support iOS autofill

https://support.apple.com/guide/iphone/automatically-fill-in-sms-passcodes-on-iphone-iphc89a3a3af/ios

I was just testing https://github.com/metonym/svelte-pincode/pull/4/commits/040398e71c4f1de268504af497fb9dcad4cf24ff and it worked like a charm.
How are you testing it?

Really? Are you on iOS 14.6?
040398e works for me as long as you copy the code from the messages app manually, however fails, when using the autocomplete feature.
I sent messages from another phone (e.g. 1234 is your verification code).

I've applied the requested changes.

Released in v1.3.0


Cleaning netpar.cpp

@nrnhines : do you agree that removing #if NRNSTAT code is fine? I haven't used that for years and I think we are almost never (?) looked at those stats?

I have no objection to removing them. They are just counts and as such are available from NEURON.


unbound variable PORTS v1.1.0

I'm getting an error when trying to upgrade to v1.1.0:
/marathon-lb/run: line 6: PORTS: unbound variable
Am I missing something?

try passing an PORTS env to docker, normally marathon would do this i guess.

docker run -P -e "PORTS=10000" mesosphere/marathon-lb:v1.1.0 poll -m http://master.mesos:8080 --health-check --group external

currently you are going to run into #60 / #57 with the public docker images

As @pgraemer mentioned, if you use the built-in run script, you'll need to pass an env var that contains a comma separated list of the ports HAProxy binds to.

I'll add a more helpful error message for this.

@brndnmtthws,
Could explain the reasoning behind this? I would guess without any background information a sensible default would be 80,443,9090. Or docker inspect the HostPort's that are being mapped?

It's required for the firewall rules here: https://github.com/mesosphere/marathon-lb/blob/master/service/haproxy/run#L17-L21
For more background on why we do this, have a look here:

https://github.com/mesosphere/marathon-lb#zero-downtime-deployments
http://www.haproxy.org/download/1.6/doc/management.txt, under "4. Stopping and restarting HAProxy"
http://engineeringblog.yelp.com/2015/04/true-zero-downtime-haproxy-reloads.html

@brndnmtthws,
Awesome, really happy this change made it through. Thanks!
I still wonder if a default 80,443,9090 would make sense, but I leave that up to you. ;)

Sorry for the duplicate.
Does this mean you need to specify all the ports you want to use? Say for exemple I have 30 services running in marathon with randomly assigned ports, is there any way I can specify a range?

It's not strictly required, and you must list all the ports, or just one (if you want). See my comment here: https://github.com/mesosphere/marathon-lb/issues/59#issuecomment-182505469

It is really not convenient. I would like to be able to list the marathon default range, since I do not control the services that are deployed, the number of them and the ports they will use. If it's not required, how to bypass it?

You can supply your own script instead, or just specify any port.

Alright, I'll do it this way. Thanks for the clarification and the help!


JSONDecodeError while running First Example

Dear Zipline Maintainers,
Before I tell you about my issue, let me describe my environment:
My Environment is Python 3.5 with Windows-10 operating system.
When I try to run example "buyapple.py" from IPython Jupiter Notebook. I am getting following error ""

Operating System: (Windows Version or Windows-10)
Python Version: $ python --version 3.5
Python Bitness: $ python -c 'import math, sys;print(int(math.log(sys.maxsize + 1, 2) + 1))'
How did you install Zipline: (conda,conda install -c Quantopian zipline `)
Python packages: $ pip freeze or $ conda list

Now that you know a little about me, let me tell you about the issue I am
having:
#When I try to run example "buyapple.py" from IPython Jupiter Notebook. I am getting following error "JSONDecodeError "

It was expected to see a Plot of Symbol "AAPL for date range.
But I get error message as below
Here is how you can reproduce this issue on your machine:

Reproduction Steps

Use code `from zipline.api import order, record, symbol
from zipline.finance import commission, slippage
from zipline import run_algorithm

def initialize(context):
context.asset = symbol('AAPL')
# Explicitly set the commission/slippage to the "old" value until we can
# rebuild example data.
# github.com/quantopian/zipline/blob/master/tests/resources/
# rebuild_example_data#L105
context.set_commission(commission.PerShare(cost=.0075, min_trade_cost=1.0))
context.set_slippage(slippage.VolumeShareSlippage())

def handle_data(context, data):
order(context.asset, 10)
record(AAPL=data.current(context.asset, 'price'))
Note: this function can be removed if running
this algorithm on quantopian.com
def analyze(context=None, results=None):
import matplotlib.pyplot as plt
# Plot the portfolio and asset data.
ax1 = plt.subplot(211)
results.portfolio_value.plot(ax=ax1)
ax1.set_ylabel('Portfolio value (USD)')
ax2 = plt.subplot(212, sharex=ax1)
results.AAPL.plot(ax=ax2)
ax2.set_ylabel('AAPL price (USD)')
# Show the plot.
plt.gcf().set_size_inches(18, 8)
plt.show()

results= run_algorithm(start= '2019-1-1', end='2020-5-15', initialize=initialize, capital_base=100000, handle_data=handle_data, analyze=analyze)`
2. Set Quandl API Key and Ingest Data from Quandl
3. Run the cell with code
...
What steps have you taken to resolve this already?
I have tried to look for error on Github. But I did not find solution for this error.
Anything else?
...
Sincerely,
Chidambar Kulkarni

Hi @kulchidambar , I can't tell definitively without a traceback, but I think this is probably the same as https://github.com/quantopian/zipline/issues/2607. I'm going to close this in favor of https://github.com/quantopian/zipline/issues/2627 as well, but let us know if this is actually different.


Supporting other languages?

Is there a possibility that we can support other languages?
Reasons for supporting other languages:

Making the opening explorer more accessible for people who do not speak English.
creating a possibility for people to search for the opening in their native language, talking about openings to other people in the native language.
it looks better when there is only one language on a page

This is probably a big amount of work, especially with hundreds of lines of Openings, but some basic translations can probably be done for popular openings.

Do you think it would be feasible to split a name like
Hungarian Opening: Reversed Brooklyn Defense, Brooklyn Benko Gambit

into components like
Hungarian Opening
Reversed Brooklyn Defense
Brooklyn Benko Gambit

to avoid duplicated work, or will some languages naturally have special names for specific lines?
Is there any hope generalizing <name> Opening, <name> Gambit, etc.?

I think that splitting the opening names into the suggested components is a good idea. But I don't know if this generalization is possible in every language in every case. Sometimes the "Formation" could be called a "Variation" in a specific language. Also, some languages have different grammar. For example, in German the "King's Gambit" is written in one word as "Königsgambit". But perhaps the larger parts could be generalized, and exceptions could be handled separately.


Feature: Support Discord Authorization

Feature Description
Add support to allow login via Discord OAuth2 flow.
https://discord.com/developers/docs/topics/oauth2
Describe the solution you'd like
Utilize Discord as an identify provider.
Describe alternatives you've considered
None.
Additional context
None.

Thank you @foestauf for adding, soon will be adding support for this 👍


[rancher-compose] rancher-compose is missing a "pull" command like docker-compose

I could not figure out how to get rancher-compose to pull a new image that was checked into the registry (deploying a service to rancher hosts using rancher-compose up, the latest image was not being pulled from the registry), I had to manually login to the rancher host and "docker pull" there. docker-compose has "pull", is there any equivalent for docker-compose?

Working on it now.  Expect rancher-compose pull in the next release.

The following has been added

A new Cattle API at /v1/pullTask.  The input parameters are

image: The image name to pull
mode:  all to pull on all hosts that match the scheduling labels. or cached to pull on hosts that match the scheduling labels and already have the image.
labels: The scheduling labels

rancher-compose pull [--cached] [SERVICE...]

Pulls all the images that match the services using the labels from the compose file.  By default it will do mode all but --cached will do mode cached.

rancher-compose upgrade --pull ...

Added a --pull to upgrade which will do a pull mode=cached before doing the update

io.rancher.container.pull_image=always

If this label exists on a container at will always happen before the container is created on any host.

@sangeethah

Tested with build from master - Sep 18 and rancher-compose version - v0-4-0-rc2
Following options are now supported and functional:

rancher-compose pull [--cached] [SERVICE...]
rancher-compose upgrade --pull ...
io.rancher.container.pull_image=always

Issues seen when testing these options are tracked in different tickets.

Is there an example of this functionality for adding it within Rancher Server? I tried both
my-stack:
  image: my-registry.com:5000/foo/bar
  ports:
  - 8888:8888/tcp
  labels:
  - "io.rancher.container.pull_image=always"

and
my-stack:
  image: my-registry.com:5000/foo/bar
  ports:
  - 8888:8888/tcp
  labels:
    io.rancher.container.pull_image: always

in a docker-compose.yml but neither seem to actually pull the updated image. We have some docker containers being built out by Drone and pushed into our private registry but the devs can't pull their changes without logging into the machine currently. Are there any gotchas with this functionality?
Rancher	v0.43.1
Cattle	v0.106.0
User Interface	v0.63.0
Rancher Compose	v0.5.0

Have you checked rancher-compose -v to make sure you are running the right version of rancher-compose?
Also, the containers won't automatically restart with the new image. You'd need to do something to trigger so that new containers spin up. When new containers spin up, then the image would be pulled.


ollama.service cannot create folder defined by OLLAMA_MODELS or do not run when the folder is created manually

Hello
I'm facing an issue to locate the models into my home folder since my root partition is limited in size.
I followed the FAQ and information collected here and there to setup OLLAMA_MODELS in ollama.service.
When starting the service, the journal report that the server could not create the folder in my home directory.
Permission issue apparently.
This where i'm at, i couldn't find a way to fix it looking at various resources for systemd.
Can someone point me in the right direction ?
I'm using the package ollama-cuda on Arch.
[Unit]
Description=Ollama Service
Wants=network-online.target
After=network.target network-online.target

[Service]
ExecStart=/usr/bin/ollama serve
WorkingDirectory=/var/lib/ollama
Environment="HOME=/var/lib/ollama" "GIN_MODE=release" "OLLAMA_MODELS=/home/crystal/Applications/ollama_model"
User=ollama
Group=ollama
Restart=on-failure
RestartSec=3
Type=simple
PrivateTmp=yes
ProtectSystem=full
ProtectHome=yes

[Install]
WantedBy=multi-user.target

Feb 23 11:02:46 terrier systemd[1]: Started Ollama Service.
Feb 23 11:02:46 terrier ollama[37688]: Error: mkdir /home/crystal: permission denied
Feb 23 11:02:46 terrier systemd[1]: ollama.service: Main process exited, code=exited, status=1/FAILURE
Feb 23 11:02:46 terrier systemd[1]: ollama.service: Failed with result 'exit-code'.```

I tried also other things.
Modify ollama.service with my user/group:
User=crystal
Group=crystal

and add my user name to ollama group and run with:
User=crystal
Group=ollama

None work (no folder created), although the journal message is different now:
Feb 23 11:41:19 terrier systemd[1]: ollama.service: Main process exited, code=exited, status=1/FAILURE
Feb 23 11:41:19 terrier systemd[1]: ollama.service: Failed with result 'exit-code'.

Try this out
Change OLLAMA_MODELS Path
Steps:

Create Directory: sudo mkdir /usr/local/share/ollama-models
Grant Ownership: sudo chown ollama:ollama /usr/local/share/ollama-models
Update Service File: Edit the /etc/systemd/system/ollama.service file and modify:
-- Environment="OLLAMA_MODELS=/usr/local/share/ollama-models"
Restart Ollama: sudo systemctl restart ollama

@seanmavley
Thanks.
Since my goal is have the models located in the home folder (no space left in / ) i have adapted what you proposed.
I created manually /home/crystal/Applications/ollama_model and subsequently added sudo chown ollama:ollama, and kept in ollama.service:
User=ollama
Group=ollama

Still same error the server doesn't start:
Feb 23 11:58:22 terrier systemd[1]: ollama.service: Main process exited, code=exited, status=1/FAILURE
Feb 23 11:58:22 terrier systemd[1]: ollama.service: Failed with result 'exit-code'.

To note when using from the shell:
export OLLAMA_MODELS=/home/crystal/Applications/ollama_model
ollama serve

The server start without issue and models are correctly downloaded in the home/crystal/Applications/ollama_model.
Looks like the issue is related to starting the server through systemd.

Ditto this problem on Ubuntu. The workaround to export and serve works.

The issue is ProtectHome=yes, systemctl edit ollama and create an override:
[Service]
ProtectHome=

This is a hack and you shouldn't do it, and you SHOULD NOT try to give it access to your own user, create a new home directory for it.

my goal is to have the models located in the home folder (no storage space left in / )

So you split / and /home and now you ran out of space?
Consider if you really need them split in the first place

I will add that I'm so glad I finally found THIS issue with a working solve for ubuntu .
my models are in a zfs pool at /pool/models
so protect home wasn't my issue

@Crystal4276 It looks like you're trying to store the models in your user directory "/home/crystal/..."
I was trying to do the same thing and it just wouldn't work. I think it has something to do with ollama not having permission to access a user's directory.
What I did to get it working was create a directory in the /home directory: mkdir ollama_models
Give ollama ownership: sudo chown -R ollama:ollama ollama_models
And then edit the ollama.service file: sudo systemctl edit ollama.service
I added the following above the third line (the one that says "Lines below this comment will be discarde":
[Service]
Environment="OLLAMA_MODELS=/home/ollama_models"

Then I reloaded systemd and restarted ollama:
sudo systemctl daemon-reload
sudo systemctl restart ollama

This sometimes hangs the system for awhile (less than 30s for me), but be patient.
To check that it worked I gave the command to list models:
ollama list
If everything worked, it might hang for a while, but just be patient (could be > 1 min).
Then, you'll get output that looks like:
NAME         ID   SIZE   MODIFIED
If you see that, everything worked! Now, just copy the contents of the old models directory to your new one.
Good luck!

@John-OK The critical part for was giving ollama ownership of the models directory.  I did the create from a completely different directory (for convenience) and that permission change was all that was needed,


Add precompile statements back in

Try precompiling core methods.

We don't need this anymore, due to #36.


Replace deprecated lock_table with dynamodb_table

This reflects a deprecation in Terraform 0.9.7 (changelog), and gets rid of the annoying deprecation message I was seeing.

Merging by fiat, as Travis isn't going to tell us anything useful about this.


Changing the Edit page

In the section "Update the Edit Page," I assume we are editing Pages/Students/Edit.cshtml.cs but my page is very different from the one in the tutorial.  Here is the code I find in OnPostAsync so I am confused as to how to proceed:
public async Task<IActionResult> OnPostAsync()
        {
            if (!ModelState.IsValid)
            {
                return Page();
            }

            _context.Attach(Student).State = EntityState.Modified;

            try
            {
                await _context.SaveChangesAsync();
            }
            catch (DbUpdateConcurrencyException)
            {
                if (!StudentExists(Student.ID))
                {
                    return NotFound();
                }
                else
                {
                    throw;
                }
            }

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 8f592059-3328-88a8-5c6c-43121ac8a0a5
Version Independent ID: f8a63abf-824b-5b80-e03d-abcb2c162b95
Content: Razor Pages with EF Core in ASP.NET Core - CRUD - 2 of 8
Content Source: aspnetcore/data/ef-rp/crud.md
Product: aspnet-core
GitHub Login: @Rick-Anderson
Microsoft Alias: riande

@LouBH 	 looks like you're right - it needs more highlighting. The changes are similar to those you made previously in the create page.
Use the code provided. We'll fix this in the next update.

This is the merge I ended up with combining the two. You do need to drop the _context.Attach(Student)
public async Task OnPostAsync(int? id)
{
if (!ModelState.IsValid)
{
return Page();
}
        var studentToUpdate = await _context.Students.FindAsync(id);

        if(await TryUpdateModelAsync<Student>(
            studentToUpdate,
            "Student",
            s => s.FirstMidName, s => s.LastName, s => s.EnrollmentDate))
        {
            try
            {
                await _context.SaveChangesAsync();
            }
            catch (DbUpdateConcurrencyException)
            {
                if (StudentExists(Student.ID))
                {
                    throw;
                }

            }

            return RedirectToPage("./Index");
        }

        return Page();
    }


[Feature] Melt function implementation

What do these changes do?
Implementation of pandas.DataFrame.melt + apply_full_axis_select_indices optimization.

[x] passes flake8 modin
[x] passes black --check modin
[x] signed commit with git commit -s
[x] Resolves #1205
[x] tests added and passing

@devin-petersohn Thanks for your comments, definitely first implementation were extremely slow because of inserting column with numpy array and sorting indices via sort_index. Now for restoring pandas-order of output it uses modin_frame.reorder_labels, but it's still slower than pandas:
500000x45 ~ 74Mb Dataset

Pandas: 1.0365909719839692
Modin: 4.968821498565376

time of execution reorder_labels inside
modin melt implementation: 4.164067830890417

As we see from the results, native modin frame function reorder_labels is a bottleneck here.
Here is the results without restoring pandas-order:
500000x45 ~ 74Mb Dataset

Pandas: 1.0422626351937652
Modin: 0.5023592244833708

How it was measured
import numpy as np
import string
import csv
import os
from timeit import default_timer as timer

IS_PANDAS = True
RAND_LOW = -100
RAND_HIGH = 100
N = 500000
M = 45
TEST_FILENAME = os.path.abspath(f"int_dataset-{N},{M},{RAND_LOW},{RAND_HIGH}.csv")

def generate_data_file(filename, row_n, col_n):
    letters = list(string.ascii_letters)
    columns = [
        "".join(np.random.choice(letters) for _ in np.arange(10))
        for _ in np.arange(col_n)
    ]

    with open(filename, "w") as file:
        writer = csv.writer(file, delimiter=",")
        writer.writerow(columns)
        for _ in np.arange(row_n):
            writer.writerow(np.random.randint(RAND_LOW, RAND_HIGH, col_n))

if __name__ == "__main__":
    import pandas
    import modin.pandas as pd

    if not os.path.exists(TEST_FILENAME):
        generate_data_file(TEST_FILENAME, N, M)

    if IS_PANDAS:
        pd_df = pandas.read_csv(TEST_FILENAME)
        t1_pd = timer()
        pd_df.melt()
        t2_pd = timer()

        print("Pandas:", t2_pd - t1_pd)

    md_df = pd.read_csv(TEST_FILENAME)
    t1_md = timer()
    md_df.melt()
    t2_md = timer()

    print("Modin:", t2_md - t1_md)

What is restoring pandas-order?
For applying melt function we must get information about full row axis, so it's implemented via modin_frame._apply_full_axis(1, lambda df: df.melt()) and because function applied only for row partitions, we would get a different order of rows as the result.
For example we have DataFrame splitter into row partitions like that:
   first     last  weight  height
0   John    Smith     5.0     130
1   Mary  Johnson     6.0     140
----------------------------------
2    Bob    Jones     5.5     150
3  Andry    Brown     4.2     160

and then we will apply melt(id_vars=["first", "last"])
Result of applying			Result of applying
for row partitions:			for the whole dataframe:

   first     last variable  value	   first     last variable  value
0   John    Smith   weight    5.0	0   John    Smith   weight    5.0
1   Mary  Johnson   weight    6.0	1   Mary  Johnson   weight    6.0
2   John    Smith   height  130.0	2    Bob    Jones   weight    5.5
3   Mary  Johnson   height  140.0	3  Andry    Brown   weight    4.2
---------------------------------
0    Bob    Jones   weight    5.5	4   John    Smith   height  130.0
1  Andry    Brown   weight    4.2	5   Mary  Johnson   height  140.0
2    Bob    Jones   height  150.0	6    Bob    Jones   height  150.0
3  Andry    Brown   height  160.0	7  Andry    Brown   height  160.0

Restoring order from right result in left result is what I mean under restoring pandas-order

Restoring order is the most expensive operation because we must have knowledge about the whole column axis, which is the longest one in case of melt output, so the reordering will take longer that melt itself.
So, @devin-petersohn is it acceptable for modin to output shuffled data in such functions or modin has a pattern for fast reordering which I'm don't know?

@dchigarev maybe you can found some useful things in #725

@devin-petersohn I've reimplemented melt via apply_full_axis_select_indices and got this results
45x500000 (5 values in a different partitions)
Pandas: 0.1547
Modin (8 cores): 0.1028
Modin (112 cores): 0.0514
Modin default_to_pandas: 2.0192

45x500000 (all values)
Pandas: 0.4206
Modin (8 cores): 0.9479
Modin (112 cores): 0.8355
Modin default_to_pandas: 3.3246

I've also fixed a strange bug in apply_func_to_select_indices_along_full_axis, without this fix I was getting the same times when applying melt function for only one column partition and for the whole column partitions. Does cls.column_partitions() do any hard work if we don't apply a function to that column partition? If yes, then for me it's not obvious and I guess it should be mentioned in documentation.

@dchigarev Yes, if there is no work being done, the column partition is still shuffled together to the same worker, which is some significant work.
Thanks for running the performance numbers on this. Is there a reason this cannot be done by applying the function to row partitions instead of column partitions?

@devin-petersohn It could be implemented via applying to row partitions, but there is a two details:

melt is designed to transform dataframe from wide to long format, since we have wide dataframe with short columns it will be more scalable if we'll apply function to column partitions, not to rows
Applying melt to rows leads to losing correct rows order in the result, that problem was described in that comment. So we will have to do slow reordering. Unfortunately, I still have no idea how to do it fast with the current modin_frame API

Applying melt to rows leads to losing correct rows order in the result, that problem was described in that comment. So we will have to do slow reordering. Unfortunately, I still have no idea how to do it fast with the current modin_frame API

Ah, I forgot about that, sorry. The reordering rows can happen via sort, which isn't implemented scalably yet, but should be soon. It is okay to rely on functionality that isn't implemented yet. We could also perform the sort first, which would probably perform better. What do you think about this?

@devin-petersohn what do you mean under "perform the sort first"? The problem is that after applying melt rows are sorted correctly, but only for every independent partition, so it requires some kind of merge phase to sort it globally. Also as you can see in the example above, rows sorted not in alphabetic order, but in the order when they were columns, will it be possible to pass a custom order function with the new implemented sort?
And another question, I don't know how data scientists use melt, but in my suggestions, it is transforming wide and short dataframes to a long format (correct me if I'm wrong), so in that case, applying to columns will be more efficient?

@dchigarev It will scale better if operations are performed across the columns axis=1. We can throw a Warning that mentions that the order may not match pandas exactly for a first pass so that we do not pay the heavy penalty for reordering the rows. Please create an issue for the ordering of the rows in melt implementation so we can fix it later.

@devin-petersohn I've reimplemented melt with applying function to selected indices + broadcasting columns from id_vars to every partition. This is the results:
500000x128 (all values)
Pandas: 2.9566
Modin (8 cores): 0.6220
Modin (112 cores): 0.5468

500000x128 (5 values in a different partitions)
Pandas: 0.1019
Modin (8 cores): 0.0893
Modin (112 cores): 0.3803 (re-runed many times, but still getting
                                 that weird result for 112 cores)

Also added a warning of incorrect order of rows and created an issue, to we could fix this later (#1793)

Thanks @dchigarev! Were those times including a print statement to ensure computation was finished?

@devin-petersohn It's shamable, but it seems that I forgot to add repr to the result to force materialization in my measurement script, so all measurements above are not relevant. Time measurements with repr are not so magical:
Pandas: 2.9670
Modin (8 cores): 1.5371
Modin (112 cores): 1.1135

@dchigarev 500,000 rows is not very many, so that speedup is quite good, especially on 128 columns.

@dchigarev The implementation looks good, I have retriggered GitHub Actions because it showed a -40% coverage drop.

@devin-petersohn now codecov check is okay, I guess


A11 iPhone 8 Plus Misaka freezes and close itself while kopen KFD iOS 16.5 3.2.5-3.3.1

Dear straight-tamago,
on my iP8+ Misaka always crashes while trying to kopen with KFD.
It does not matter if it trys to kopen directly after open the application, or from the settings panel in the app.
I´ve tried to play around with the exploit settings. Changing puaf pages, puaf metho and kwrite/kread. I´ve have also tried different versions. 3.2.5-3.3.1. I´ve restarted the device a lot of times.
Do you have any suggestion for me?
Sincerely
Phillip Goik

Dear straight-tamago,
on my iP8+ Misaka always crashes while trying to kopen with KFD. It does not matter if it trys to kopen directly after open the application, or from the settings panel in the app. I´ve tried to play around with the exploit settings. Changing puaf pages, puaf metho and kwrite/kread. I´ve have also tried different versions. 3.2.5-3.3.1. I´ve restarted the device a lot of times.
Do you have any suggestion for me?
Sincerely Phillip Goik

me to i can’t get it to work only crashes when trying to open koppen will there be  may suport near future?


first attempt to have compatibility with EllipsisNotation.jl, cf. #39

There is a method ambiguity
  MethodError: getindex(::HybridArray{Tuple{2,StaticArrays.Dynamic()},Float64,2,2,Array{Float64,2}}, ::EllipsisNotation.Ellipsis) is ambiguous. Candidates:
    getindex(A::AbstractArray, ::EllipsisNotation.Ellipsis) in EllipsisNotation at EllipsisNotation/XpBpL/src/EllipsisNotation.jl:58
    getindex(sa::HybridArray{S,T,N,M,TData} where TData<:AbstractArray{T,M} where M where N where T, inds...) where S in HybridArrays at HybridArrays/src/indexing.jl:14
  Possible fix, define
    getindex(::HybridArray{S,T,N,M,TData} where TData<:AbstractArray{T,M} where M where N where T, ::EllipsisNotation.Ellipsis) where S

since EllipsisNotation.jl defines
# avoid copying if indexing with .. alone, see
# https://github.com/JuliaDiffEq/OrdinaryDiffEq.jl/issues/214
Base.getindex(A::AbstractArray, ::Ellipsis) = A

This can be fixed by removing the current definition
# general fallback allowing, e.g. `..` from EllipsisNotation.jl
Base.@propagate_inbounds function getindex(sa::HybridArray{S}, inds...) where S
    getindex(sa, to_indices(sa, inds)...)
end

in HybridArrays/src/indexing.jl:14. If we do that, we don't catch something like u_hybrid[1, ..] anymore, meaning that this will result in an Array instead of a HybridArray (as it is for u_hybrid[1, :]). My best guess is that it would be good to look how something like OffsetArrays.jl deals with this situation (since they work with EllipsisNotation and return an OffsetArray appropriately).
I think the basic reason for this is that HybridArrays.jl interrupts directly at the level of getindex(::HybridArray, inds...) in general, circumventing the mechanisms of to_indices etc. from Base. I somehow get the impression that this can't be the best approach since we run into this issue. Something like writing a method
_unsafe_getindex(::IndexLinear{…},::HybridArray{…},::Int64{…},::Base.Slice{…})

does not seem to be the right approach either. Since I'm not an expert on HybbridArrays.jl, I don't really know how to proceed further from here. I could try something but I thought it might be better to share my experience so far and let also others have a look. I'm definitely willing to invest some more work into this, but it will probably be best if others have a look, too.
When we get this correct, it will fix #39.

This is a great topic. I wrote most of HybridArrays when I didn't know as much about indexing as I do now, and there is still a lot that I don't know. First thing I'd like to clear here, do you think EllipsisNotation works right with StaticArrays? StaticArrays indexing should be closer to HybridArrays than OffsetArrays.jl. I just tried that:
julia> a = @SMatrix randn(3,3)
3×3 SArray{Tuple{3,3},Float64,2,9} with indices SOneTo(3)×SOneTo(3):
  0.321819   1.30703    0.165836
 -0.433719  -0.403508   2.25181
  0.404721  -0.568728  -0.282213

julia> a[1,..]
3-element MArray{Tuple{3},Float64,1,3} with indices SOneTo(3):
 0.3218188726238625
 1.307030516467493
 0.16583612823771224

and I get MArray instead of SArray. Note that StaticArrays also partially circumvents to_indices: https://github.com/JuliaArrays/StaticArrays.jl/blob/59f92e0ca7ac391a850a6e7a2ce1eb53aa237fc4/src/indexing.jl#L225 .

You're right, StaticArrays.jl and EllipsisNotation do also not work together as they should, since
julia> using Pkg; Pkg.activate(temp=true); Pkg.add(["EllipsisNotation", "HybridArrays", "StaticArrays"]); using EllipsisNotation, HybridArrays, StaticArrays
[...]
  [da5c29d0] + EllipsisNotation v1.0.0
  [1baab800] + HybridArrays v0.4.4
  [90137ffa] + StaticArrays v1.0.1
[...]

julia> a = @SMatrix randn(3,3)
3×3 SArray{Tuple{3,3},Float64,2,9} with indices SOneTo(3)×SOneTo(3):
  1.2857    1.52985    1.49314
 -0.814121  1.67052   -0.0925791
 -0.230291  0.848189   0.934648

julia> a[1, :] # gives an SArray
3-element SArray{Tuple{3},Float64,1,3} with indices SOneTo(3):
 1.2857007082151861
 1.5298533524538094
 1.4931356369002144

julia> a[1, ..] # gives an MArray
3-element MArray{Tuple{3},Float64,1,3} with indices SOneTo(3):
 1.2857007082151861
 1.5298533524538094
 1.4931356369002144

However, it seems to work at least (in the sense of throwing no error). Continuing the example above,
julia> view(a, 1, :)
3-element view(::SArray{Tuple{3,3},Float64,2,9}, 1, :) with eltype Float64 with indices SOneTo(3):
 1.2857007082151861
 1.5298533524538094
 1.4931356369002144

julia> view(a, 1, ..)
3-element view(::SArray{Tuple{3,3},Float64,2,9}, 1, :) with eltype Float64 with indices SOneTo(3):
 1.2857007082151861
 1.5298533524538094
 1.4931356369002144

julia> b = HybridArray{Tuple{3, 3}}(rand(3, 3))
3×3 HybridArray{Tuple{3,3},Float64,2,2,Array{Float64,2}} with indices SOneTo(3)×SOneTo(3):
 0.038654  0.706119  0.151672
 0.530268  0.806502  0.835772
 0.280619  0.915615  0.179368

julia> view(b, 1, :)
3-element SizedArray{Tuple{3},Float64,1,1,SubArray{Float64,1,HybridArray{Tuple{3,3},Float64,2,2,Array{Float64,2}},Tuple{Int64,Base.Slice{SOneTo{3}}},true}} with indices SOneTo(3):
 0.03865400819804554
 0.7061190888149158
 0.1516722054538031

julia> view(b, 1, ..)
ERROR: MethodError: no method matching all_dynamic_fixed_val(::Type{Tuple{3,3}}, ::Int64, ::EllipsisNotation.Ellipsis)
Closest candidates are:
  all_dynamic_fixed_val(::Type{Size}, ::Union{Colon, Int64, AbstractArray}...) where Size<:Tuple at /home/hendrik/.julia/packages/HybridArrays/GeLeK/src/HybridArrays.jl:52
  all_dynamic_fixed_val(::Type{Size}) where Size<:Tuple at /home/hendrik/.julia/packages/HybridArrays/GeLeK/src/HybridArrays.jl:44
  all_dynamic_fixed_val(::Type{Size}, ::StaticArrays.StaticIndexing{var"#s14"} where var"#s14"<:Union{Colon, Int64, AbstractArray}...) where Size<:Tuple at /home/hendrik/.julia/packages/HybridArrays/GeLeK/src/HybridArrays.jl:48
Stacktrace:
 [1] view(::HybridArray{Tuple{3,3},Float64,2,2,Array{Float64,2}}, ::Int64, ::EllipsisNotation.Ellipsis) at /home/hendrik/.julia/packages/HybridArrays/GeLeK/src/indexing.jl:304
 [2] top-level scope at REPL[32]:1

I'm not an expert on every detail of indexing in Julia either, but I think it would be good to provide some working fallback methods such that something like the view above works. We would really like to use this to speed up some computations.

Maybe another approach would be to use the same tactic as StaticArrays and just fall back to base methods for something not recognized by HybridArrays, i.e. to restrict new getindex, view etc. methods to known index types? For example, https://github.com/mateuszbaran/HybridArrays.jl/blob/1550dab049279d0e3a1d5e97a634b1905907c3ca/src/indexing.jl#L299-L305 could become
@inline function Base.view(
     a::HybridArray{S},
     indices::Union{Colon, Int, AbstractArray}...,
 ) where {S}
     inner_view = invoke(view, Tuple{AbstractArray, typeof(indices).parameters...}, a, indices...)
     return _view_hybrid(a, all_dynamic_fixed_val(S, indices...), inner_view, indices...)
 end

I would also argue that the problem lies more on the side of EllipsisNotation, since
julia> a = @SArray rand(2,3,4);

julia> a[:, CartesianIndex(1, 2)]
2-element MArray{Tuple{2},Float64,1,2} with indices SOneTo(2):
 0.2986268295107888
 0.9195744224253837

julia> view(a, :, CartesianIndex(1, 2))
2-element view(::SArray{Tuple{2,3,4},Float64,3,24}, :, 1, 2) with eltype Float64 with indices SOneTo(2):
 0.2986268295107888
 0.9195744224253837
julia> b = HybridArray{Tuple{2, 3, 4}}(rand(2, 3, 4));

julia> b[:, CartesianIndex(1, 2)]
2-element HybridArray{Tuple{2},Float64,1,1,Array{Float64,1}} with indices SOneTo(2):
 0.5847068898984851
 0.8900340411185412

julia> view(b, :, CartesianIndex(1, 2))
ERROR: MethodError: no method matching all_dynamic_fixed_val(::Type{Tuple{2,3,4}}, ::Colon, ::CartesianIndex{2})
Closest candidates are:
  all_dynamic_fixed_val(::Type{Size}, ::Union{Colon, Int64, AbstractArray}...) where Size<:Tuple at HybridArrays/GeLeK/src/HybridArrays.jl:52
  all_dynamic_fixed_val(::Type{Size}) where Size<:Tuple at HybridArrays/GeLeK/src/HybridArrays.jl:44
  all_dynamic_fixed_val(::Type{Size}, ::StaticArrays.StaticIndexing{var"#s14"} where var"#s14"<:Union{Colon, Int64, AbstractArray}...) where Size<:Tuple at HybridArrays/GeLeK/src/HybridArrays.jl:48
Stacktrace:
 [1] view(::HybridArray{Tuple{2,3,4},Float64,3,3,Array{Float64,3}}, ::Function, ::CartesianIndex{2}) at HybridArrays/GeLeK/src/indexing.jl:304
 [2] top-level scope at REPL[12]:1

I implemented the idea described in https://github.com/mateuszbaran/HybridArrays.jl/pull/41#issuecomment-774978010 and added new tests for Cartesian indices. Now, views should work at least with various index types but they will fall back to generic methods from Base, similar to StaticArrays.

I think this is a good hotfix for this problem. Next, we probably need to overload Base._getindex since it's called after to_indices, with some methods that would return something better than the default.
We can discuss it either here or on Discourse, your choice :slightly_smiling_face: .
Could you bump the patch version so I can merge & tag this?

Could you bump the patch version so I can merge & tag this?

Sure :+1:

Next, we probably need to overload Base._getindex since it's called after to_indices, with some methods that would return something better than the default.
We can discuss it either here or on Discourse, your choice.

Both is fine for me, but I guess creating a thread on Discourse might attract more people from outside who are also involved in indexing, say in Base and StaticArrays.


fsencode TypeError when running forge iOS lru-dict

Describe the bug
There is an issue when mobile-forge install steps are followed. Issue is happening when forging for any target.
env_list.append(k + b'=' + os.fsencode(v))                                ^^^^^^^^^^^^^^   File "<frozen os>", line 812, in fsencode TypeError: expected str, bytes or os.PathLike object, not NoneType
Steps to reproduce

Use the Python-Apple-Support branch 3.11
Follow the instructions in readme of mobile-forge
System is M1 MacBook Air

Expected behavior
Corresponding wheel is generated
Screenshots
No response
Environment

Operating System: Mac OS Sonoma Version 14.3.1 (23D60)
Device: M1 MacBook Air
Python version: 3.11.6
Software versions:

Python-Apple-Support: branch 3.11
Mobile-Forge: Latest Main Branch

Logs

(venv3.11) noelmullankuzhy@Noels-MacBook-Air mobile-forge % forge iphonesimulator:12.0:arm64 lru-dict
Building lru-dict 1.1.8 for ios_12_0_iphonesimulator_arm64

[venv3.11-ios_12_0_iphonesimulator_arm64] Clean up old builds
Removing build/cp311/lru-dict/1.1.8...

[venv3.11-ios_12_0_iphonesimulator_arm64] Unpack sources
Unpacking downloads/lru-dict-1.1.8.tar.gz...

[venv3.11-ios_12_0_iphonesimulator_arm64] Apply patches
No patches to apply.

[venv3.11-ios_12_0_iphonesimulator_arm64] Create clean build environment
Creating venv3.11-ios_12_0_iphonesimulator_arm64...

Verifying cross-platform environment...
done.

Cross platform-environment venv3.11-ios_12_0_iphonesimulator_arm64 created.

[venv3.11-ios_12_0_iphonesimulator_arm64] Install forge host requirements
No host requirements.

[venv3.11-ios_12_0_iphonesimulator_arm64] Install forge build requirements
No build requirements.

[venv3.11-ios_12_0_iphonesimulator_arm64] Installing non-PEP517 build requirements

Requirement already satisfied: setuptools in ./build/cp311/lru-dict/1.1.8/venv3.11-ios_12_0_iphonesimulator_arm64/venv3.11-ios_12_0_iphonesimulator_arm64/lib/python3.11/site-packages (65.5.0)
Collecting setuptools
Obtaining dependency information for setuptools from https://files.pythonhosted.org/packages/c0/7a/3da654f49c95d0cc6e9549a855b5818e66a917e852ec608e77550c8dc08b/setuptools-69.1.1-py3-none-any.whl.metadata
Using cached setuptools-69.1.1-py3-none-any.whl.metadata (6.2 kB)
Using cached setuptools-69.1.1-py3-none-any.whl (819 kB)
Installing collected packages: setuptools
Attempting uninstall: setuptools
Found existing installation: setuptools 65.5.0
Uninstalling setuptools-65.5.0:
Successfully uninstalled setuptools-65.5.0
Successfully installed setuptools-69.1.1

Collecting build
Obtaining dependency information for build from https://files.pythonhosted.org/packages/4f/81/4849059526d02fcc9708e19346dd740e8b9edd2f0675ea7c38302d6729df/build-1.1.1-py3-none-any.whl.metadata
Using cached build-1.1.1-py3-none-any.whl.metadata (4.2 kB)
Collecting wheel
Obtaining dependency information for wheel from https://files.pythonhosted.org/packages/7d/cd/d7460c9a869b16c3dd4e1e403cce337df165368c71d6af229a74699622ce/wheel-0.43.0-py3-none-any.whl.metadata
Using cached wheel-0.43.0-py3-none-any.whl.metadata (2.2 kB)
Collecting packaging>=19.0 (from build)
Obtaining dependency information for packaging>=19.0 from https://files.pythonhosted.org/packages/49/df/1fceb2f8900f8639e278b056416d49134fb8d84c5942ffaa01ad34782422/packaging-24.0-py3-none-any.whl.metadata
Using cached packaging-24.0-py3-none-any.whl.metadata (3.2 kB)
Collecting pyproject_hooks (from build)
Obtaining dependency information for pyproject_hooks from https://files.pythonhosted.org/packages/d5/ea/9ae603de7fbb3df820b23a70f6aff92bf8c7770043254ad8d2dc9d6bcba4/pyproject_hooks-1.0.0-py3-none-any.whl.metadata
Using cached pyproject_hooks-1.0.0-py3-none-any.whl.metadata (1.3 kB)
Using cached build-1.1.1-py3-none-any.whl (19 kB)
Using cached wheel-0.43.0-py3-none-any.whl (65 kB)
Using cached packaging-24.0-py3-none-any.whl (53 kB)
Using cached pyproject_hooks-1.0.0-py3-none-any.whl (9.3 kB)
Installing collected packages: wheel, pyproject_hooks, packaging, build
Successfully installed build-1.1.1 packaging-24.0 pyproject_hooks-1.0.0 wheel-0.43.0

Requirement already satisfied: setuptools in ./build/cp311/lru-dict/1.1.8/venv3.11-ios_12_0_iphonesimulator_arm64/build/lib/python3.11/site-packages (65.5.0)
Collecting setuptools
Obtaining dependency information for setuptools from https://files.pythonhosted.org/packages/c0/7a/3da654f49c95d0cc6e9549a855b5818e66a917e852ec608e77550c8dc08b/setuptools-69.1.1-py3-none-any.whl.metadata
Using cached setuptools-69.1.1-py3-none-any.whl.metadata (6.2 kB)
Using cached setuptools-69.1.1-py3-none-any.whl (819 kB)
Installing collected packages: setuptools
Attempting uninstall: setuptools
Found existing installation: setuptools 65.5.0
Uninstalling setuptools-65.5.0:
Successfully uninstalled setuptools-65.5.0
Successfully installed setuptools-69.1.1

Collecting build
Obtaining dependency information for build from https://files.pythonhosted.org/packages/4f/81/4849059526d02fcc9708e19346dd740e8b9edd2f0675ea7c38302d6729df/build-1.1.1-py3-none-any.whl.metadata
Using cached build-1.1.1-py3-none-any.whl.metadata (4.2 kB)
Collecting wheel
Obtaining dependency information for wheel from https://files.pythonhosted.org/packages/7d/cd/d7460c9a869b16c3dd4e1e403cce337df165368c71d6af229a74699622ce/wheel-0.43.0-py3-none-any.whl.metadata
Using cached wheel-0.43.0-py3-none-any.whl.metadata (2.2 kB)
Collecting packaging>=19.0 (from build)
Obtaining dependency information for packaging>=19.0 from https://files.pythonhosted.org/packages/49/df/1fceb2f8900f8639e278b056416d49134fb8d84c5942ffaa01ad34782422/packaging-24.0-py3-none-any.whl.metadata
Using cached packaging-24.0-py3-none-any.whl.metadata (3.2 kB)
Collecting pyproject_hooks (from build)
Obtaining dependency information for pyproject_hooks from https://files.pythonhosted.org/packages/d5/ea/9ae603de7fbb3df820b23a70f6aff92bf8c7770043254ad8d2dc9d6bcba4/pyproject_hooks-1.0.0-py3-none-any.whl.metadata
Using cached pyproject_hooks-1.0.0-py3-none-any.whl.metadata (1.3 kB)
Using cached build-1.1.1-py3-none-any.whl (19 kB)
Using cached wheel-0.43.0-py3-none-any.whl (65 kB)
Using cached packaging-24.0-py3-none-any.whl (53 kB)
Using cached pyproject_hooks-1.0.0-py3-none-any.whl (9.3 kB)
Installing collected packages: wheel, pyproject_hooks, packaging, build
Successfully installed build-1.1.1 packaging-24.0 pyproject_hooks-1.0.0 wheel-0.43.0

********************************************************************************
Failed build: lru-dict 1.1.8 for iphonesimulator 12.0 on arm64
********************************************************************************
Traceback (most recent call last):
  File "/Users/noelmullankuzhy/Tools/mobile-forge/src/forge/build.py", line 267, in build
    self._build()
  File "/Users/noelmullankuzhy/Tools/mobile-forge/src/forge/build.py", line 510, in _build
    self.cross_venv.run(
  File "/Users/noelmullankuzhy/Tools/mobile-forge/src/forge/cross.py", line 356, in run
    return subprocess.run(logfile, *args, **self.cross_kwargs(kwargs))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/noelmullankuzhy/Tools/mobile-forge/src/forge/subprocess.py", line 39, in run
    with stdlib_subprocess.Popen(*args, **kwargs) as process:
         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/noelmullankuzhy/Tools/Python-Apple-support/install/macOS/macosx/python-3.11.6/lib/python3.11/subprocess.py", line 1030, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/Users/noelmullankuzhy/Tools/Python-Apple-support/install/macOS/macosx/python-3.11.6/lib/python3.11/subprocess.py", line 1874, in _execute_child
    env_list.append(k + b'=' + os.fsencode(v))
                               ^^^^^^^^^^^^^^
  File "<frozen os>", line 812, in fsencode
TypeError: expected str, bytes or os.PathLike object, not NoneType

Failed builds for:
 * lru-dict (default version) (ios_12_0_iphonesimulator_arm64)

(venv3.11) noelmullankuzhy@Noels-MacBook-Air mobile-forge %

Additional context
No response

Thanks for the report; unfortunately, I can't reproduce what you're seeing - a clean 3.11 build of lru-dict for iOS simulator arm64 completes successfully.
I suspect the problem might be something I've assumed about the build environment; the error would be consistent with a None value being passed in as an argument to a build call. Can I ask you to share the log file that was generated in errors for this build? That might give a hint as to where things have gone wrong.

Here are the log files.
lru-dict-1.1.8-cp311-ios_12_0_iphoneos_arm64.log
lru-dict-1.1.8-cp311-ios_12_0_iphonesimulator_arm64.log
lru-dict-1.1.8-cp311-ios_12_0_iphonesimulator_x86_64.log

As I suspected, the issue is an assumption about the build environment. The compiler environment is copying over some "useful default" values for HOME, TMPDIR, and a couple of other variables - but if those aren't present in the user's environment, they're passed in as None, which causes the error you're seeing. The problem value in this case is LANG - I thought that it was safe to assume that was set, but apparently not.
I've corrected this in #38. Thanks for the report, and apologies for the inconvenience.


Simple Gemfile causes "bundle update" to never finish

When running bundle update with the following Gemfile, the command never completes.  It runs with "Resolving dependencies" forever.  This happens on new installations using RVM for MRI and JRuby.
source 'https://rubygems.org/'

gem 'rails', '<4.2.0'
gem 'actionpack-page_caching'
gem 'simple_workflow'

@donv what version of bundler is this with?

Hm, the issue here seems to be with a combo of attempt_to_swap and our sorting heuristic...

@Who828 what do you think of using dependency.requirements_list.size as part of the sort?

@segiddins  This is with bundler 1.9.6.

I left it going for a while and with the simple Gemfile it actually finished in the end:
real	0m46.411s
user	1m10.831s
sys	0m1.680s

That is with all the gems already installed before running the command.

Yup, I think I have an optimization in mind that may help this pathological case.


How can I convert a VOC style data base into a COCO style database

Hello Ethan!
Can you expand? Are you trying to get those datasets in a format that can be ingested by Luminoth? For that, you must transform the dataset into TFrecords format. You can read this page in the docs for how to do that.

Thanks for the reply,
I ran this
lumi dataset transform \         --type pascal \         --data-dir DataOut \         --output-dir datasets/pascal/tf/ \         --split train --split val
and I get this
File "/home/parallels/.virtualenvs/cv/lib/python3.5/site-packages/luminoth/tools/dataset/readers/object_detection/pascalvoc.py", line 46, in _validate_structure     raise InvalidDataDirectory('Labels path is missing') luminoth.tools.dataset.readers.base_reader.InvalidDataDirectory: Labels path is missing
I am using a custom data set, but it should be in the format of Pascal Voc. Do you know what is going on?

This error is when it cannot find ImageSets/Main folder. Are you sure your dataset is in the exact same format as expected from Pascal VOC?:
ImageSets/Main
JPEGImages
Annotations

Sorry,
I'm still pretty new to this
I'm not 100% sure. My database goes images/image1.jpg
Can I use what I have?

Hi @EthanReid!
There seems to be no dataset reader in Luminoth that supports this format.
For reading a dataset, the folder structure and format of the annotation must be supported by Luminoth (Pascal VOC, COCO, etc).
Where did you get this dataset from? Is it open and public? If so, we could take a look and try to build a reader that works for this.


Add links to readme

ExpertPDF (http://www.html-to-pdf.net/)
IronPDF (http://ironpdf.com/)
iTextSharp (https://sourceforge.net/projects/itextsharp/)
NReco PDF Creator for .NET (http://www.nrecosite.com/pdf_generator_net.aspx)
HTML renderer for PDF Sharp (https://www.nuget.org/packages/HtmlRenderer.PdfSharp/)
SelectPDF community edition (http://selectpdf.com/community-edition/)

ExpertPDF (http://www.html-to-pdf.net/) IronPDF (http://ironpdf.com/) iTextSharp (https://sourceforge.net/projects/itextsharp/) NReco PDF Creator for .NET (http://www.nrecosite.com/pdf_generator_net.aspx) HTML renderer for PDF Sharp (https://www.nuget.org/packages/HtmlRenderer.PdfSharp/) SelectPDF community edition (http://selectpdf.com/community-edition/)

go further


Add retry around get_user_by_api_key

get_user_by_api_key can fail if there are intermittent DB connection errors. We should retry if it fails.

Should be fixed by #821.


Getter methods for camera position

Hi (again!),
I'm not sure if I'm missing something but I'm struggling to find a way to get the current rotation, center and zoom of the camera for the viewer (e.g. to save specific views). Is this currently possible? I looked at trying to access the viewer's _cam property directly but couldn't get this to work (my javascript hackery is limited!)
Best wishes,
Harry

Don't ask me why, but most of them have been missing. I've just added viewer.rotation(), viewer.center() (viewer.zoom() already existed). The following will print the rotation (as mat4), center of rotation and the zoom factor
console.log('rotation:', pv.mat4.str(viewer.rotation()),
            ', center:', pv.vec3.str(viewer.center()),
            ', zoom:', viewer.zoom());

Ah ok, thank you! I saw the zoom one but it threw an error when I was using the minified release. I actually got to them in the end by finding the obfuscated _cam using the Chrome javascript inspector! (it's _d inside the viewer in the version I'm using) But using the getters is much better of course :D


[Enhancement] ON Clause support mutiple subqueries

What type of PR is this：

[ ] bug
[ ] feature
[x] enhancement
[ ] refactor
[ ] others

Which issues of this PR fixes ：

Fixes #9875
Enhancement
Continuation of the previous work #9832, the main work of this pr is to remove the restriction that the on clause can only contain one subquery, then we can write join on predicate like the below example
select * from t0 join t1 on
t0.v1 = t1.v1
and t0.v2 in (select v2 from t2)
and t0.v3 = (select v3 from t2 where t2.v1 = t0.v1)

And the solution is simple and straightforward, since the Expr can only contains one subquery, I'm not going to remove this limitation, but turn to extract all the conjuncts of the join on predicate, and processing every single conjunct indenpendently, and each conjunct can only contains one subquery(conjunct is also a Expr, which should follow the same limitation).
Checklist:

[x] I have added test cases for my bug fix or my new feature
[x] I have added user document for my new feature or new function

[FE PR Coverage Check]
:heart_eyes: pass : 90 / 92 (97.83%)
file detail

path
covered_line
new_line
coverage
not_covered_line_detail

:large_blue_circle:
com/starrocks/analysis/Expr.java
31
33
93.94%
[386, 414]

:large_blue_circle:
com/starrocks/sql/optimizer/transformer/RelationTransformer.java
56
56
100.00%
[]

:large_blue_circle:
com/starrocks/sql/optimizer/transformer/SubqueryTransformer.java
2
2
100.00%
[]

:large_blue_circle:
com/starrocks/planner/LoadScanNode.java
1
1
100.00%
[]

run starrocks_clang-tidy

run starrocks_be_unittest

run starrocks_fe_unittest

[FE PR Coverage Check]
:heart_eyes: pass : 91 / 93 (97.85%)
file detail

path
covered_line
new_line
coverage
not_covered_line_detail

:large_blue_circle:
com/starrocks/analysis/Expr.java
31
33
93.94%
[386, 414]

:large_blue_circle:
com/starrocks/sql/optimizer/transformer/RelationTransformer.java
57
57
100.00%
[]

:large_blue_circle:
com/starrocks/sql/optimizer/transformer/SubqueryTransformer.java
2
2
100.00%
[]

:large_blue_circle:
com/starrocks/planner/LoadScanNode.java
1
1
100.00%
[]

run starrocks_admit_test


FreeMarker / Pebble failed

https://youtrack.jetbrains.com/issue/KTOR-4272/Template-FreeMarker-Pebble-doesn-t-work-when-Mustache-works-norm

it looks like wont fixed .
Please dont use  these 2 plugin.
Use Mustache  . Mustache  is good <3


Publications Validations

Validations for ISBN/ISSN/DOIs.  This can either be on the model level or at import.
Having model level validations will give us more universal control over what gets into the database.  As of right now our biggest issue is data coming in from Digital Measures.  Sometimes the data is either wrong, or placed in the wrong field (ie a doi in the isbn/issn field).  This is where validating on import might be a better solution, since we could detect identifiers in the wrong field and put them in the right place on import.
It might make sense to implement both of these.  Model level validations for universal use, and something that detects identifiers in the wrong fields during the DM import.

1b5e0b2af66f0ec5a77834b65e48159b38fd9e88

@EricDurante Since we already have a DOIParser and now have a DOI field in Activity Insight, I think we just need something that can differentiate between ISSNs and ISBNs from AI?  I think this only needs to be applied to the AI importer, since the other resources don't seem to give us isbns.
The data coming from Pure has an "isbns" element in the JSON output.  I can have the Pure importer import this.  It currently is not importing isbns.

@ajkiessl That all sounds accurate/good to me. It would be good to have our definition of valid DOI format in only one place if possible (especially so since I don't know if our definition is 100% correct, and so it might have to be tweaked in the future).
Is the plan still to check each field (DOI, ISSN, ISBN, URL, etc.) from AI for a valid DOI, ISSN, or ISBN value and take values that are entered in the incorrect place in AI and put them in the correct place in RMD? If so, then we'll probably need to establish single definitions of ISSN and ISBN validity somewhere too.

@EricDurante  Yeah I'll stick to that plan.  I was considering model level validations for publications to check that DOIs, ISBNs, and ISSNs match their corresponding regexes.  I think that might be too restrictive.  I don't want to implement something that will affect the other imports, since AI seems to be the primary source of this problem.  For now, I'll implement something like the DOIParser for ISSNs and ISBNs that can be used to get incorrect values in AI put in the right place in RMD.


Enable remember-me in owner webapp

changes signin request from post to get so we can easily pass parameters that can be
picked up by the RememberMeServices

configures RememberMeServices in owner-security.xml

changes login method in won-utils.js

changes the session timeout to 1 day

How to test:

log in with an account
note there is a 'remember me' checkbox in the login popover
do not check that box
when logged in, close the window (and all other windows, so the session is closed)
open a new browser window
open the owner webapp
notice that you are not logged in.
log in again, now checking 'remember-me'
when logged in, close all browser windows
open a new browser window and open the owner webapp
check that you are now logged in

Note: the remember-me function survives an owner-webapp server restart

i think we should be careful with putting the password in the http request parameters. See here for example: https://stackoverflow.com/questions/323200/is-an-https-query-string-secure

2 other issues:

when you reopen the browser and owner url you come to the page where you can post a new needs about do not see your posted needs, matches etc. => i think this should be another start page for an aldready logged in user
when you log in and click "remember me" then you close the browser and reopen it you are still logged in => ok. If you post a need now and then close the browser again (without loggin out) and then open it again you should still be logged in but actually you are logged out then

@heikofriedrich your first point is an edge-case we'll have to deal with in the future. The second one has to do (I think) with the browser evicting the cookie because it is marked as 'secure' but the integration-test server only has a self-signed certificate. We'll see if that persists on live.


RT-4.10 Use Await to check for route summary

RT-4.10 Use Await to check for route summary to avoid flakiness in test runs
--- PASS: TestRouteSummaryWithISIS (42.62s)
...
 --- PASS: TestRouteSummaryWithBGP (49.53s)
     --- PASS: TestRouteSummaryWithBGP/propagate_IPv4_over_IPv4 (26.23s)
     --- PASS: TestRouteSummaryWithBGP/propagate_IPv6_over_IPv6 (23.30s)

Pull Request Functional Test Report for #2965 / 6014e47804d94c3d07ca7ffaff411758896bf5fd
Virtual Devices

Device
Test
Test Documentation
Job
Raw Log

Arista cEOS

RT-4.10: AFTs Route Summary

Cisco 8000E

RT-4.10: AFTs Route Summary

Cisco XRd

RT-4.10: AFTs Route Summary

Juniper ncPTX

RT-4.10: AFTs Route Summary

Nokia SR Linux

RT-4.10: AFTs Route Summary

Openconfig Lemming

RT-4.10: AFTs Route Summary

Hardware Devices

Device
Test
Test Documentation
Raw Log

Arista 7808

RT-4.10: AFTs Route Summary

Cisco 8808

RT-4.10: AFTs Route Summary

Juniper PTX10008

RT-4.10: AFTs Route Summary

Nokia 7250 IXR-10e

RT-4.10: AFTs Route Summary

Help

Pull Request Test Coverage Report for Build<PHONE_NUMBER>
Details

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 55.859%

Totals

Change from base Build<PHONE_NUMBER>:
0.0%

Covered Lines:
1983

Relevant Lines:
3550

💛  - Coveralls


Avoid NPE if a window is ordered over a column that has null values.

Summary of the changes / Why this improves CrateDB
Checklist

[x] User relevant changes are recorded in CHANGES.txt
[x] Touched code is covered by tests
[ ] Documentation has been updated if necessary
[x] CLA is signed

This should go into 3.2 and 3.3, right? (labels are missing)

Yes, I usually add the lables after I get ✅


[BUG] Drawing Chinese using SkiaSharp in Blazor WASM is very blurry

Description
I have enabled Antialias, but Blazor WASM DrawText in Chinese comes out very blurry, Windows Forms DrawText Chinese is very clear and sharp.
What is the method to draw Chinese clearly on Blazor WASM SkiaSharp?
The following figure shows the test cases:

Code
https://github.com/18779758522/SkiaSharpBlazorWebDemo
Expected Behavior
I tried upgrading to the latest version and it worked the same way.
Actual Behavior
No response
Version of SkiaSharp
2.88.4-preview (Preview)
Last Known Good Version of SkiaSharp
Other (Please indicate in the description)
IDE / Editor
Visual Studio Code (Windows)
Platform / Operating System
All
Platform / Operating System Version
Goole Chrome 122.0.6261.112
Devices
No response
Relevant Screenshots
No response
Relevant Log Output
No response
Code of Conduct

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

The problem at first glance, is in your code : you asked for TextSize = 16. That means it is generated at size 16 (roughly a 16x16 pixel grid, though the actual detail could differ, depending on the font itself), then scaled/drawn on your canvas. If you ask for a much larger size and have skia scale down for you, you would get better results.

Also 16 is likely an embedded bitmap size - ie you are reading the embedded bitmap within the font, rather than using the scalable outlines. Just a much larger value e.g. 32, then scale it to half size within the canvas.

16 也可能是嵌入位图大小 - 即您正在读取字体内嵌入的位图，而不是使用可缩放轮廓。只需一个大得多的值，例如 32，然后在画布内将其缩放到一半大小。

Thank you for your answer, this method may be feasible. It's strange why using Winform can draw text very clearly.

Winform likely defaults to disable the use of embedded bitmaps. This is possible with freetype based renderer (skia) too, but it is not the default.
 Some people prefer the outlines: you can gray pixels but the shapes are never distorted.
Hmm, I think it is the other way round - winforms uses the embedded bitmaps but skiasharp uses outlines. Anyway, you want to look for the embedded bitmap option or scale it yourself.

Found it - you want to play with the embedded bitmap property a bit: https://learn.microsoft.com/en-us/dotnet/api/skiasharp.skfont.embeddedbitmaps?view=skiasharp-2.88#skiasharp-skfont-embeddedbitmaps - i.e. set it on if it is off, etc.

Found it - you want to play with the embedded bitmap property a bit: https://learn.microsoft.com/en-us/dotnet/api/skiasharp.skfont.embeddedbitmaps?view=skiasharp-2.88#skiasharp-skfont-embeddedbitmaps - i.e. set it on if it is off, etc.

Wow, it's effective, the drawing effect is the same as Winform.

using var paint = new SKPaint
{
        TextSize = 16,
        IsAntialias = true,
        Color = SKColors.Black,
        TextAlign = SKTextAlign.Left,
        Typeface = SkiaChinaFont.ChinaFont,
        IsEmbeddedBitmapText = true
};

SKPaint.IsEmbeddedBitmapText = true  Just need to set it to true here

Embedded bitmap is what it is - a pixel grid of the glyph within the font. So if you specific to use it, and also disable scaling, you should get identical result with the same font, regardless of which tech you use to display the font.

close

You should/could close this one too: https://github.com/mono/SkiaSharp/issues/2713


HADOOP-17195. ABFS Store thread pool for stream IO.

This is the successor to #2179

ABFS Store creates a single threadpool, configurable with fixed size or multiple of cores
each output stream is given its own semaphored pool which limits the access that stream has to the pool

To actually defend against OOMs the per-stream queue length is what needs to be managed; looking at the patch it still has the problem of #2179: you need one buffer per pending upload in the the pools.
Ultimately the S3A Connector fixed this by going to disk buffering by default. A more performant design might be to have a blocking byte buffer factory which limits the #of buffers which the streams can request, so putting an upper bound on the amount of memory which a single ABFS store instance can demand.

:confetti_ball: +1 overall

Vote
Subsystem
Runtime
Comment

+0 :ok:
reexec
1m 39s
Docker mode activated.

_ Prechecks _

+1 :green_heart:
dupname
0m  0s
No case conflicting files found.

+1 :green_heart:
@author
0m  0s
The patch does not contain any @author tags.

+1 :green_heart:
test4tests
0m  0s
The patch appears to include 1 new or modified test files.

_ trunk Compile Tests _

+1 :green_heart:
mvninstall
36m 34s
trunk passed

+1 :green_heart:
compile
0m 49s
trunk passed with JDK Ubuntu-11.0.8+10-post-Ubuntu-0ubuntu118.04.1

+1 :green_heart:
compile
0m 33s
trunk passed with JDK Private Build-1.8.0_265-8u265-b01-0ubuntu2~18.04-b01

+1 :green_heart:
checkstyle
0m 26s
trunk passed

+1 :green_heart:
mvnsite
0m 40s
trunk passed

+1 :green_heart:
shadedclient
19m 51s
branch has no errors when building and testing our client artifacts.

+1 :green_heart:
javadoc
0m 32s
trunk passed with JDK Ubuntu-11.0.8+10-post-Ubuntu-0ubuntu118.04.1

+1 :green_heart:
javadoc
0m 27s
trunk passed with JDK Private Build-1.8.0_265-8u265-b01-0ubuntu2~18.04-b01

+0 :ok:
spotbugs
1m 13s
Used deprecated FindBugs config; considering switching to SpotBugs.

+1 :green_heart:
findbugs
1m  9s
trunk passed

_ Patch Compile Tests _

+1 :green_heart:
mvninstall
0m 36s
the patch passed

+1 :green_heart:
compile
0m 37s
the patch passed with JDK Ubuntu-11.0.8+10-post-Ubuntu-0ubuntu118.04.1

+1 :green_heart:
javac
0m 37s
the patch passed

+1 :green_heart:
compile
0m 31s
the patch passed with JDK Private Build-1.8.0_265-8u265-b01-0ubuntu2~18.04-b01

+1 :green_heart:
javac
0m 31s
the patch passed

-0 :warning:
checkstyle
0m 19s
hadoop-tools/hadoop-azure: The patch generated 7 new + 2 unchanged - 0 fixed = 9 total (was 2)

+1 :green_heart:
mvnsite
0m 34s
the patch passed

+1 :green_heart:
whitespace
0m  0s
The patch has no whitespace issues.

+1 :green_heart:
shadedclient
18m 28s
patch has no errors when building and testing our client artifacts.

+1 :green_heart:
javadoc
0m 27s
the patch passed with JDK Ubuntu-11.0.8+10-post-Ubuntu-0ubuntu118.04.1

+1 :green_heart:
javadoc
0m 24s
the patch passed with JDK Private Build-1.8.0_265-8u265-b01-0ubuntu2~18.04-b01

+1 :green_heart:
findbugs
1m 15s
the patch passed

_ Other Tests _

+1 :green_heart:
unit
1m 38s
hadoop-azure in the patch passed.

+1 :green_heart:
asflicense
0m 34s
The patch does not generate ASF License warnings.

90m 15s

Subsystem
Report/Notes

Docker
ClientAPI=1.40 ServerAPI=1.40 base: https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-2294/1/artifact/out/Dockerfile

GITHUB PR
https://github.com/apache/hadoop/pull/2294

Optional Tests
dupname asflicense compile javac javadoc mvninstall mvnsite unit shadedclient findbugs checkstyle

uname
Linux 70cc2f756b0c 4.15.0-112-generic #113-Ubuntu SMP Thu Jul 9 23:41:39 UTC 2020 x86_64 x86_64 x86_64 GNU/Linux

Build tool
maven

Personality
dev-support/bin/hadoop.sh

git revision
trunk / e5fe3262702

Default Java
Private Build-1.8.0_265-8u265-b01-0ubuntu2~18.04-b01

Multi-JDK versions
/usr/lib/jvm/java-11-openjdk-amd64:Ubuntu-11.0.8+10-post-Ubuntu-0ubuntu118.04.1 /usr/lib/jvm/java-8-openjdk-amd64:Private Build-1.8.0_265-8u265-b01-0ubuntu2~18.04-b01

checkstyle
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-2294/1/artifact/out/diff-checkstyle-hadoop-tools_hadoop-azure.txt

Test Results
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-2294/1/testReport/

Max. process+thread count
309 (vs. ulimit of 5500)

modules
C: hadoop-tools/hadoop-azure U: hadoop-tools/hadoop-azure

Console output
https://ci-hadoop.apache.org/job/hadoop-multibranch/job/PR-2294/1/console

versions
git=2.17.1 maven=3.6.0 findbugs=4.0.6

Powered by
Apache Yetus 0.13.0-SNAPSHOT https://yetus.apache.org

This message was automatically generated.

Looking at this a bit more

its the use of buffer which causes the OOM not the thread pooling, so neither this nor its predecessor patch will directly fix that
need to support a bytebuffer pool with max capacity and/or disk buffering

Closing this, but leaving up as the PoC to say "we should have a shared thread pool for lower startup costs"; it would be a switch to buffering on which will the way to guarantee an end to OOM problems
I am happy for the S3A blocks class to be moved to hadoop-common to address this.

Maybe I was being pessimistic there. If the #of active writes a single stream can have active is throttled, the #of open blocks a single stream can have allocated is also blocked. But: ability to buffer on disk is the way to robustly avoid scale issues with many active threads.


[Bug]: incompatiblity with immersive weathering

Minecraft Version
1.18.2
Fabric Version
0.13.3
Mod Version
prefab-fabric-3.1.2.jar
Details
using prefab alongside of immersive weathering, causes a crash when using certain prefab blocks.
https://pastebin.ubuntu.com/p/bPqSZp5B3k/
its to do with
Cannot get property class_2746{name=fertile, clazz=class java.lang.Boolean, values=[true, false]} as it does not exist in Block{prefab:block_grass_stairs}

This is an error in Immersive Weathering that they have to fix.


Old column widths are reused on matching column names

A very slight modification to the 112 tutorial (add/delete/swap data) illustrates the problem.
In colDefs1 the 'company' field has width:60 and it works fine. colDefs2 has a column defined with the same name but with width:120 . When you swap the data to use colDefs2 it keeps the width of the company column at 60 rather than using the new value of 120.
It looks like there is some internal cache that gets reused when the column name is the same.
http://plnkr.co/edit/kpn77emSbQLb4VbVe0XK?p=preview

Confirmed. Relevant code is most likely here: https://github.com/angular-ui/ng-grid/blob/master/src/js/core/factories/Grid.js#L812

I believe this if-else chain is the problem: https://github.com/angular-ui/ng-grid/blob/master/src/js/core/factories/GridColumn.js#L431
if (gridUtil.isNullOrUndefined(self.width) || !angular.isNumber(self.width)) {
      if (gridUtil.isNullOrUndefined(colDef.width)) {
        self.width = '*';
      }

      [....]

        // Is a number, use it as the width
        else {
          self.width = colDef.width;
        }
      }
    }

If width is defined and a number, it isn't updated. Setting widths as percentages makes the demo work.

nope, I re-read it and noticed it has already been addressed in the latest version.


patient files should be html not xml

do we want to do this? if you're using QRDA for the patient import we would want a record of the QRDA looks like...


MINOR: [C++] Substrait example fix

A recent refactor on File handling has not updated the example. Fixing it in this minor PR.

Thanks for the catch.


[Feature Request] Make UBI query_id optional

Is your feature request related to a problem? Please describe
In some cases, it may not be desirable for a client to generate a UBI on the client-side. In these cases, the query_id should be optional.
Describe the solution you'd like
If a query_id is not provided, UBI should generate a random query_id (likely a UUID) and return it in the ubi block of ext in the search response.
Additional context
This relates to UBI which is described in #12084 and #13545.
This issue can be assigned to myself.

[Triage - attendees 1 2 3 4]
@jzonthemtn Thanks for filing.

Closing this RFC because the initial implementation is now available at https://github.com/opensearch-project/user-behavior-insights and new issues can be created there.


Error: ImportFileUpload expired while uploading service dialog

I'm getting Error: ImportFileUpload expired while trying to upload YAML file with service dialog:

I'm not getting any error messages in console log.

@eclarizio Can you work with @romanblanco to try to track this one down.
@romanblanco Are you running simulate_queue_worker?  I believe we still queue the delete of the imported data using deliver_on column of the MiqQueue model which simulate_queue_worker ignores.
Are there any errors in the evm.log?

Yeah I believe I've seen this error before as the simulate_queue_worker immediately executes the deletion of the imported data, which causes the "file expired" error. If you're not running simulate_queue_worker then something else must be consuming that item in the queue immediately.

I'm running simulate_queue_worker, after uploading the YAML, the worker log shows:
  ImportFileUpload Load (0.3ms)  SELECT  "import_file_uploads".* FROM "import_file_uploads" WHERE "import_file_uploads"."id" = $1 LIMIT $2  [["id",<PHONE_NUMBER>0020], ["LIMIT", 1]]
  ImportFileUpload Inst Including Associations (1.9ms - 1rows)
   (0.1ms)  BEGIN
  BinaryBlob Load (0.4ms)  SELECT  "binary_blobs".* FROM "binary_blobs" WHERE "binary_blobs"."resource_id" = $1 AND "binary_blobs"."resource_type" = $2 LIMIT $3  [["resource_id",<PHONE_NUMBER>0020], ["resource_type", "ImportFileUpload"], ["LIMIT", 1]]
  BinaryBlob Inst Including Associations (7.3ms - 1rows)
  SQL (0.4ms)  DELETE FROM "binary_blob_parts" WHERE "binary_blob_parts"."binary_blob_id" = $1  [["binary_blob_id",<PHONE_NUMBER>3825]]
  SQL (0.2ms)  DELETE FROM "binary_blobs" WHERE "binary_blobs"."id" = $1  [["id",<PHONE_NUMBER>3825]]
  SQL (0.1ms)  DELETE FROM "import_file_uploads" WHERE "import_file_uploads"."id" = $1  [["id",<PHONE_NUMBER>0020]]
   (0.7ms)  COMMIT
   (0.1ms)  BEGIN
  SQL (0.2ms)  DELETE FROM "miq_queue" WHERE "miq_queue"."id" = $1 AND "miq_queue"."lock_version" = $2  [["id",<PHONE_NUMBER>9137], ["lock_version", 0]]
   (0.7ms)  COMMIT

After commiting import, nothing happens in the log, just the flash message appears

Try the import without running simulate_queue_worker.  What I was mentioning above is that simulate_queue_worker will delete the imported data before it can be processed since it does not honor the deliver_on queue field.

@gmcculloug I see, sorry didn't understood.
Without simulate_queue_worker it works fine, no error in evm.log, only:
[----] I, [2017-08-03T14:25:22.689788 #11694:2ac8db6f49c8]  INFO -- : MIQ(MiqQueue.put) Message id: [10000004399142],  id: [], Zone: [default], Role: [], Server: [], Ident: [generic], Target id: [], Instance id: [10000000000025], Task id: [], Command: [ImportFileUpload.destroy], Timeout: [600], Priority: [100], State: [ready], Deliver On: [2017-08-04 12:25:22 UTC], Data: [], Args: []

With simulate_queue_worker running, I'm getting:
[----] I, [2017-08-03T14:27:10.966513 #11694:2ac8db6f49c8]  INFO -- : MIQ(MiqQueue.put) Message id: [10000004399143],  id: [], Zone: [default], Role: [], Server: [], Ident: [generic], Target id: [], Instance id: [10000000000026], Task id: [], Command: [ImportFileUpload.destroy], Timeout: [600], Priority: [100], State: [ready], Deliver On: [2017-08-04 12:27:10 UTC], Data: [], Args: []
[----] I, [2017-08-03T14:27:11.283189 #22242:2b0a6f956f88]  INFO -- : MIQ(MiqQueue#deliver) Message id: [10000004399143], Delivering...
[----] I, [2017-08-03T14:27:11.324089 #22242:2b0a6f956f88]  INFO -- : MIQ(MiqQueue#delivered) Message id: [10000004399143], State: [ok], Delivered in [0.040926831] seconds
[----] E, [2017-08-03T14:27:24.719587 #11694:2ac8db6f47c0] ERROR -- : MIQ(miq_ae_customization_controller-import_service_dialogs): Error: ImportFileUpload expired

in the evm.log

Correct, it is working as designed and this issue can be closed.

Thanks @gmcculloug @eclarizio


Packet Filtering Using Access Control Lists in Networking

Proposed title of article
Understanding Packet Filtering in Networks Using ACLs.
Introduction paragraph (2-3 paragraphs):
Security is crucial for any network. In networks, packets are always moving from one host to another or from one network segment to another. This is insecure, as the network is more vulnerable to unwanted and dangerous traffic. To improve the security of the network, a security mechanism should be in place to control the incoming and outgoing traffic. For that, Access Control Lists become the solution to control the flow of traffic in and out of the network. They work on sets of rules that define how to forward or block a packet at a router's interface.
In this article, we are going to discuss how one can use the ACLs to restrict, permit or deny traffic in the network to provide secure remote administrative access. It will also equip the reader with the knowledge of how to configure the ACLs on the network devices, how to change them if they are not working correctly or if they require other changes.
Key takeaways:

What are Access Control Lists in networking?
How Access Control List provides security to a network.
How to create and configure Access Control Lists to network devices.

References:
N/A
Templates to use as guides
N/A

cc @hectorkambow  @ahmadmardeni1

@dentonya
Sounds like a helpful topic - lets please be sure it add value beyond what is in the official docs and what is covered in other blog sites.
Please be sure to double check that it does not overlap with any existing EngEd articles or incoming topic suggestions (if you haven't already) to avoid any potential article closure, please reference any relevant EngEd articles in yours. - Approved


Create troubleshooting-your-solution.md

This is a stub!
TODO:

confirm the placement of the file in the directories tree => Need feeback about that

correct/update the data at the top of the page  => Need feeback about that (see on zulip too)

images in light mode+dark mode to import/recreate

all links to correct (directed to wiki for now) -> added TODO inside the tags of all the links to wiki to spot them more easily

I used the version available on the wiki on 23 Jul 2020.

damn it... x/
the linter rejects built in in the text while the sentences are correct: the tests are built in suwh a way... => how to bypass the linter in this kind of case?

I don't know why it's not working :(

there are problems with internal links ([...](#internal-link)). Not sure if it's related to the preview of the PR if it will show up in the merged version too, but here is the thing:
in preview mode:

when clicking on the link, nothing happens
when opening the same link in a new tab, that "works" -> I get a new tab pointing on the related version, but the title is hidden behind the search bar:

(clicking on My solution seems to work fine, but some tests fail)
is it sepcific to the preview? (I guess not...)

aside of the link troubles (see above), ready to merge, it seems

Can you remove the Table of Contents? It's now generated on the side.

done.
...but I guess we'll need shorter titles... XD

Can you remove the Table of Contents? It's now generated on the side.

To be honest, I liked TOC at the top more than side navigation.  My idea behind the troubleshooting FAQ was to make it, well, a troubleshooting FAQ: user comes with some specific problem, searches for statement of that problem in a list of frequently encountered problems, and it leads them to the answer. I think that sidebar is meant more for navigation rather than being used as a kind of index, and it won't work well in case of this type of pages.
At the moment, I have no good idea how to make the FAQ look better, but IMO removing list of questions at the top and leaving a side menu does not help much.

Yeah, we can create a page for that after splitting this up.

I think it's best to have a single problem per page and those can to each other as necessary. We can have an index page too, but I don't want everything on the same page.
Each of these page have some consistent format like:
# How to ...

explain the problem

## Answers

can link to other pages

## Further Reading

The sidebar can be populated with related pages based on topics or snippets in different languages.

As I said before, we can pretty much tweak anything so feel free to open issues about any ideas you have.
I'm thinking of showing these pages automatically when a user tries to comment on Codewars containing specific keywords. To make that work, we should have stable URL for each problem instead of anchors within a page.