Require complete minimal project so configuration can be understood

I have played with the sample app from Github and want to try to use the library in my own app. However, attempts at creating a minimal app fail. I suspect instructions are missing from the instructions on Github.
Please provide a complete worked example.
I did this:
1  In Android Studio, File > New > New Project and selected "Empty Activity"
2 Built and ran this successfully.
3 Added the two entries to the two build.gradle files described in readme.MD (version 0.1.2)
4 Sync fails with this:
ERROR: Manifest merger failed : Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91
is also present at [androidx.core:core:1.1.0-beta01] AndroidManifest.xml:22:18-86 value=(androidx.core.app.CoreComponentFactory).
Suggestion: add 'tools:replace="android:appComponentFactory"' to  element at AndroidManifest.xml:5:5-19:19 to override.
5 I added the suggestion to AndroidManifest.xml - now get "ERROR: Manifest merger failed with multiple errors, see logs"
I note the sample app mainfest file includes: tools:ignore="GoogleAppIndexingWarning"
But this does not fix the problem.
Some (relevant?) discussion here? https://github.com/material-components/material-components-android/issues/193

This error is happening because the library uses the new AndroidX packages and your app does not.
You need to migrate your project to use AndroidX: Menu -> Refactor -> Migrate to AndroidX.
Alternatively, as suggested in the linked issue, you can add the two lines to your gradle.properties file:
android.useAndroidX=true
android.enableJetifier=true

I understand from the new issue that this is resolved, as you have migrated to AndroidX. Will close this now.
I do believe the documentation can be improved in so many ways so less reference has to be made to the sample project and I am working on that.

i do the same it's worked but app is open for 4 second and crash after that

i do the same it's worked but app is open for 4 second and crash after that

Please open a new issue and explain clearly.


MongoProfileService uses wrong id field name

MongoProfileService::update and MongoProfileService::deleteById both uses eq(ID, id) to find the Document to act on. But It should be eq(getIdAttribute(), id) instead.

Thanks very much for the report. Consider sending a pull request to demonstrate and and apply the fix.

Via https://github.com/pac4j/pac4j/pull/1349


Add row based schema validation code to detect schema mismatch

Description
This PR adds row based schema validation code to detect schema mismatch.
This validation will capture the schema mismatch on row basis, so that we don't miss any cases when converting the raw data to pinot data.
Sample mismatch detailed information:
Found data type mismatch from the following Pinot columns: [column2]
Found single-value multi-value field mismatch from the following Pinot columns: [column3]
Found multi-value structure mismatch from the following Pinot columns: [column3, column16]

High level question, do we really need row level validation? What is the overhead of this validation?
Seems like the validation only applies to the Avro reader. In that case, validating Pinot schema and Avro schema should be enough. IMO we are paying a lot of overhead for very little gain.

@jackjlli Could you describe the case which is not caught by schema level check?

Most of the cases can be covered by validating pinot schema and avro schema. One tricky thing is that when all the fields are required to be fetched, we convert the avro generic record to string first, then parse it as a json:
https://github.com/apache/incubator-pinot/blob/d54b04a2562f86dfb3adaa02ff400951d8108738/pinot-plugins/pinot-input-format/pinot-avro-base/src/main/java/org/apache/pinot/plugin/inputformat/avro/AvroRecordExtractor.java#L49
  /**
   * Converts from a GenericRecord to a json map
   */
  public static Map<String, Object> genericRecordToJson(GenericRecord genericRecord) {
    try {
      String jsonString = genericRecord.toString();
      return DEFAULT_MAPPER.readValue(jsonString, new TypeReference<Map<String, Object>>() {
      });
    } catch (IOException e) {
      throw new IllegalStateException("Caught exception when converting generic record " + genericRecord + " to JSON");
    }
  }

The data type of the value from the k-v pair might get changed.

Most of the cases can be covered by validating pinot schema and avro schema. One tricky thing is that when all the fields are required to be fetched, we convert the avro generic record to string first, then parse it as a json:
https://github.com/apache/incubator-pinot/blob/d54b04a2562f86dfb3adaa02ff400951d8108738/pinot-plugins/pinot-input-format/pinot-avro-base/src/main/java/org/apache/pinot/plugin/inputformat/avro/AvroRecordExtractor.java#L49
  /**
   * Converts from a GenericRecord to a json map
   */
  public static Map<String, Object> genericRecordToJson(GenericRecord genericRecord) {
    try {
      String jsonString = genericRecord.toString();
      return DEFAULT_MAPPER.readValue(jsonString, new TypeReference<Map<String, Object>>() {
      });
    } catch (IOException e) {
      throw new IllegalStateException("Caught exception when converting generic record " + genericRecord + " to JSON");
    }
  }

The data type of the value from the k-v pair might get changed.

I don't think we ever init record extractor without the fields. Also, converting to string then serializing as json doesn't seem correct. We should fix that instead of adding the row based validation.

This PR can be closed as we've already had the schema validation in another PR(https://github.com/apache/incubator-pinot/pull/5873).


Make fallover thumbnail rules consistent

On the homepage Newsroom widget, you use the thumbnail stored in global options as a fallback thumbnail when Category is set to "Blog". On the blog listing page, however, you use this one, which does not have padding.
I'm confused which one should be used when.  The one in global options, now, has padding and the one on the filesystem does not.  Could you review your use of these to make sure they are used in the correct places?

Fixed and copied to cncfci


Proposal: Rename init to new.

I propose renaming init command to new. There are two reasons for this that come to my mind:

Similarity with cargo contract -- it uses new for generating starting package/template for the project.
Sometimes, users may already have a working smart contract that they wish to deploy using swanky-cli. It's currently impossible to "just" init a project - i.e. generate swanky config file. This would match the functionality of git init as well.

I can do the work, just wanted to ask for your opinions first.

I agree.
Another reason is we also have swanky contract new command, so this would be more consistent.
Please proceed with the PR 👍


imagemagick: 6.9.3-10 -> 7.0.2-4 CVE-2016-3717

