Gradle File
?PNG
IHDR ??a ?IDATx?c??????g?Di???P?r?e??5????s?C?y???c??\??????}??X?x?a????b??a ?QMw??J?B6???k
?p
???P???*?HqB?8) Q?????? IEND?B`?
Manifest file
�PNG
IHDR 0 3 і�) �IDATx��YMOQ��Y�V����4���XJ�� ����)���X *�EQ��P��Ъ|مδH��xo�����#�MΪw�Ι�������F7��$�� O #P�.�8 � �C�>'��< ��/��i��N��,��_�G��v�ؼ�I�T�S���X�,�Ԃ��������E��]����2�=Q��<�ܳ��h��[Q��k>~�$6_I���f���3��NX��v���#�[w�i!���E���H�o�U�%T!O�&?G���K���l&�"�HJ�b�ˆ���� �������ƥ/_��SV���,��_������%���.�F�ߥ����n'y8~e��!#�W5��R6����H�%?BW+'�V��861��=h��=���e��D r��"�lR��<N�������Z31��g�Y�<9�Z�l�a�� �j��I�.>��������Uji(!5zre ��P�"���$Ԉ!/�.%3rVj��O=N����B�hZ��%ֻj\G�,�ƾ \4� �cA��C��O��Y��%��[�ht��"̒o�tC���,����+�T#MI#k�/.-;�����/��[_��Rv�$~�^�������֖�:e���N��u%�rV:�I;e#C.D����!�F��"oVr!���5�F����f90n^��C<�q��Z^;�i�9�:�C���k�6�:��،9��T6I5U�m�M�d�I=g���WyYx��9�6�"�c1FWV���F+����Q(j5k�7�\���7�
��zel��al��ܸYwn��\vY���m1y�f�6wy�s��!?��Fq���%;�^p��1�]1��xk����t��F\�ݘk�q�ݍnt����N����T IEND�B`�
\
**xml Or java file all are converted like this **
{
"logs": [
{
"outputFile": "E:\\Husher\\app\\build\\intermediates\\incremental\\mergeDebugResources\\merged.dir\\values-gl\\values-gl.xml",
"map": [
{
"source": "C:\\Users\\BackB0i\\.gradle\\caches\\transforms-1\\files-1.1\\places-1.1.0.aar\\e54a7510fa5f4dceb58db78ef6ff578d\\res\\values-gl\\values.xml",
"from": {
"startLines": "4,5,6,7,8,9,10,11",
"startColumns": "0,0,0,0,0,0,0,0",
"startOffsets": "184,254,320,422,485,532,606,703",
"endColumns": "69,65,101,62,46,73,96,55",
"endOffsets": "253,319,421,484,531,605,702,758"
},
"to": {
"startLines": "49,50,51,52,53,54,55,56",
"startColumns": "4,4,4,4,4,4,4,4",
"startOffsets": "58
All Files are converted like this, But New project that i create are not effected
Related
I need to get data from a site and create a .json file from the data.
But when I create a .json file, I get extra square brackets.
Code:
person_info = []
person_info.append(
{
"Name": name,
"Mail": mail,
}
)
with open(filename, 'a', encoding='utf-8') as file:
json.dump(person_info, file, indent=4, ensure_ascii=False)
What i get from it in .json file:
[
{
"Name": "Sample Name",
"Mail": "No results"
}
][
{
"Name": "Sample Name",
"Mail": "Mail"
}
]
What i need to get:
[
{
"Name": "Sample Name",
"Mail": "No results"
},
{
"Name": "Sample Name",
"Mail": "Mail"
}
]
You're issue seems to be related to how you write into your file.
You're accessing the "filename" file in "a" (append) mode.
Delete the file, the open it in "w" mode instead and this should solve your problem.
I am currently using SSH-Remote add-on for VisualStudioCode and some directories are having numbered names due to docker usage, my question is:
"Can i somehow 'rename' them without actually making changes to directory name"
With this i would give folder a nickname or a alias shown only to me and not changing actual values on my VPS
As a workaround you can add those folders to a workspace in VS Code, save the workspace and then edit the .code-workspace file you just saved to add a new node "name" where you can add custom names to the folder without actually renaming them.
{
"folders": [
{
"path": "../path/to/your/directory1"
},
{
"path": "../path/to/your/directory2"
}
],
"settings": {}
}
from this to
{
"folders": [
{
"path": "../path/to/your/directory1",
"name": "Your Custom NickName1"
},
{
"path": "../path/to/your/directory2",
"name": "Your Custom NickName2"
}
],
"settings": {}
}
I am trying to get my IoT Central app to show the GPS location using a map tile. My JSON file sends over the location and i have this tied to the map tile but the map tile keeps saying "Waiting for data" I have tried everything to get this to show and i can't seem to get it to work.
I have followed the JSON layout as shown here
You can see the raw data tab below which shows the data coming in and that it is associating the data with the gps capability but the map shows nothing.
enter image description here
I have just made a quick test and it looks like everything is working well:
New App with a custom device template
Creating a View
Exporting a device template for my tester (simulator):
{
"#id": "urn:custom6ec42lhnjx:gps38u:1",
"#type": "CapabilityModel",
"contents": [],
"displayName": {
"en": "gps"
},
"implements": [
{
"#type": "InterfaceInstance",
"displayName": {
"en": "Interface"
},
"name": "gpsea",
"schema": {
"#id": "urn:custom6ec42lhnjx:gpsea:1",
"#type": "Interface",
"contents": [
{
"#type": [
"Telemetry",
"SemanticType/Location"
],
"displayName": {
"en": "gps"
},
"name": "gps",
"schema": "geopoint"
},
{
"#type": [
"Telemetry",
"SemanticType/Temperature"
],
"displayName": {
"en": "temp"
},
"name": "temp",
"schema": "double"
}
],
"displayName": {
"en": "Interface"
}
}
}
],
"#context": [
"http://azureiot.com/v1/contexts/IoTModel.json"
]
}
Provisioning and Simulating device (with a random values):
Dashboard IoT Central App:
Example with simulating your telemetry data:
I finally got it working, unfortunately only by starting again and deleting everything i had done thus far, as soon as i recreated my IoTC app and reimplemented the function that deals with the webhook everything worked perfectly. Still strange as the data format and everything else remained unchanged. But thank you for your help.
I've tried using the csvtojson module to create a GeoJSON-formatted file, but the nesting isn't working correctly at all. Can anyone point me in the right direction or do I need to write my own code?
> npx csvtojson input.tsv > output.json
input.tsv
properties.labelTc properties.labelEn properties.nameTc properties.nameEn properties.zoomifyX properties.zoomifyY geometry.coordinates.1 geometry.coordinates.0 properties.urlEn properties.urlZh type
皇城 The Imperial Palace City 明故宫 Ming Palace 105513 -1863 32.038 118.815 https://en.wikipedia.org/wiki/Ming_Palace Feature
天地壇 Altar of Heaven and Earth Guanghuamen? 105049 -1000 32.058 118.832 https://baike.baidu.com/item/%E5%A4%A9%E5%9D%9B/19964669 Feature
What I want
{
"properties": {
"labelTc": "皇城",
"labelEn": "The Imperial Palace City",
...
},
"geometry": {
"coordinates": [118.815, 32.038]
},
"type": "Feature"
}
What I got:
[
{
"properties": {
"labelTc\tproperties": {
"labelEn\tproperties": {
"nameTc\tproperties": {
"nameEn\tproperties": {
"zoomifyX\tproperties": {
"zoomifyY\tgeometry": {
"coordinates": {
"1\tgeometry": {
"coordinates": {
"0\tproperties": {
"urlEn\tproperties": {
"urlZh\ttype": "??\tThe Imperial Palace City\t???\tMing Palace\t105513\t-1863\t32.038\t118.815\thttps://en.wikipedia.org/wiki/Ming_Palace\t\tFeature"
}
}
}
}
}
}
}
}
}
}
}
}
},
Since I was using Windows PowerShell, which uses an extension of Latin-1 encoding, by default, I needed both a flag for the csvtojson library and a second for PowerShell.
npx csvtojson --delimiter=\t input.tsv > output.json -encoding utf8
I use some files written with Gherkin mode, but they don't have the ".feature" extension. I tried to change some visual code files related to cucumber extension to be able to highlight files that are not .feature but I had no success.
For example:
Workspace settings.json:
{
"folders": [
{
"path": "/home/user/git"
},
{
"path": "/home/user/Documents/scripts"
}
],
"settings": {}
"cucumberautocomplete.steps": [
"*.myext"
],
"cucumberautocomplete.syncfeatures": "*.myext",
"cucumberautocomplete.strictGherkinCompletion": true
}
It worked changing the file /home/user/.config/Code/User/settings.json and adding this config:
"files.associations": {
"*.myext": "feature"
}
{
"editor.renderWhitespace": "all",
"window.titleBarStyle": "custom",
"editor.fontSize": 15,
"python.jediEnabled": false,
"terminal.integrated.shell.linux": "/bin/bash",
"workbench.colorTheme": "Visual Studio Dark",
"editor.suggestSelection": "first",
"vsintellicode.modify.editor.suggestSelection": "automaticallyOverrodeDefaultValue",
"[feature]": {
},
"files.associations": {
"*.myext": "feature"
}
}