Motivation for this change
CVE-2016-3717
There were also a few more issues detailed in the change logs that didn't reach a CVE:
2016-05-25  7.0.1-7 Cristy<EMAIL_ADDRESS>  * Security improvements to TEXT coder broke it (reference
    https://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=29754).
  * Fix stroke offset problem for -annotate (reference
    https://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=29626).
  * Don't interpret -fx option arguments (reference
    https://www.imagemagick.org/discourse-server/viewtopic.php?f=3&t=29774);
  * Add additional checks to DCM reader to prevent data-driven faults (bug
    report from Hanno Böck).

2016-05-03  7.0.1-1 Cristy<EMAIL_ADDRESS>  * Sanitize input filename for http / https delegates (improved patch).
  * Fix for possible security vulnerabilities (reference
    https://www.imagemagick.org/discourse-server/viewtopic.php?f=4&t=29588).

Things done

[x] Tested using sandboxing
(nix.useChroot on NixOS,
or option build-use-chroot in nix.conf
on non-NixOS)
Built on platform(s)

[x] NixOS
[ ] OS X
[x] Linux

[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
[x] Fits CONTRIBUTING.md.

p.s. also fixed up the patch to make it easier to update the package.

Travis run out of room.

The 6->7 major update is likely to break some reverse dependencies, as there were many symbols removed http://abi-laboratory.pro/tracker/objects_report/imagemagick/6.9.5-2/7.0.1-0/report.html

Note: 6.9.3-10 is not vulnerable to that CVE according to https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2016-3717

Oh, the wrong title confused me.

But still, imagetragic.com claims our policy patch was enough to fix security.
The major update should be tested with reverse dependencies before merging; I think build-time testing should be enough in this case.

Then I'll suggest the same thing we discussed regarding librsvg (https://github.com/NixOS/nixpkgs/pull/16735): To follow upstream and use the imagemagick namespace as the current branch (http://imagemagick.org/) and the previous v6 branch as the legacy (http://legacy.imagemagick.org/) branch.
Either way, I've changed the title to WIP as well.

Now I'm confused too :)
Anyhow, I'm off the PC until Monday so you'll likely be deciding regarding 6.9.3-10 versus 6.9.5-2 on your own.
So, good luck :)

I've changed the PR to target the latest legacy branch. The namespace issue of current\legacy will have to wait.
Note: The master is incompatible with stable since https://github.com/NixOS/nixpkgs/commit/73f1f5eb3969743fe459e7cc36cfb766c7f5318a#diff-cdd4240cc50e7dc234040d6ccfcb0cba and can't be used in stable.  To backport, cherry-pick the patch, version and sha256.

Travis false negative:
*** Downloading ‘https://cache.nixos.org/nar/11cwvq369bk5kgsqkwnf6b8rpjj6gy4cjvh3fnxb3ca366pmzxyg.nar.xz’ to ‘/nix/store/cjiv33k4qjm11x380bzkagzv9fdrw78m-digikam-4.12.0.tar.bz2’...

curl: (18) transfer closed with 82103020 bytes remaining to read

/nix/store/hs8lf8v9qqfs9m3jqmm97nqg7wg9dqjw-xz-5.2.1/bin/xz: (stdin): Unexpected end of input

error: unexpected end-of-file

download of ‘https://cache.nixos.org/nar/1idwx80hilfgg0wxcma06xfwdsyx2gpxn7m06iimlpkrr8pl2a06.nar.xz’ failed: No such file or directory

could not download ‘/nix/store/n24dm7vrziv0bbw7hsdkc4dj1n9yh96r-calligra-2.9.11.tar.xz’ from any binary cache

fetching path ‘/nix/store/n24dm7vrziv0bbw7hsdkc4dj1n9yh96r-calligra-2.9.11.tar.xz’ failed with exit code 1

fetching path ‘/nix/store/ngpb0fbb2fs8b7cs2mlfl9gy42r00b55-disorderfs_0.4.2.orig.tar.gz’...

Builds fine for me, thanks!


For the browser, the volume doesn't change

Describe the bug
When running video or audio in a browser, such as Firefox, you can't adjust the volume with the mouse wheel.
To Reproduce
Steps to reproduce the behavior:

Open the Firefox browser
Go to the page with any media content
Play media
Move the cursor over the player control
Move the mouse wheel up and down

Expected behavior
Changes the volume of the video or audio that is running in the browser
Screenshots
Environment:

Distro: [e.g. Ubuntu 24.10]
GNOME version [47]
Extension Version [2.0.2]

Additional context
Checked for Firefox and Floorp browsers

floorp is firefox based - so seems a firefox problem

#156 in this issue a link to the FF issue


Custom user interface

As we need to reduce several components of the user interface we would want to build a custom user interface if somehow possible. Unfortunately I can't find anything in the documentation on how to connect to the websocket or how to use it accordingly. How can I create a valid connection to the video/audio stream and embed it and close a room using the websockets?

That's great, let me point you to the right directions: To create your own interface please refer to the JavaScript library documentation, there is also a tutorial project that uses React, but any other Framework is fine. For sure you can also use native JavaScript as described in the documentation.

Thanks for the links, I wanted to download the Javascript library, but there is no library in that download - only the documentation.

You can use the JavaScript library hosted on npm. If you have any further questions do not hesitate to create an issue!


Scale= option to \setmathfont undocumented

According to several answers on tex.SE as well as issues here, there is a Scale= option to \setmathfont. However, there is no description of this options and its possible values in the user manual as of 2019/09/26. I think this information should be added.

unicode-math will simply pass all these options to fontspec, and they are documented in fontspec package.

Hm, alright. After searching specifically for fontspec, I found the following sentence at the end of the introductory paragraph of "4 Unicode maths font setup":

Other fontspec features are also valid.

So you are right, it is documented.
I still wish it would be more prominent. After reading a package documentation once (more or less) completely, I often try to quickly find the feature I'm want to use by searching the pdf. In this case, searching for "scale" finds appendix D on XeTeX math font dimensions.
Maybe it would be possible to have a table / appendix briefly listing the fontspec options, and refer to it from that sentence?


[3.x] Fix action exact match

Back-port of https://github.com/godotengine/godot/pull/54173
MRP: Test9.zip

Is cherrypick:3.3 still needed? I would guess a 3.4 cherry pick makes more sense.

Thanks!


pin version for a particular project

need a feature to automatically switch go version for a particular project, i should be able to manually set this version

BTW, it's very similar to what nvm have

gvm applymod automatically picks version from go.mod file. Is there need for a separate file for keeping version? I think expected go version for project should be in go.mod. What are your thoughts?

@ShivamKumar2002 right, the expected version will be in go.mod.
I was hoping the version switch will be automatic once the terminal is opened in the same directory as the go.mod file, instead of typing the applymod command


ionic serve failed on Mac OS X

ionic serve
There was an error serving your Ionic application: Error: getaddrinfo ENOTFOUND localhost
at errnoException (dns.js:28:10)
at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:79:26)
Caught exception:
Error: getaddrinfo ENOTFOUND localhost
at errnoException (dns.js:28:10)
at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:79:26)
It was working just last night.

ionic serve --address <IP_ADDRESS>
solved the issue.


Theme settings filters not working

Ran into an issue where trying to filter the menus in the header and footer didn't change the menu locations in the theme. The following code does not affect whether or not the footer menu is registered:
function remove_footer_menu(): array {
		return [];
	}

add_filter( 'teft_footer_menus', __NAMESPACE__ . '\\remove_footer_menu', 10, 1 );

Checked Thongruppen because their repo had this code as well and the footer menu still displays on  dev03.

Closing this as it is not related to the base setup.


[cypress] wait and verify slice in dashboard one-by-one

Try to fix the flaky cypress dashboard test, as discussed offline with @graceguo-supercat
@michellethomas

Codecov Report

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

@@           Coverage Diff           @@
##           master    #5995   +/-   ##
=======================================
  Coverage   63.54%   63.54%
=======================================
  Files         393      393
  Lines       23654    23654
  Branches     2638     2638
=======================================
  Hits        15032    15032
  Misses       8609     8609
  Partials       13       13

Continue to review full report at Codecov.

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


Multi-outputs & class_weight

Assume our model have two outputs :
output 1   'class'    for  classification
output 2   'location'  for regression
Now we have the imbalance dataset(eg. binary classification, class '0': 98 percent, class '1': 2 percent), so we need set the class_weight params in model.fit() function, but for output 2 'location' regression task, we do not need class_weight.
How can we set  the class_weight in this situation?
Does "class_weight = {0: ratio 1 ,   1:  ratio 2} is applied the classification task  and ignore the regression task by default？

And a second situation is that:
output 1 'class_1' for classification
output 2 'class_2' for classification
Both outputs do the classification, but we want to give each output different class_weight params.
How can we do this? (I am not sure whether this situation makes sense or not. )
Maybe Like this?:
class_weight = { 'class_1': {0: ratio 1 , 1: ratio 2} , 'class_2': {0: ratio 3 , 1: ratio 4}  }

You should pass a dict with string keys corresponding to the names of your
outputs. Like you describe.
On 15 December 2016 at 15:14, Ke Young<EMAIL_ADDRESS>wrote:

And a second situation is that:
output 1 'class_1' for classification
output 2 'class_2' for classification
Both outputs do the classification, but we want to give each output
different class_weight params.
How can we do this? (I am not sure whether this situation makes sense or
not. )
Maybe Like this?:
class_weight = { 'class_1': {0: ratio 1 , 1: ratio 2} , 'class_2': {0:
ratio 3 , 1: ratio 4} }
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/fchollet/keras/issues/4735#issuecomment-267472549,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AArWb6wWFGIUv7e82crHb9ggQ4M2oyAnks5rIcnJgaJpZM4LOrKk
.

Thanks for your quick response.
If we use the one-hot code.
For the two classes classification, should the class_weight like this? :
class_weight = {10: weight 1, 11:  weight 2}
10 and 11 repesent the one hot codes of the two classes

No, use integers.
On 15 December 2016 at 15:31, Ke Young<EMAIL_ADDRESS>wrote:

Thanks for your quick response.
If we use the one-hot code.
For the two classes classification, should the class_weight like this? :
class_weight = {10: weight 1, 11: weight 2}
10 and 11 repesent the one hot codes of the two classes
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/fchollet/keras/issues/4735#issuecomment-267475515,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AArWb98elmzifptTjsU3SK1SYX-_wIT3ks5rIc23gaJpZM4LOrKk
.

@fchollet what is the right way to set weights given multi-class, one-hot encoded outputs? e.g. y = [0, 1, 1, 1, 0]

Yup. Same issue

@olix20 did you find a solution ?

For a multi output model how can I change class_weights during training ie after each step according to a batch.

In 2020 / TF 2.3.0 this does not work: class_weights = {'output1': {0: 1, 1: 10}, 'output2': {0: 5, 1: 1, 2: 10}}

this discussion should be reopened as of Dec 11, 2020 as this issue is still not resolved.
Here is what it comes to me:
ValueError: Expected ``class_weight`` to be a dict with keys from 0 to one less than the number of classes, found {'THEORETICAL': {0: 0.9251916468411314, 1: 1.0879701585327946}, 'ENGINEERING': {0: 0.9703354588300527, 1: 1.031535514294135}, 'EMPIRICAL': {0: 0.720016457519029, 1: 1.6362786348761102}, 'OTHERS': {0: 0.5192107995846313, 1: 13.513513513513514}}
and this discussion is related to another discussion.

Agreed.  This is really needed.

@fchollet Can we get this re-opened?  We are dealing an inherently asymmetric target set with the need for multiple outputs.  class_weight is the right way for us to address this.  Is there a work around?  (Topic is also addressed in https://github.com/tensorflow/tensorflow/issues/41448#issuecomment-756145318)

@fchollet Can we get this re-opened?  We are dealing an inherently asymmetric target set with the need for multiple outputs.  class_weight is the right way for us to address this.  Is there a work around?  (Topic is also addressed in https://github.com/tensorflow/tensorflow/issues/41448#issuecomment-756145318)

Any progress?

Any progress?

I think class weights can always be implemented via sample weights (see sklearn.utils.class_weight.compute_sample_weight). It seems like Keras does support sample weights for each output, so maybe using compute_sample_weight for each output can work? If you already have sample weights, I think you should be able to do weight = weight * new_weight (but someone with more of a statistics background should confirm this)

I think class weights can always be implemented via sample weights (see sklearn.utils.class_weight.compute_sample_weight). It seems like Keras does support sample weights for each output, so maybe using compute_sample_weight for each output can work? If you already have sample weights, I think you should be able to do weight = weight * new_weight (but someone with more of a statistics background should confirm this)

@adriangb Ostensibly, Keras does support class weights with multiple outputs, but the implementation is broken, as noted by the error message shown in this thread.  Its unclear to me if sklearn can be used in a tensorflow/keras training pipeline.  I find adding outside frameworks can be troublesome when exporting models to TF Serving.  But I may not have enough knowledge here.

@adriangb Ostensibly, Keras does support class weights with multiple outputs, but the implementation is broken, as noted by the error message shown in this thread.  Its unclear to me if sklearn can be used in a tensorflow/keras training pipeline.  I find adding outside frameworks can be troublesome when exporting models to TF Serving.  But I may not have enough knowledge here.

I'm not sure either. I'm just offering it as an alternative, but obviously it would still be nice if it got fixed.

I'm not sure either. I'm just offering it as an alternative, but obviously it would still be nice if it got fixed.

Did anyone have any luck with this issue here? The nested dictionary approach as suggested by @fchollet for class_weight earlier seems to be supported for TF 2.1.0 and earlier versions only.
A lot of people with such multi-label/multi-output problems seem to have raised this as a big (and unresolved) issue across many recent forums.

Keras is goind somewhere :( ... Not even a response from https://github.com/fchollet :(

I think class weights can always be implemented via sample weights (see sklearn.utils.class_weight.compute_sample_weight). It seems like Keras does support sample weights for each output, so maybe using compute_sample_weight for each output can work? If you already have sample weights, I think you should be able to do weight = weight * new_weight (but someone with more of a statistics background should confirm this)

Thanks @adriangb
This worked for me, I just wanted to adjust the weight on for the last class
from sklearn.utils.class_weight import compute_sample_weight
class_weight = [{0: 1, 1: 1}, {0: 1, 1: 1}, {0: 1, 1: 1}, {0: 0.8, 1: 1.1}]
sample_weight = compute_sample_weight(class_weight,labels)
Would be nice if Keras would accept the class_weight directly, but until then...

sample_weight is not supported when using tf.data.Dataset instances, so the need for class_weight with multilabel models remains.


Move flutter_gallery__transition_perf_e2e_ios32 and native_ui_tests_ios32 from staging to prod

These are consistently passing now with https://github.com/flutter/flutter/pull/76658 and https://github.com/flutter/flutter/pull/76800.
See https://github.com/flutter/flutter/issues/74920#issuecomment-785524603

\cc @godofredoc


Simplify F.swapaxes test

Simplifies test_swapaxes using testing.FunctionTestCase
Solves part of issue #6071

LGTM. Jenkins, test this please.

Jenkins CI test (for commit aa2a13cb3676b572c749565a5d91ff7c42bcf12d, target branch master) failed with status FAILURE.
(For contributors, please wait until the reviewer confirms the details of the error.)


pool needs additional capacity to support this workload

While deploying a demo app I got this error while even I'm not paying anything
(StopChatFlow(...), 'failed to deploy workload on node 72CP8QPhMSpF7MbSvNR1TYZFbTnbRiuyvq5xwcoRNAib due to error 402 Client Error: pool needs additional capacity to support this workload for url: https://explorer.testnet.grid.tf/api/v1/reservations/workloads')

The error message "failed to deploy workload on node 72CP8QPhMSpF7MbSvNR1TYZFbTnbRiuyvq5xwcoRNAib due to error" is only present in the dry_run method. Which means that a workload in network.network_resources failed to deploy to the error mentioned after it. This error is raised from here, it indicates that the pool doesn't have enough resources to deploy this workload for at least two minutes. But AFAIK network workloads doesn't incur any cost, so even an empty pool shouldn't fail because of lack of resources. So can network.network_resources contain workloads of types other than adding a node (or access) to a network? And if no, how the pool requirements for such workloads are calculated?

The failing workload: 478649.

I tried to add a new network on a newly created empty pool and it didn't fail! And it's shown in the "Deployed workloads" 479183.
code:
network = j.sals.zos.network.create('<IP_ADDRESS>/16', 'test_net_cap152')
j.sals.zos.network.add_node(network, '72CP8QPhMSpF7MbSvNR1TYZFbTnbRiuyvq5xwcoRNAib', "<IP_ADDRESS>/24", 1883)
wg_quick = j.sals.zos.network.add_access(network, '72CP8QPhMSpF7MbSvNR1TYZFbTnbRiuyvq5xwcoRNAib', "<IP_ADDRESS>/24", ipv4=True)
result = []
for resource in network.network_resources:
    result.append(j.sals.zos.workloads.deploy(resource))


[Issue 5553] [website] Add coding-guide page

Fixes #5553
Motivation
Lack of coding guide page on Pulsar website.
Modifications

Add coding guide.
Add coding-guide.js file.
Update footer.js file.

run java8 tests

@tuteng Thanks for your reminder. Updated. PTAL again.

run cpp tests


BOM sensor not working

Home Assistant release (hass --version):
50.0
Python release (python3 --version):
3.4
Component/platform:
RPI 3/AIO Install
Description of problem:
https://home-assistant.io/components/sensor.bom/
The sensor does not appear to work after 50.0 upgrade and its formatting in the frontend has changed
Expected:

Problem-relevant configuration.yaml entries and steps to reproduce:

Traceback (if applicable):

Additional info:

The weather frontend is for the weather platforms not the sensor. Use https://home-assistant.io/components/weather.buienradar/

And why can I not use the BOM weather platform which was working prior to 50.1 upgrade? Buienradar is a Netherlands based meteorlogical site and I am in Australia.

On 2 Aug 2017, at 6:17 pm, Fabian Affolter<EMAIL_ADDRESS>wrote:
The weather frontend is for the weather platforms not the sensor. Use https://home-assistant.io/components/weather.buienradar/ https://home-assistant.io/components/weather.buienradar/
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub https://github.com/home-assistant/home-assistant/issues/8751#issuecomment-319631220, or mute the thread https://github.com/notifications/unsubscribe-auth/AdLnQj8U4GCP8rdllmgN3oprUms81kEYks5sUEyegaJpZM4OogDF.

??? BOM was working fine prior to 50.1 upgrade  - and the fix is to refer me to another meteorological site in the Netherlands?


build failed for OSX in release mode

Building in release mode fails in OSX. The library mimalloc is built successfully in release mode, however, linking to it causes failure in the compilation of wolf.

Building in release mode fails in OSX. The library mimalloc is built successfully in release mode, however, linking to it causes failure in the compilation of wolf.

kindly make sure pull the latest commit.

When I run the command cargo run --release, the building fails with the following error:
warning: /Users/siminbadri/ALPHA/Wolves/WolfEngine/wolf/Cargo.toml: unused manifest key: build
   Compiling wolfengine v3.0.3 (/Users/siminbadri/ALPHA/Wolves/WolfEngine/wolf)
error: could not find native static library `mimalloc-minsizerel`, perhaps an -L flag is missing?

error: could not compile `wolfengine` due to previous error

Running the above command changes the OPT_LEVEL environment variable to either "s" or "z". This change forces the cmake to build the library for MinSizeRel mode. Regarding the file wolf/build.rs, the library that will be linked to wolf should have the name mimalloc-minsizerel. However, the name of the built library of mimalloc is libmimalloc.a
Note that this built library is located at the path:
/WolfEngine/wolf/sys/build/MinSizeRel/_deps/mimalloc-static-build/libmimalloc.a

Building in release mode fails in OSX. The library mimalloc is built successfully in release mode, however, linking to it causes failure in the compilation of wolf.

kindly make sure pull the latest commit.

I cloned this repo with depth set to 1 and then tried to build it. In debug mode, the wolf is built successfully and the demo runs too. However, building in release mode fails with the error mentioned here.

It seems that linking to mimalloc is useless. I changed the file wolf/build.rs and removed the linking to the library mimalloc. Now, wolf is built and running successfully in both release and debug mode for osx.
I applied this change as a pull request in the commit here.

This issue is fixed in this commit.


Feature: Tutorial updates and Auth Imports Reorg

#75 opened to track the security issue with rsa.


Feature: cache busting

When using Ionic as a web app, cache busting is essential to make sure your users are always running the latest version.
The best way to do this is by appending a hash to filenames in the build phase. This will make sure that any changed files will be instantly refetched by the browser, but it can safely cache everything that hasn't changed.
The Angular CLI does a great job at this and I would love to see support for this in Ionic. For the JS and CSS files, but also for other assets like images and fonts.
cc @jasekiw who asked questions about this in #201

Hello! I have reopened issue #201 as it was a misunderstanding on my part. Sorry about that! I am going to close this one for now as a duplicate of #201 . Thanks!


Change demodulated function

We just need ID of the phone and not the cellPhone entirely

No ID does not deserve, we need phone for debuging function and it doesn't change speed of code if you change this. DON'T DO THIS, IT WORKS !

btw arguments are passed as reference, so dont consume memory.....

You right but it oblige us to traverse all table of mobile each time we print something on screen.

you don't have to use the demodulate function to print something on screen, and you don't have to parse the table of mobile each time you use the demodulate function, if you want to demodulate the signal for one mobile just call the demodulate function with listMobile[id]

Ok i see, I'll test it. Thanks
--
Victor SENE
Le 7 juin 2017 07:30, "Glangine Geoffrey"<EMAIL_ADDRESS>a
écrit :

you don't have to use the demodulate function to print something on
screen, and you don't have to parse the table of mobile each time you use
the demodulate function, if you want to demodulate the signal for one
mobile just call the demodulate function with listMobile[id]
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/Vskilet/UMTS-Multiplexing/issues/1#issuecomment-306690886,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AHUmf6yMYxQVKcZPJKsbg24ji_LEnr_Hks5sBjV_gaJpZM4NxruQ
.


[Bug] Schema builder - renameColumn fails on table with enum columns

Example code:
Schema::create('presentations', function($table)
{
...
	$table->enum('repeat_unit', array('DAY', 'WEEK', 'MONTH', 'YEAR'))->default('DAY');
...
});

Schema::table('presentations', function($table)
{
	$table->renameColumn('created', 'created_at');
});

Result:

[Doctrine\DBAL\DBALException]
Unknown database type enum requested, Doctrine\DBAL\Platforms\MySqlPlatform may not support it.

Is there any improvement in this issue? I'm having the same problem here. :(

I'm new to Laravel and I'm currently scratching my head over, what I presume, is the same issue.  In my case the datatype it's complaining about is a 'point' which isn't even the field I'm trying to rename.

@kebian the docs are still incorrect, reading my last comments you'll see that you can't rename any columns on tables which contain enums

@upngo That does indeed seem to be the case, however my table doesn't contain any enum columns but does contain a geospatial "point" field.  Perhaps the bug is with any non-standard field types.

I've noticed a lot of these issues are specifically related to using the renameColumn() method. However, it's also an issue when using change() (yes, even when the column being changed is not an ENUM).
Seems the most convenient way around this (but by no means the best way) is to drop the column and re-create... unless/until Laravel is updated with a work-around or Doctrine gets updated.

@simonhamp alternative to dropping (and losing all rows) would be to just use a raw query in whatever db language you're using
@kebian yes this is the case, if you see the comment at the top of the page from @shnhrrsn it's that DBAL doesnt know enum and probably not point either, the work around was to tell mysql it's just a string.
This issue isn't going anywhere though -> unsubscribing.

@upngo good point. Will do that in future

Hit this issue today on Laravel 5 and dbal 2.5.1, can't call change on any column if my table has any enum or point columns in it.

This is something I could not believe at first. But thanks to Paul Bill I did it as following
public function up()
{
	Schema::table('projects', function(Blueprint $table)
	{
           DB::statement('ALTER TABLE projects CHANGE slug url VARCHAR(200)');
	});
}

public function down()
{
	Schema::table('projects', function(Blueprint $table)
	{
           DB::statement('ALTER TABLE projects CHANGE url slug VARCHAR(200)');
	});
}

Follow up to this problem as I had it too...
I figured out fairly simple solution at least to my case.
As @malcolmhall said, it was not letting me update ANY columns in my table if that table had an enum in it.
If I moved the renaming unto it's own function instead of trying to include it with the rest of my migration it worked. For example....
Changed A Migration Like This
public function up()
{
   Schema::table('mytable', function(Blueprint $table) {
      $table->dropColumn('randomColumn');
      $table->string('newColumn', 25)->after('id');
      $table->renameColumn('oldColumnName', 'newColumnName');
   });
}

To this
public function up()
{
   Schema::table('mytable', function(Blueprint $table) {
      $table->dropColumn('randomColumn');
      $table->string('newColumn', 25)->after('id');
   });

   Schema::table('mytable', function(Blueprint $table) {
      $table->renameColumn('oldColumnName', 'newColumnName');
   });

}

By moving the renaming of columns to it's own function it seemed to work. The crazy part is NONE of the fields in my example are enum fields, but since the table contains enum fields I was getting this error.

when I tried to use change got same issue on laravel 5 and doctrine/dbal 2.5.0.

I've fixed this for hook with a pretty ugly workaround: https://github.com/doubleleft/hook/blob/2ffde1352649513919b51bb591f0668f70a37925/src/Database/Schema/Builder.php#L397-L435
Hope it helps!

Still hitting this issue 3 years later, having to use the manual DB statement solution which is a shame.

3 years later and Doctrine hasn't fix this issue which is a shame.

My simple solution was to use raw SQL.
public function up()     {         DB::statement('ALTER TABLE kois ALTER doitsu SET DEFAULT 0');         DB::statement('ALTER TABLE kois ALTER male SET DEFAULT 0');     }

running into the same issue with a json blob on the table :(

still no fix...

@taylorotwell

Just to clarify @reedmaniac 's path, I changed it here: vendor/doctrine/dbal/lib/Doctrine/DBAL/Platforms/MySqlPlatform.php

I too just came into this issue 2 days ago. ENUM is widely used and I can't, in any way shape or form, understand why someone would think it should not be supported. Nor did I realize this was an issue that clearly causing some issues and has been sat on for over 3 years.... In most organizations someone would come under serious scrutiny for it.

Is there a reason this isn't getting fixed? These kinds of 3-year-still-not-fixed bugs are just insane.

@peppy if you have a fix in mind you can open a PR.

This worked for me in laravel 5.2 with<EMAIL_ADDRESS>. When you have an enum on your table and you want to change any of the columns on the table you will have to:
 public function up()
    {
       Schema::getConnection()->getDoctrineSchemaManager()->getDatabasePlatform()->registerDoctrineTypeMapping('enum', 'string');

        Schema::table('jobs', function(Blueprint $table)
        {
            $table->decimal('latitude', 10, 6)->nullable()->change();
        });
    }

@henritoivar well this solved my issue! what a crazy hack.

@crynobone Can you explain why you feel Doctrine should fix this? Laravel's Blueprint class offers both a enum() and a renameColumn() method, yet they cannot be used in combination.

Can you explain why you feel Doctrine should fix this?

My response is to response to "Still hitting this issue 3 years later, having to use the manual DB statement solution which is a shame.", Don't put the blame on Laravel when it's been 3 years and Doctrine still hasn't solved it.
Besides that, monkey-patching is never a good solution (which was questioned by Taylor), and Taylor himself mention this at the very first reply.
renameColumn() highly depends on Doctrine, enum() doesn't.

If you come across this comment, I think this will help you.
You must have same question as I and other think about this problem and don't want to use DB statement. I'm in same boat as you so I search all in google and found solution that I think it is best practise right now. I use Laravel 5.3. Current DBAL hash some update and depend on @henritoivar solution only is not work. DBAL will throw error that you need to define type in DBAL. They need sql processor.
First. Please read all this page. http://doctrine-orm.readthedocs.io/projects/doctrine-orm/en/latest/cookbook/mysql-enums.html
This is doc that talk about why doctrine don't implement about enum on it.
Second. I will keep it short. This is my implement.
<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
use Doctrine\DBAL\Types\Type;

class AlterCartCustomersMakeGenderNullable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::getConnection()->getDoctrineSchemaManager()->getDatabasePlatform()->registerDoctrineTypeMapping('enum', 'string');

        Type::addType('enum', \Extended\Doctrine\DBAL\Types\GenderEnumType::class);

        Schema::table('cart_customers', function(Blueprint $table) {
            // add nullable
            // must call change to tell we change field attribute
            $table->enum('gender', ['male', 'female'])->nullable()->change();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::getConnection()->getDoctrineSchemaManager()->getDatabasePlatform()->registerDoctrineTypeMapping('enum', 'string');

        Type::addType('enum', \Extended\Doctrine\DBAL\Types\GenderEnumType::class);

        Schema::table('cart_customers', function(Blueprint $table) {
            // revert nullable
            $table->enum('gender', ['male', 'female'])->nullable(false)->change();
        });
    }
}

<?php

namespace Extended\Doctrine\DBAL\Types;

use Doctrine\DBAL\Types\Type;
use Doctrine\DBAL\Platforms\AbstractPlatform;

class EnumType extends Type
{
    protected $name;
    protected $values = array();

    public function getSQLDeclaration(array $fieldDeclaration, AbstractPlatform $platform)
    {
        $values = array_map(function($val) { return "'".$val."'"; }, $this->values);

        return "ENUM(".implode(", ", $values).")";
    }

    public function convertToPHPValue($value, AbstractPlatform $platform)
    {
        return $value;
    }

    public function convertToDatabaseValue($value, AbstractPlatform $platform)
    {
        if (!in_array($value, $this->values)) {
            throw new \InvalidArgumentException("Invalid '".$this->name."' value.");
        }
        return $value;
    }

    public function getName()
    {
        return $this->name;
    }

    public function requiresSQLCommentHint(AbstractPlatform $platform)
    {
        return true;
    }
}

<?php

namespace Extended\Doctrine\DBAL\Types;

class GenderEnumType extends EnumType
{
    protected $values = array('male', 'female');
}

After you saw these files.  Problem is DBAL don't receive another attribute so I cannot pass enum values to it.

Still not solved ?
Oups I have to switch from ENUM to int with a default value set to 0

Can someone managing this GitHub repository please summarize the current state of this issue?
My own opinion is that sure, monkey patching isn't desirable, but it's quite often necessary in our field. Newcomers to Laravel are hitting this problem in large numbers. This is bad for the reputation of the product.
Yes Doctrine should fix it, but it has been three years. Now it falls on the Laravel framework to create an intuitive development experience for its users.
(PS - this is an amazing framework and thank you everyone for your contributions to it. I'm sure we can find a solution for this simple problem.)

@zschuessler feel free to make a PR to fix the issue if you can do it.

wow!  I didn't knew that its an 3 years old issue until i faced the issue myself. Though my table don't have any enum column. still facing this issue.

For who found this problem, next time I think use INT field is better solution. After I try to think why DBAL don't do it. If I'm in same boat, I will do same too because their design pattern don't allow them to implement ENUM.
If I can forecast or see future, this problem will stay same in 4 or 5 years. LOL
GL HF.
PS. Currently I like INT field better because I can use bitwise to store more than single value in one field.

In databases it is not a good idea to store multiple pieces of information in one field because it can't be indexed and is slower to query.

@taylorotwell does this issue still exist?

@jycr753 yes.

In Illuminate\Database\Connection would it be possible to do something like the following in the getDoctrineConnection() method?
$this->doctrineConnection = new DoctrineConnection($data, $driver);
// New code here
if(!is_null($this->getConfig('mapping_types'))) {
    $dbPlatform = $this->doctrineConnection->getSchemaManager()->getDatabasePlatform();
    foreach($this->getConfig('mapping_types') as $dbType => $doctrineType) {
        $dbPlatform->registerDoctrineTypeMapping($dbType, $doctrineType);
    }
 }

Users would then add a 'mapping_types' => [] parameter to their database settings in config/database.php, i.e.:
'mapping_types' => [
                'enum'  =>  'string',
                'json'  =>  'json_array',
            ]

Just trying to get some insight if that might break anything before I do a PR. Have done the changes locally on 5.3 and it allows me to update columns on tables with the json type. Thanks for the awesome framework, been a joy to work with so far.

OK So I was too lazy to figure out where in my local code to permanently put the code snippet from  @johndslone, but what I did discover is you can put a modified version of it at the top of a specific migration file and it will work.
    $connection = DB::connection();
    $doctrineConnection = $connection->getDoctrineConnection();
    // New code here
    if (!is_null($connection->getConfig('mapping_types'))) {
        $dbPlatform = $doctrineConnection->getSchemaManager()->getDatabasePlatform();
        foreach ($connection->getConfig('mapping_types') as $dbType => $doctrineType) {
            $dbPlatform->registerDoctrineTypeMapping($dbType, $doctrineType);
        }
    }

and 1 additional comment, you have to put the mapping_types array in the specific connection entry of config/database.php not just as a new top level entry (It wasn't clear to me on first try).

Heck here's an even more temporary one
    $map = [
        'enum' => 'string',
    ];
    $connection = DB::connection();
    $doctrineConnection = $connection->getDoctrineConnection();
    // New code here
    $dbPlatform = $doctrineConnection->getSchemaManager()->getDatabasePlatform();
    foreach ($map as $dbType => $doctrineType) {
        $dbPlatform->registerDoctrineTypeMapping($dbType, $doctrineType);
    }

Please reopen issue!
Laravel v5.4.25
problem still exists

@ISaidHey Yeah, all that code comes from the workarounds mentioned earlier in the thread. Was just integrating it to a bit more 'permanent' method that would work out of the box. I tend to just use ALTER TABLE statements in my own migrations that involve changes on tables, but I can understand the desire from users to still be able to write migrations using the tools in the documentation.
It creates a bit of a mental disconnect when you can $table->json() add a column, but would be unable to use any change() commands later on because of it. [Not that it's Laravel's fault, since it's an issue with the underlying dbal library]
(The files you would need to edit are in the vendor/src directory - it's just a proof of concept so I could reinstall the original composer files once I was done playing with it)

Its sad that issues like this still plague Laravel.

I hit a similar issue while trying to update columns with a postgis geometry while installing Voyager, there's a workaround described here for  laravel-generator although I haven't managed to make it work yet.

I ended up using @ISaidHey 's suggestion, this is my take:
config/database.php
//....
   'types_mapping' => [
        'ltree' => 'string',
    ],

app/Providers/AppServiceProvider.php
class AppServiceProvider extends ServiceProvider
{
    public function boot()
    {
        // add DBAL Types
        $this->addDBALTypes();
    }
    public function addDBALTypes()
    {
        $connection = DB::connection();
        if (App::runningInConsole()) {
            //workaround for php artisan migrate --database=
            if (isset($_SERVER['argv'][2]) && strpos($_SERVER['argv'][2], '--database=') == 0) {
                $connection = DB::connection(str_replace('--database=', '', $_SERVER['argv'][2]));
            }
        }
        $doctrineConnection = $connection->getDoctrineConnection();
        $dbPlatform = $doctrineConnection->getSchemaManager()->getDatabasePlatform();
        foreach (config('database.types_mapping', []) as $dbType => $doctrineType) {
            $dbPlatform->registerDoctrineTypeMapping($dbType, $doctrineType);
        }
    }
}

I believe it wouldn't hurt if laravel could parse the types_mapping array by default in the migrate command

@henritoivar thanks a lot!

This still exists, just downloaded Laravel 5.5.18.
I think the bug is bad enough but the misleading error message is worse, given that i'm not even trying to rename the enum column in my table.
[Doctrine\DBAL\DBALException]
Unknown database type enum requested, Doctrine\DBAL\Platforms\MySQL57Platform may not support it.

Still an issue in 5.5.24. Trying to rename a integer column where the table contains enum.

not sure why people keep commenting on the laravel version. it is not a laravel problem it is a DBAL problem which is an entirely different package.

not sure why people keep commenting on the laravel version. it is not a laravel problem it is a DBAL problem which is an entirely different package.

@itsmill3rtime likely because they've only encountered it in Laravel and people expect limitations to be lifted as framework versions increase over time.
Regardless, it appears the DBAL may never support this, as explained in their docs. FWIW, that link does document some workarounds.

The question is, if a package selected by the framework doesn't operate in the manner the framework audience assumes, why hasn't the framework maintainers done anything to replace the package or patch the framework to account for this issue?
You can say this is a DBAL issue all you want but it doesn't account for Laravel's migration system breaking because of their package choice.  The issue is going on 5 years now and I've run into it more times than I can count.  I've now also discovered that the workarounds don't fix adding nullable() to a column.  If I need to do this I must drop columns (and write a transition if I can't nuke the data) or not use a column type that they have explicitly included in multiple iterations of their documentation.  Nowhere do they describe this issue there to prevent the runaround that invariably follows.  This is bad code maintenance and one of the main reasons I no longer consider this framework for new projects.  I've spent countless hours working around this and it seems they can develop new features, refactor the entire framework and write countless blogs about their updates yet they can't fix this core issue and don't even let new users know it exists.

Gotta say there are some silly comments on this thread.
If you’re not using the framework anymore why are you bothering to write a tirade on here about why it doesn’t work for you?
Also, these are free, open source projects. That means 2 things:

The developers don’t get an immediate financial reward/incentive to help contribute towards ongoing development. Any funds they do get usually barely covers the investment they’ve already made and is likely going towards more big-hitting features that will benefit many more people (you included).

There’s nothing and no one stopping you from writing your own alternative based on DBAL or Laravel that works the way you want it to.  It literally only takes some time and a little effort.

So it really is pointless coming on here just to vent about that thing you want for those occasional projects that need it that clearly many folks can go without.
And it’s a bit childish to slam a perfectly good framework that is working very well in a lot of cases for a lot of people because you have a little issue that’s been around for a few years.
A lot of things have been failing for a lot longer than DBAL hasn’t been able to edit tables with enum columns. I mean my toaster still can’t toast 2 pieces of bread consistently on the same setting. That’s been at least 30 years. Let’s keep some perspective.

I see no harm in these discussion threads, personally.
Is this not a good gauge of how many people are potentially relying on this feature from a framework that is otherwise "working very well in a lot of cases"?
As a repository maintainer or potential contributor, it would let me know that maybe I should consider reopening the issue with the possibility of a localised workaround, even if my own project wasn't the one at fault.

Actually not only ENUM not working in migrations, you also cannot use SET, MEDIUMBLOB, LONGBLOB, etc. Thus out the box standard migrations are unuseful in real big projects, unfortunately.
Another solution (with own cons of course) - you can use MySQL Workbench to create migration.sql and run in inside laravel migrations, but you need split SQL file into single queries (jdorn/sql-formatter can do that, but this package a little outdated)

@peppy As an unpaid repository maintainer or potential contributor, are you more or less likely to do so if you happen to read the occasional troll comment on a closed issue OR if you can see a clear and definitive trend by way of hundreds of comments, votes., issues, blog posts, tweets?
There’s no such justification that this issue should be given that kind of attention in this case from what I can see.

@simonhamp there's no trolling going on in this thread. People are posting because it's a genuine issue when you cannot run your migrations because Laravel isn't providing a simple function that could work around the issue like @G3z suggested.

@adriennn it looks like the particular comment I was responding to has been removed. So it seems some people are using this thread as an opportunity to have a dig at Laravel, even personally "attacking" the maintainers.
I agree, this is an issue that I would like to see fixed. I have faced it and it catches me out on those odd occasions, but there's no need to lose one's rag and start attacking people over it.
The fact is that there are ways around it and it's not a major issue afflicting thousands of developers on a daily basis, so just being realistic, I can see why other issues would take priority :)

@adriennn, this simple function is not a solution, because it fixes only "Unknown database type enum requested" message, but change() migration will not works and you still needed Schema::getConnection()->statement(ALTER TABLE ...). So this is more complicated bug :(

@simonhamp roger, didn't see that post.
@LastDragon-ru well if it's a more complicated issue, it proves my above point, I ended up adding 'geom' to the conversion list suggested in that fix and I think/hope it has fixed my problem... let's see for how long...

OP is now working with PHP7.1 and DBAL >= 2.7

I'm using Laravel 5.7 with Mariadb and wrote this migration. It worked for me.
    public function up()
    {
        $options = implode("','", MediationStatus::getValues());
        $defaulf = MediationStatus::Opened;
        $raw_sql = "ALTER TABLE mediation.mediations
                    MODIFY COLUMN status ENUM('{$options}')
                    DEFAULT '{$defaulf}' NOT NULL";
        DB::statement($raw_sql);
    }

FIXED !
ONE LINER ....
Either put it into an AppServiceProvider or into your migrations:
\Doctrine\DBAL\Types\Type::addType('enum', \Doctrine\DBAL\Types\StringType::class);
For the lazy ones out there:
App/Providers/DatabaseServiceProvider
<?php

namespace App\Providers;

use Doctrine\DBAL\Types\StringType;
use Doctrine\DBAL\Types\Type;
use Illuminate\Support\ServiceProvider;

class DatabaseServiceProvider extends ServiceProvider
{
    public function register()
    {
        Type::addType('enum', StringType::class);
    }
}

app/bootstrap/app.php
 $app->register(App\Providers\DatabaseServiceProvider::class);
Hope this helps someone and saves precious time I wasted reading thru a lot of discussion...
In the end  none of the suggested solutions worked and doctrines error message pointed me into the right direction

Anyone using @pinkal-vansia's solution of writing alter statements, keep in mind your field length. Unless you've overwritten it, the default string length is 255 characters. If you are renaming a string field, be sure to double check that you're not truncating some data or unexpectedly altering a field.
If you have a look at the BluePrint string function it either accepts the length in the second parameter or uses Illuminate\Database\Schema\Builder::$defaultStringLength, which is currently set to 255. You can either use that number in your migrations or simply altere the previously pasted statement like so:
public function up()
{
    Schema::table('projects', function(Blueprint $table)
    {
           DB::statement('ALTER TABLE projects CHANGE slug url VARCHAR(255)');
    });
}

public function down()
{
    Schema::table('projects', function(Blueprint $table)
    {
           DB::statement('ALTER TABLE projects CHANGE url slug VARCHAR(255)');
    });
}

I ended up using @ISaidHey 's suggestion, this is my take:
config/database.php
//....
   'types_mapping' => [
        'ltree' => 'string',
    ],

app/Providers/AppServiceProvider.php
class AppServiceProvider extends ServiceProvider
{
    public function boot()
    {
        // add DBAL Types
        $this->addDBALTypes();
    }
    public function addDBALTypes()
    {
        $connection = DB::connection();
        if (App::runningInConsole()) {
            //workaround for php artisan migrate --database=
            if (isset($_SERVER['argv'][2]) && strpos($_SERVER['argv'][2], '--database=') !== false) {
                $connection = DB::connection(str_replace('--database=', '', $_SERVER['argv'][2]));
            }
        }
        $doctrineConnection = $connection->getDoctrineConnection();
        $dbPlatform = $doctrineConnection->getSchemaManager()->getDatabasePlatform();
        foreach (config('database.types_mapping', []) as $dbType => $doctrineType) {
            $dbPlatform->registerDoctrineTypeMapping($dbType, $doctrineType);
        }
    }
}

I believe it wouldn't hurt if laravel could parse the types_mapping array by default in the migrate command

Thank you very much, this solution worked perfectly.
I'm working with Laravel 5.8. and I was trying to generate an automatic model from a table with enum fields (https://github.com/krlove/eloquent-model-generator)

I see that in Laravel 6 that has been released recently, there is still this non-sense in the documentation.
I think that 1 viable solution for those who have data in their tables would be:

create a new varchar column enum_col_2
copy the data from enum_col
drop the enum_col
rename your column
recreate the old enum_col
copy the data from enum_col_2 to  enum_col
drop the enum_col_2

And this will NEVER implemented? @Vusys ?


feat: add support to resolve dns to ipns

This PR also normalizes ipns name resolve return value and offline options, to integrate better with http client and ipfs core.

Is this ready for a re-review @hugomrdias or are there more commits you want to add? 😁

Create an issue for the ping problem in js-ipfs
https://github.com/ipfs/js-ipfs/issues/2186


Arbitrary endpoint support.

Right now we are having a hard dependency on TCP sockets through epoll, poll or iocp for our endpoints. We need the ability to let the users plug their own endpoints instead.

I am assuming this can be closed (?)


gccgo: big increase in compile time of cmplxdivide.go results in test timeout on ppc64le

The test cmplxdivide.go recently had a dramatic increase in compile time, resulting in a compile timeout for the test:
Executing on host: /home/boger/gccgo.git/bld/gcc/testsuite/go/../../gccgo -B/home/boger/gccgo.git/bld/gcc/testsuite/go/../../ /home/boger/gccgo.git/gcc/gcc/testsuite/go.test/test/cmplxdivide.go /home/boger/gccgo.git/gcc/gcc/testsuite/go.test/test/cmplxdivide1.go   -fdiagnostics-plain-output  -I/home/boger/gccgo.git/bld/powerpc64le-linux/./libgo   -pedantic-errors  -L/home/boger/gccgo.git/bld/powerpc64le-linux/./libgo -L/home/boger/gccgo.git/bld/powerpc64le-linux/./libgo/.libs  -lm  -o ./cmplxdivide.o    (timeout = 300)
spawn -ignore SIGHUP /home/boger/gccgo.git/bld/gcc/testsuite/go/../../gccgo -B/home/boger/gccgo.git/bld/gcc/testsuite/go/../../ /home/boger/gccgo.git/gcc/gcc/testsuite/go.test/test/cmplxdivide.go /home/boger/gccgo.git/gcc/gcc/testsuite/go.test/test/cmplxdivide1.go -fdiagnostics-plain-output -I/home/boger/gccgo.git/bld/powerpc64le-linux/./libgo -pedantic-errors -L/home/boger/gccgo.git/bld/powerpc64le-linux/./libgo -L/home/boger/gccgo.git/bld/powerpc64le-linux/./libgo/.libs -lm -o ./cmplxdivide.o^M
WARNING: program timed out
compiler exited with status 1
exit status is 1
FAIL: go.test/test/cmplxdivide.go

This started happening after this change:
commit cd34d5f2c40f3c65407f4b0bee0b49fc84e4a4ab
Author: Ian Lance Taylor<EMAIL_ADDRESS>Date:   Tue Dec 1 18:59:18 2020 -0800

    compiler: defer to middle-end for complex division

    Go used to use slightly different semantics than C99 for complex division,
    so we used runtime routines to handle the different.  The gc compiler
    has changes its behavior to match C99, so changes ours as well.

    For golang/go#14644

    Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/274213

The compile now takes > 5m. Prior to the commit, it took about 12s.

On my x86 laptop building the test takes about 30 seconds.  With the GCC 10 test took about 4 seconds.
I think the key change here is not the change to the compiler, but the change to the test.  The test used to have a lot of references to the constant 0.  Now they refer to the variable zero.  That seems to slow things down a fair amount.
Unfortunately I don't see a quick fix.

I did a profile and it now shows this:
  31.42%  go1       go1                        [.] bitmap_clear_bit                                              ◆
  27.88%  go1       go1                        [.] assign_by_spills                                              ▒
  25.15%  go1       go1                        [.] bitmap_set_bit                                                ▒
   8.21%  go1       go1                        [.] insert_in_live_range_start_chain                              ▒

I didn't realize the test was changed. If the increase is expected, is there a way the timeout can be increased just for this test?

I did a profile and it now shows this:
  31.42%  go1       go1                        [.] bitmap_clear_bit                                              ◆
  27.88%  go1       go1                        [.] assign_by_spills                                              ▒
  25.15%  go1       go1                        [.] bitmap_set_bit                                                ▒
   8.21%  go1       go1                        [.] insert_in_live_range_start_chain                              ▒

I didn't realize the test was changed. If the increase is expected, is there a way the timeout can be increased just for this test?

If the test really takes 5 minutes to compile on PPC, we may just want to skip it for now.
Just in case it helps, can you compile the test with -ftime-report and show us the passes that take the most time?  Thanks.

If the test really takes 5 minutes to compile on PPC, we may just want to skip it for now.
Just in case it helps, can you compile the test with -ftime-report and show us the passes that take the most time?  Thanks.

Skipping it is fine. I will ask someone on the gcc team about this. Here is the report.
[boger@trout test]$ gccgo -ftime-report cmplxdivide.go cmplxdivide1.go

Time variable                                   usr           sys          wall           GGC
 phase parsing                      :   0.24 (  0%)   0.00 (  0%)   0.24 (  0%)  8536k (  4%)
 phase opt and generate             : 400.72 (100%)   0.18 (100%) 400.87 (100%)   186M ( 96%)
 garbage collection                 :   0.28 (  0%)   0.00 (  0%)   0.29 (  0%)     0  (  0%)
 dump files                         :   0.00 (  0%)   0.01 (  6%)   0.01 (  0%)     0  (  0%)
 callgraph construction             :   0.01 (  0%)   0.00 (  0%)   0.01 (  0%)  2161k (  1%)
 callgraph optimization             :   0.01 (  0%)   0.00 (  0%)   0.01 (  0%)     0  (  0%)
 callgraph ipa passes               :   0.62 (  0%)   0.06 ( 33%)   0.67 (  0%)  5612k (  3%)
 ipa dead code removal              :   0.00 (  0%)   0.00 (  0%)   0.02 (  0%)     0  (  0%)
 ipa inlining heuristics            :   0.01 (  0%)   0.00 (  0%)   0.00 (  0%)     0  (  0%)
 CFG verifier                       :   0.64 (  0%)   0.00 (  0%)   0.62 (  0%)     0  (  0%)
 trivially dead code                :   0.06 (  0%)   0.00 (  0%)   0.06 (  0%)     0  (  0%)
 df scan insns                      :   0.04 (  0%)   0.00 (  0%)   0.04 (  0%)  3264  (  0%)
 df live regs                       :   0.04 (  0%)   0.00 (  0%)   0.05 (  0%)     0  (  0%)
 df reg dead/unused notes           :   0.05 (  0%)   0.00 (  0%)   0.06 (  0%)  3416k (  2%)
 register information               :   0.01 (  0%)   0.00 (  0%)   0.02 (  0%)     0  (  0%)
 alias analysis                     :   0.02 (  0%)   0.00 (  0%)   0.02 (  0%)  4112k (  2%)
 rebuild jump labels                :   0.02 (  0%)   0.00 (  0%)   0.02 (  0%)     0  (  0%)
 parser (global)                    :   0.24 (  0%)   0.00 (  0%)   0.24 (  0%)  8535k (  4%)
 inline parameters                  :   0.02 (  0%)   0.00 (  0%)   0.02 (  0%)  7088  (  0%)
 tree gimplify                      :   0.06 (  0%)   0.00 (  0%)   0.05 (  0%)    10M (  5%)
 tree CFG construction              :   0.01 (  0%)   0.00 (  0%)   0.00 (  0%)    93k (  0%)
 tree SSA rewrite                   :   0.00 (  0%)   0.00 (  0%)   0.01 (  0%)  2555k (  1%)
 tree SSA other                     :   0.00 (  0%)   0.03 ( 17%)   0.03 (  0%)  4944  (  0%)
 tree operand scan                  :   0.01 (  0%)   0.02 ( 11%)   0.03 (  0%)  3010k (  2%)
 tree SSA verifier                  :   0.34 (  0%)   0.02 ( 11%)   0.30 (  0%)     0  (  0%)
 tree STMT verifier                 :   0.40 (  0%)   0.00 (  0%)   0.46 (  0%)     0  (  0%)
 callgraph verifier                 :   0.02 (  0%)   0.00 (  0%)   0.02 (  0%)     0  (  0%)
 dominance computation              :   0.01 (  0%)   0.00 (  0%)   0.00 (  0%)     0  (  0%)
 expand vars                        :   0.02 (  0%)   0.00 (  0%)   0.01 (  0%)  4723k (  2%)
 expand                             :   0.14 (  0%)   0.00 (  0%)   0.16 (  0%)    29M ( 15%)
 post expand cleanups               :   0.02 (  0%)   0.00 (  0%)   0.01 (  0%)    21k (  0%)
 integrated RA                      :   1.89 (  0%)   0.02 ( 11%)   1.90 (  0%)    25M ( 13%)
 LRA non-specific                   :   2.23 (  1%)   0.01 (  6%)   2.29 (  1%)    54M ( 28%)
 LRA virtuals elimination           :   0.24 (  0%)   0.02 ( 11%)   0.21 (  0%)   682k (  0%)
 LRA reload inheritance             :   0.45 (  0%)   0.00 (  0%)   0.46 (  0%)   582k (  0%)
 LRA create live ranges             :   2.15 (  1%)   0.00 (  0%)   2.14 (  1%)  3804k (  2%)
 LRA hard reg assignment            : 389.11 ( 97%)   0.05 ( 28%) 389.13 ( 97%)     0  (  0%)
 LRA coalesce pseudo regs           :   0.02 (  0%)   0.00 (  0%)   0.03 (  0%)     0  (  0%)
 reload                             :   0.01 (  0%)   0.00 (  0%)   0.01 (  0%)     0  (  0%)
 thread pro- & epilogue             :   0.20 (  0%)   0.00 (  0%)   0.19 (  0%)   212k (  0%)
 shorten branches                   :   0.07 (  0%)   0.00 (  0%)   0.06 (  0%)   330k (  0%)
 final                              :   0.56 (  0%)   0.00 (  0%)   0.54 (  0%)   861k (  0%)
 rest of compilation                :   0.45 (  0%)   0.00 (  0%)   0.42 (  0%)    40M ( 21%)
 verify RTL sharing                 :   1.10 (  0%)   0.00 (  0%)   1.16 (  0%)     0  (  0%)
 TOTAL                              : 400.96          0.18        401.11          195M

Skipping it is fine. I will ask someone on the gcc team about this. Here is the report.
[boger@trout test]$ gccgo -ftime-report cmplxdivide.go cmplxdivide1.go

Time variable                                   usr           sys          wall           GGC
 phase parsing                      :   0.24 (  0%)   0.00 (  0%)   0.24 (  0%)  8536k (  4%)
 phase opt and generate             : 400.72 (100%)   0.18 (100%) 400.87 (100%)   186M ( 96%)
 garbage collection                 :   0.28 (  0%)   0.00 (  0%)   0.29 (  0%)     0  (  0%)
 dump files                         :   0.00 (  0%)   0.01 (  6%)   0.01 (  0%)     0  (  0%)
 callgraph construction             :   0.01 (  0%)   0.00 (  0%)   0.01 (  0%)  2161k (  1%)
 callgraph optimization             :   0.01 (  0%)   0.00 (  0%)   0.01 (  0%)     0  (  0%)
 callgraph ipa passes               :   0.62 (  0%)   0.06 ( 33%)   0.67 (  0%)  5612k (  3%)
 ipa dead code removal              :   0.00 (  0%)   0.00 (  0%)   0.02 (  0%)     0  (  0%)
 ipa inlining heuristics            :   0.01 (  0%)   0.00 (  0%)   0.00 (  0%)     0  (  0%)
 CFG verifier                       :   0.64 (  0%)   0.00 (  0%)   0.62 (  0%)     0  (  0%)
 trivially dead code                :   0.06 (  0%)   0.00 (  0%)   0.06 (  0%)     0  (  0%)
 df scan insns                      :   0.04 (  0%)   0.00 (  0%)   0.04 (  0%)  3264  (  0%)
 df live regs                       :   0.04 (  0%)   0.00 (  0%)   0.05 (  0%)     0  (  0%)
 df reg dead/unused notes           :   0.05 (  0%)   0.00 (  0%)   0.06 (  0%)  3416k (  2%)
 register information               :   0.01 (  0%)   0.00 (  0%)   0.02 (  0%)     0  (  0%)
 alias analysis                     :   0.02 (  0%)   0.00 (  0%)   0.02 (  0%)  4112k (  2%)
 rebuild jump labels                :   0.02 (  0%)   0.00 (  0%)   0.02 (  0%)     0  (  0%)
 parser (global)                    :   0.24 (  0%)   0.00 (  0%)   0.24 (  0%)  8535k (  4%)
 inline parameters                  :   0.02 (  0%)   0.00 (  0%)   0.02 (  0%)  7088  (  0%)
 tree gimplify                      :   0.06 (  0%)   0.00 (  0%)   0.05 (  0%)    10M (  5%)
 tree CFG construction              :   0.01 (  0%)   0.00 (  0%)   0.00 (  0%)    93k (  0%)
 tree SSA rewrite                   :   0.00 (  0%)   0.00 (  0%)   0.01 (  0%)  2555k (  1%)
 tree SSA other                     :   0.00 (  0%)   0.03 ( 17%)   0.03 (  0%)  4944  (  0%)
 tree operand scan                  :   0.01 (  0%)   0.02 ( 11%)   0.03 (  0%)  3010k (  2%)
 tree SSA verifier                  :   0.34 (  0%)   0.02 ( 11%)   0.30 (  0%)     0  (  0%)
 tree STMT verifier                 :   0.40 (  0%)   0.00 (  0%)   0.46 (  0%)     0  (  0%)
 callgraph verifier                 :   0.02 (  0%)   0.00 (  0%)   0.02 (  0%)     0  (  0%)
 dominance computation              :   0.01 (  0%)   0.00 (  0%)   0.00 (  0%)     0  (  0%)
 expand vars                        :   0.02 (  0%)   0.00 (  0%)   0.01 (  0%)  4723k (  2%)
 expand                             :   0.14 (  0%)   0.00 (  0%)   0.16 (  0%)    29M ( 15%)
 post expand cleanups               :   0.02 (  0%)   0.00 (  0%)   0.01 (  0%)    21k (  0%)
 integrated RA                      :   1.89 (  0%)   0.02 ( 11%)   1.90 (  0%)    25M ( 13%)
 LRA non-specific                   :   2.23 (  1%)   0.01 (  6%)   2.29 (  1%)    54M ( 28%)
 LRA virtuals elimination           :   0.24 (  0%)   0.02 ( 11%)   0.21 (  0%)   682k (  0%)
 LRA reload inheritance             :   0.45 (  0%)   0.00 (  0%)   0.46 (  0%)   582k (  0%)
 LRA create live ranges             :   2.15 (  1%)   0.00 (  0%)   2.14 (  1%)  3804k (  2%)
 LRA hard reg assignment            : 389.11 ( 97%)   0.05 ( 28%) 389.13 ( 97%)     0  (  0%)
 LRA coalesce pseudo regs           :   0.02 (  0%)   0.00 (  0%)   0.03 (  0%)     0  (  0%)
 reload                             :   0.01 (  0%)   0.00 (  0%)   0.01 (  0%)     0  (  0%)
 thread pro- & epilogue             :   0.20 (  0%)   0.00 (  0%)   0.19 (  0%)   212k (  0%)
 shorten branches                   :   0.07 (  0%)   0.00 (  0%)   0.06 (  0%)   330k (  0%)
 final                              :   0.56 (  0%)   0.00 (  0%)   0.54 (  0%)   861k (  0%)
 rest of compilation                :   0.45 (  0%)   0.00 (  0%)   0.42 (  0%)    40M ( 21%)
 verify RTL sharing                 :   1.10 (  0%)   0.00 (  0%)   1.16 (  0%)     0  (  0%)
 TOTAL                              : 400.96          0.18        401.11          195M