投稿時間:2021-06-08 00:44:31 RSSフィード2021-06-08 00:00 分まとめ(53件)

カテゴリー等 サイト名等 記事タイトル・トレンドワード等 リンクURL 頻出ワード・要約等/検索ボリューム 登録日
IT 気になる、記になる… Microsoft、対象のOffice製品購入で最大5,000円のキャッシュバックキャンペーンを開始 https://taisy0.com/2021/06/07/141470.html microsoft 2021-06-07 14:31:59
IT 気になる、記になる… LINEモバイル、7月より2つのキャンペーンを実施へ − ソフトバンク回線のデータ量倍増とデータ通信量が500MB/月以下で月額料金無料化 https://taisy0.com/2021/06/07/141465.html 限定 2021-06-07 14:17:21
AWS AWS Compute Blog Getting Started with serverless for developers: Part 4 – Local developer workflow https://aws.amazon.com/blogs/compute/getting-started-with-serverless-for-developers-part-4-local-developer-workflow/ Getting Started with serverless for developers Part Local developer workflowThis blog is part of the “Getting started with serverless for developers series helping developers start building serverless applications from their IDE Many “getting started guides demonstrate how to build serverless applications from within the AWS Management Console However most developers spend the majority of their time building from within their local integrated development … 2021-06-07 14:13:59
python Pythonタグが付けられた新着投稿 - Qiita 残プロ 第-6回 ~.csvをpythonで編集~ https://qiita.com/R1nY1x1/items/63bfbdc2e0b3b28b84a4 2021-06-07 23:58:53
python Pythonタグが付けられた新着投稿 - Qiita テンソルネットワーク:テンソル繰り込み群を用いた二次元イジングの厳密解 https://qiita.com/tensor/items/36fd11237de8e6e8388a UbuntuLTSRyzenXRAMGBPythonminicondavernumpyverPytorchテンソルネットワークとはテンソルネットワークとは、量子多体系の波動関数、統計力学の分配関数などを多数のテンソルの縮約として表現する手法です。 2021-06-07 23:41:23
python Pythonタグが付けられた新着投稿 - Qiita Python Win32プログラミング https://qiita.com/shirokumaneko/items/53f719a634d00b833831 PythonWinプログラミングPythonWinプログラミングWinAPI自体、今では使う機会は少ないですがWinAPIC言語で作成されたソフトをPythonに移植したりexeしかないソフトに対してPythonでちょっとしたハックをしたりするのに役立つかもしれません。 2021-06-07 23:18:49
python Pythonタグが付けられた新着投稿 - Qiita KMSを用いて機密情報をプログラム実行時に復元する https://qiita.com/masawai/items/4c7331e4e051ef59ced8 KMSを用いて機密情報をプログラム実行時に復元するセンシティブなデータを暗号化してソースコードに埋め込む。 2021-06-07 23:10:24
python Pythonタグが付けられた新着投稿 - Qiita 爆速で幼稚園児並みのFlaskアプリをHerokuにデプロイしていくぅ!↑↑↑ https://qiita.com/revvve44/items/c77fbeae8b19bc8fc951 herokupipelinespromoteremotestaging本番環境にも変更が反映されていれば完了だおわりに今回は爆速でFlaskアプリをHerokuにデプロイしたわけだが、Flaskアプリ部分があまりにも幼並完幼稚園児並みの完成度であった。 2021-06-07 23:08:30
js JavaScriptタグが付けられた新着投稿 - Qiita Next.jsのAPI RoutesをTestする https://qiita.com/tatsuya-miyamoto/items/f99eb069f65b30f2f816 なんとかAPIの方は無事に実装でき、さあJestでテストも作成するぞとなったところで、APIを作成するとき以上に色々とドキュメントを巡る羽目になったので、その記録です。 2021-06-07 23:31:49
js JavaScriptタグが付けられた新着投稿 - Qiita 【Vue.js】v-modelの修飾子の種類とその使いどころ https://qiita.com/yuta-katayama-23/items/317c7aa4773497c0506e number修飾子どうなるのか基本的にltinputtypenumbergtと指定したとしても以下のようにtypeofを出力するとstringになってしまうが、number修飾子をvmodelに付与するとnumberとして扱うようにできる。 2021-06-07 23:23:05
js JavaScriptタグが付けられた新着投稿 - Qiita scrollHint スクロールのヒントが出るやつ https://qiita.com/Histings/items/0813c3ebb352c626deea scrollHintスクロールのヒントが出るやつscrollHintスクロールができることを表示する今回はテーブルなどで横スクロールできることがわかるように、補助的なアニメーションを表示させる今回はpugとstylusを使っています。 2021-06-07 23:15:03
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) XAMPPのApacheが開始できません https://teratail.com/questions/342752?rss=all XAMPPのApacheが開始できません前提・実現したいことここに質問の内容を詳しく書いてください。 2021-06-08 00:00:08
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) CSVファイルの行列の入れ替えをする方法を教えてください。 https://teratail.com/questions/342751?rss=all CSVファイルの行列の入れ替えをする方法を教えてください。 2021-06-07 23:44:51
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) python データフレームのある要素の値渡し https://teratail.com/questions/342750?rss=all pythonデータフレームのある要素の値渡しpythonnbspデータフレームで値渡しについて以下のような処理を行う際に値の情報だけを関数の引数にしたいです。 2021-06-07 23:33:01
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) JavaScript 関数の作成 https://teratail.com/questions/342749?rss=all JavaScript関数の作成JavaScript学習中です。 2021-06-07 23:31:24
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) null判定を実装したい https://teratail.com/questions/342748?rss=all null判定を実装したい現在、googlenbspboolsnbspapiを用いた本の検索と気になる保管機能の実装したサイトを制作しております。 2021-06-07 23:30:59
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) i2c通信における読み込みたいデータのアドレスとは https://teratail.com/questions/342747?rss=all 2021-06-07 23:29:23
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) Rail tutorial13章のS3導入ができない。 https://teratail.com/questions/342746?rss=all Railtutorial章のS導入ができない。 2021-06-07 23:18:29
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) MVVMにおけるアカウント登録時に、既存アカウント重複時のエラーを通知する方法は https://teratail.com/questions/342745?rss=all MVVMにおけるアカウント登録時に、既存アカウント重複時のエラーを通知する方法は環境NETnbspWPFPrismnbsp前提・実現したいことMVVMの設計に従ってアカウント登録の実装をしているのですが、アカウント登録時のValidation処理をどう行うか困っています…ModelでValidationを実行する場合には、どうエラーメッセージを通知するのがよいのでしょうか。 2021-06-07 23:11:49
Program [全てのタグ]の新着質問一覧|teratail(テラテイル) ラウンドロビンって何に使われていますか? https://teratail.com/questions/342744?rss=all ラウンドロビンって何に使われていますかスケジューリングのアルゴリズムの一つとしてラウンドロビンがあり、決まった時間内でタスクが処理されなけば、次のタスクへ移動し処理されなかったものは待ち列の最後尾に戻ることまでは、調べてわかったのですが、ラウンドロビンは実践的にはどこで使われているのでしょうか。 2021-06-07 23:10:33
Ruby Rubyタグが付けられた新着投稿 - Qiita 【Rails】Failed to destroy the recordというエラー(メモ) https://qiita.com/tech_kento/items/abefea96021fc7bb9a56 【Rails】Failedtodestroytherecordというエラーメモエラー文詳細以下コンソールでの表示CompletedInternalServerErrorinmsActiveRecordmsAllocationsActiveRecordRecordNotDestroyedFailedtodestroytherecordFailedtodestroytherecordというエラーが出力され、指定したものが削除できない。 2021-06-07 23:08:15
AWS AWSタグが付けられた新着投稿 - Qiita KMSを用いて機密情報をプログラム実行時に復元する https://qiita.com/masawai/items/4c7331e4e051ef59ced8 KMSを用いて機密情報をプログラム実行時に復元するセンシティブなデータを暗号化してソースコードに埋め込む。 2021-06-07 23:10:24
Docker dockerタグが付けられた新着投稿 - Qiita 【ペンディング中 1点】〇〇-PostgreSQL / DBeaver_『OSS-DB標準教科書』4 https://qiita.com/ume-san/items/acbf2dcddd5f0ae30c34 SQL文「SELECTFROMcustomerWHEREcustomernameLIKE鈴木」を用いて「上記テーブルcustomer表のcustomername列が「鈴木」で始まる行データを取得」しよう、というお題が出されているのだが、このSQL文を実行すると、↓このように「データなし」との回答が返ってくる。 2021-06-07 23:42:13
Docker dockerタグが付けられた新着投稿 - Qiita 【Docker-compose】コンテナ起動時にport is already allocatedエラーが発生したときの対処方法 https://qiita.com/siromofu3/items/8de7ed4abd0ab3f5ec92 【Dockercompose】コンテナ起動時にportisalreadyallocatedエラーが発生したときの対処方法Laravelのwebアプリを作成するために、Dockercomposeで環境構築してコンテナを起動したところMySQLの立ち上げでエラーが発生しました。 2021-06-07 23:21:09
Docker dockerタグが付けられた新着投稿 - Qiita DockerでMinecraft Serverを立てる https://qiita.com/sugimochi_1019/items/c022277d48bf6eb398e6 これでデータを保存することができます。 2021-06-07 23:04:59
golang Goタグが付けられた新着投稿 - Qiita goenv を使うべきか gvm を使うべきか https://qiita.com/msh5/items/5a03b5630ec7ad2fcb75 bashltltcurlsSLinstalling余談各ツールのGoの最新リリースへの追従リリースされたばかりのバージョンだったりすると、gvmであれgoenvであれば対応されていないことがあります。 2021-06-07 23:50:41
Azure Azureタグが付けられた新着投稿 - Qiita Bot Framework Composer v2.0 を使って秘書Botを30分で作成してみたあれこれ https://qiita.com/usomaru/items/506eb51ad8a064533e45 ですが、アカウントリンクさせてから、MSGraphの認証に使用するアクセストークンをComposer側でどうすれば簡単に取得できるかわからず、だったらAzureFunctions使った方が速くねとなったため、断念しました…また、今回使用したテンプレートはユーザーにボタンで選択を促すアクションがたくさんあります。 2021-06-07 23:16:44
Azure Azureタグが付けられた新着投稿 - Qiita Azure予算とコストアラートを設定してみた https://qiita.com/azaleaInMt/items/f17b1e91b907868f6264 アラートのタイミングは「予測」か「実測」から選べます。 2021-06-07 23:11:30
Git Gitタグが付けられた新着投稿 - Qiita [基礎]Gitコマンドについてまとめてみた② https://qiita.com/tochisuke221/items/ef3fc32ba904d23ed258 基礎Gitコマンドについてまとめてみた②はじめに続きまとめていきます自分用なので、①を見たい方はこちらをご覧ください。 2021-06-07 23:07:22
Ruby Railsタグが付けられた新着投稿 - Qiita 【Rails】Failed to destroy the recordというエラー(メモ) https://qiita.com/tech_kento/items/abefea96021fc7bb9a56 【Rails】Failedtodestroytherecordというエラーメモエラー文詳細以下コンソールでの表示CompletedInternalServerErrorinmsActiveRecordmsAllocationsActiveRecordRecordNotDestroyedFailedtodestroytherecordFailedtodestroytherecordというエラーが出力され、指定したものが削除できない。 2021-06-07 23:08:15
技術ブログ Developers.IO CloudWatch LogsをターゲットとするEventBridgeルールをCloudFormationで作成するには https://dev.classmethod.jp/articles/tsnote-cloudwatch-cwlogs-eventrule-cfn/ amazoneventbridge 2021-06-07 14:19:31
海外TECH DEV Community Object Destructuring In JavaScript https://dev.to/nikhil27b/object-destructuring-in-javascript-1la Object Destructuring InJavaScript Object Destructure Object destructuring is a very useful feature of JavaScript to extract properties from objects and bind them to variables The Object destructure is extracts multiple properties at only writing a single line you can access properties from the nested objects and set a default value if that property doesn t exist Basic Object destructuring This is a basic object identifier that can name property access and expression should evaluate to an object Assigning to new variable names A property can be unpacked from an object and assigned to a variable with a different name than the object property Object Default values A variable can be assigned as a default value in if object is undefined that time we can be give a default value Nested Object Destructuring In a nested object destructuring you will be defined as an identifier in nesting you can extract properties from is unlimited Rest object The rest syntax is useful to collect the remaining properties after the destructuring also you will get the rest of the values only with the spread operator If you find this useful in a post like and save this post also comments about your thoughts For more content follow me on Instagram developer nikhil Thank you 2021-06-07 14:42:16
海外TECH DEV Community Importance of Keys in DBMS https://dev.to/hebashakeel/importance-of-keys-in-dbms-147g Importance of Keys in DBMSDBMS KeysIt is used to identify unique records by the combination of one or more fields attributes in the database table Keys play an important role in DBMS Different Types of Keys i Candidate Keys It is a minimal minimum set of attributes that can identify each tuple row uniquely in a Relation Example In the below example of Employee relation we can see that EPhone is the only unique attribute Hence it can be treated as a Candidate Key ii Primary Keys It is a set of one or more attributes that can uniquely identify each tuple gt Primary Key cannot have NULL values gt Only one Primary Key is possible in a table gt Values of Primary Key are unique and they cannot be repeated gt One of the Candidate Keys is selected as the Primary Key iii Super Keys It is a superset of Candidate Keys gt Trivial Super Key It is the set of all attributes iv Foreign Keys An attribute which is a key in one table and it also behaves as a Primary Key in another table is known as Foreign Key gt It is used to combine two tables logically v Alternate Key All other Candidate Keys which are not selected as a Primary Key is called as Alternate Keys It is also called as Secondary Key vi Composite Keys If a key contains more than one attribute then it is called as a Composite Key Example Employee table has key gt eName eAge eAddress This key will be called as Composite Key Thank You See you soon 2021-06-07 14:40:43
海外TECH DEV Community How to easily install kafka without zookeeper https://dev.to/adityasridhar/how-to-easily-install-kafka-without-zookeeper-1j2 How to easily install kafka without zookeeperThis post was originally published in adityasridhar comIn this article we will see how kafka can be setup without using zookeeper We will setup a node kafka cluster and create a test topic We will use a kafka producer to produce data into the test topic and also use a kafka consumer to consume data from the kafka topic Why is zookeeper used in kafkaZookeeper is used to store kafka cluster metadata information Zookeeper stores information like topic configuration topic partition locations and so on How will kafka work without zookeeperZookeeper acts as a external metadata management system for kafka This creates multiple problems such as data duplication increased system complexity and also leads to additional java processes being used In order to run kafka without zookeeper it can be run using Kafka Raft metadata mode KRaft In KRaft the kafka metadata information will be stored as a partition within kafka itself There will be a KRaft Quorum of controller nodes which will be used to store the metadata The metadata will be stored in an internal kafka topic metadata This is available in an experimental mode in kafka Right now using KRaft is experimental and should not be used in production Setting up a kafka cluster without zookeeper Download kafkaDownload kafka from wget Extract kafkatar xzf kafka tgzOpen the kafka folder All kafka commands should be run in the kafka foldercd kafka Kafka cluster configurationIf you go to config kraft folder inside the kafka home directory you will see a file called server properties This is a sample file which is provided by kafka to show how kafka can be started without zookeeperCreate new files from server properties This is because we will be creating a node clustercd config kraftcp server properties server propertiescp server properties server propertiescp server properties server propertiesIn server properties modify the following properties Please keep the other properties as is node id process roles broker controllerinter broker listener name PLAINTEXTcontroller listener names CONTROLLERlisteners PLAINTEXT CONTROLLER log dirs tmp server kraft combined logslistener security protocol map CONTROLLER PLAINTEXT PLAINTEXT PLAINTEXT SSL SSL SASL PLAINTEXT SASL PLAINTEXT SASL SSL SASL SSLcontroller quorum voters localhost localhost localhost Let me explain what these properties do node id This will act as the node Id in the cluster This will help us identify which broker this is It will also help us identify which kraft controller node this is process roles A node can act as a broker or controller or both Here we are indicating that this node can be both a kafka broker and a kraft controller node inter broker listener name Here the broker listener name is set to PLAINTEXTcontroller listener names Here the controller listener name is set to CONTROLLERlisteners Here we indicate that the broker will use port and the kraft controller will use port log dirs This is the log directory where kafka will store the datalistener security protocol map Here the connection security details are addedcontroller quorum voters This is used to indicate all the kraft controllers which are available Here we are indicating that we will have kraft controller nodes running on ports and For server properties modify the following properties Please keep the other properties as is node id process roles broker controllercontroller quorum voters localhost localhost localhost listeners PLAINTEXT CONTROLLER inter broker listener name PLAINTEXTcontroller listener names CONTROLLERlog dirs tmp server kraft combined logslistener security protocol map CONTROLLER PLAINTEXT PLAINTEXT PLAINTEXT SSL SSL SASL PLAINTEXT SASL PLAINTEXT SASL SSL SASL SSLIn Server the broker port is and controller port is Also the log dirs is differentFor server properties modify the following properties Please keep the other properties as is node id process roles broker controllercontroller quorum voters localhost localhost localhost listeners PLAINTEXT CONTROLLER inter broker listener name PLAINTEXTcontroller listener names CONTROLLERlog dirs tmp server kraft combined logslistener security protocol map CONTROLLER PLAINTEXT PLAINTEXT PLAINTEXT SSL SSL SASL PLAINTEXT SASL PLAINTEXT SASL SSL SASL SSLIn Server the broker port is and the controller port is Also the log dirs is different The complete server property files are available in this Git repo Kafka cluster id creation and log directory setupFirst we need to create kafka cluster id before starting the servers This can be done using the following command bin kafka storage sh random uuidNote down the uuid that comes after running the above statement In my case I got the following uuid bin kafka storage sh random uuid dJzdGvfTPaCYeklXaDQNext we need to format all the storage directories This is basically the directory that we put in log dirs property This can be done with the following command bin kafka storage sh format t lt uuid gt c lt server config location gt Replace lt uuid gt with the uuid that you got in the previous step Replace lt server config location gt with the server property filesIn my case I will be running the following commandsFor Server bin kafka storage sh format t dJzdGvfTPaCYeklXaDQ c config kraft server propertiesFor Server bin kafka storage sh format t dJzdGvfTPaCYeklXaDQ c config kraft server propertiesFor Server bin kafka storage sh format t dJzdGvfTPaCYeklXaDQ c config kraft server propertiesThis is the result which you get when you run the commands bin kafka storage sh format t dJzdGvfTPaCYeklXaDQ c config kraft server propertiesFormatting tmp server kraft combined logs bin kafka storage sh format t dJzdGvfTPaCYeklXaDQ c config kraft server propertiesFormatting tmp server kraft combined logs bin kafka storage sh format t dJzdGvfTPaCYeklXaDQ c config kraft server propertiesFormatting tmp server kraft combined logs Starting the kafka serversThe kafka servers can be started in daemon mode using the following commands First setup the heap propertiesexport KAFKA HEAP OPTS XmxM XmsM Here we are giving a very small max heap of M since we are running all the servers in a single local machine If you have bigger servers you can give heap size of GB or Above Start Server bin kafka server start sh daemon config kraft server propertiesStart Server bin kafka server start sh daemon config kraft server propertiesStart Server bin kafka server start sh daemon config kraft server properties Create a kafka topicLet us create a topic kraft test in this clusterThe topic can be created using the following command bin kafka topics sh create topic kraft test partitions replication factor bootstrap server localhost We are creating a topic with partitions and replicas since we have nodes We can list the topics present in the cluster using the following command bin kafka topics sh bootstrap server localhost listRunning the above command gives the below result bin kafka topics sh bootstrap server localhost listkraft testWe can describe the topics present in the cluster using the following command bin kafka topics sh bootstrap server localhost describe topic kraft testRunning the above command gives the below result bin kafka topics sh bootstrap server localhost describe topic kraft testTopic kraft test TopicId vZKswHHlQkmEOwyzAGAA PartitionCount ReplicationFactor Configs segment bytes Topic kraft test Partition Leader Replicas Isr Topic kraft test Partition Leader Replicas Isr Topic kraft test Partition Leader Replicas Isr Exploring the kafka metadata using metadata shellSimilar to zookeeper cli there is a metadata shell provided by kafka so that we can read the data in the metadata internal topic Open the shell using the following command bin kafka metadata shell sh snapshot tmp server kraft combined logs metadata logThe structure here is very similar to what we see in zookeeperIn order the list the brokers you can type ls brokers gt gt ls brokers In order to list the topics you can type ls topics gt gt ls topics kraft testIn order to see the topic metadata you can type cat topics kraft test data gt gt cat topics kraft test data partitionId topicId vZKswHHlQkmEOwyzAGAA replicas isr removingReplicas null addingReplicas null leader leaderEpoch partitionEpoch In order to find the controller leader node you can type cat metadataQuorum leader gt gt cat metadataQuorum leaderMetaLogLeader nodeId epoch Type exit to get out of the metadata shell Producing and consuming data from kafkaUse the following command to start a kafka producer in the terminalbin kafka console producer sh broker list localhost topic kraft testIn a different terminal use the following command to start a kafka consumerbin kafka console consumer sh bootstrap server localhost topic kraft testIn the producer terminal send a bunch of messages as shown below bin kafka console producer sh broker list localhost topic kraft test gt message gt message gt message gt hello gt byeIn the consumer terminal you would see the messages coming as shown belowbin kafka console consumer sh bootstrap server localhost topic kraft test message message message hellobye Congrats You have now learnt how to setup kafka without zookeeper This is still an experimental feature and should not be used in production If you are interested in realtime analytics using kafka and Apache Pinot feel free to checkout my course in Udemy by clicking on the Image below References Feel free to connect with me in LinkedIn or follow me in twitter 2021-06-07 14:37:55
海外TECH DEV Community ❄️ Today I released a version control software for 2D/3D artists and graphic designers, made in Angular+Electron https://dev.to/sebmtl/today-i-released-a-version-control-software-for-2d-3d-artists-and-graphic-designers-made-in-angular-electron-nck ️Today I released a version control software for D D artists and graphic designers made in Angular ElectronToday I released the first public beta version of my desktop application called Snowtrack What is Snowtrack Snowtrack is an intuitive easy to use and super fast version control software for graphic projects Its purpose is to make version control accessible to graphic designers and D D artists with a non technical workflow In this blog post I will cover some basics about technical challenges that lay ahead To get a better understanding of Snowtracks user interface check out the following screenshot What I used to build itFor the UI application I used a combination of Angular and Electron The underlying version control engine is called SnowFS an open source project I developed a fast and simple alternative to Git and Git LFS Feel free to check it out on GitHub A few months ago I wrote a blog post about it here on dev to Technical challenge no Graphic projects can differ in size tremendously From a single Photoshop file up to a GB file set of D scenes textures and assets These project types come with their own set of problems In the following I want to clear up some misconceptions about the topic around file locking File LockingTake a look at the code snippet below Process fd fs openSync foo w Process fd fs openSync foo w Imagine more than one process wants to open the same file at the same time What do you think will happen Answer It depends on the OS and if you re the maintainer of all processes When you call fs openSync NodeJS will forward the call behind the scenes to an OS function as you can see from this C codestatic ssize t uv fs open uv fs t req return open req gt path req gt flags O CLOEXEC req gt mode The function open is an OS function and available in all operating systems But the internals of this function differ between Windows Linux and macOS so I will cover them separately macOS LinuxTechnically neither macOS nor Linux have true file locking mechanisms Although you can read or write lock a file using another function called fcntl only programs which use this function regard and respect the file lock This means any other process which doesn t use fcntl can acquire a file handle and manipulate it as long as the file permissions allow it What a bummer That s why file locking on macOS and Linux is also called advisory file locking WindowsWindows is more complicated in that matter Windows offers two functions to open a file Either through the Windows API function called CreateFile yes that s really the name to open files or through open But the open function on Windows is a POSIX extension and uses CreateFile internally as well As we ve seen above NodeJS uses open but since we know that this is just a wrapper for CreateFile let s check out that function The low level open function of Windows HANDLE CreateFile LPCSTR lpFileName DWORD dwDesiredAccess DWORD dwShareMode LPSECURITY ATTRIBUTES lpSecurityAttributes DWORD dwCreationDisposition DWORD dwFlagsAndAttributes HANDLE hTemplateFile CreateFile has a parameter called dwShareMode A file that is opened with dwShareMode cannot be opened again until its handle has been closed So if you use open on a file that was already open by another process with CreateFile … dwShareMode you receive this error message The process cannot access the file because it is being used by another processOn the other hand if you use fs openSync in NodeJS or open in C C to open a file that hasn t been opened yet you cannot prevent another application from modifying it Unless you you use file permissions as a workaround but that s not really a file lock To prove this you will see that our fs openSync call executes CreateFile with the read write shared flags to comply with the POSIX standard This means on Windows you cannot prevent another application from opening and modifying your file if you don t use CreateFile What does this have to do with Snowtrack Imagine a user saving a big file in a graphic application and while the file is still being written to disk the user attempts to commit the file change How does Snowtrack deal with this As we learned open has no file locking and most applications don t even follow the file protocol and Snowtrack cannot control how Photoshop Blender and co open and write their files This means the only reliable chance of detecting if a file is still being written by another process is to check prior to a commit if any process on the system has a write handle on that file On Windows I solved this with a custom helper process and and the Windows API of Restart Manager which is mainly used for installers to ensure the files it is about to replace are not open anymore On MacOS I invoke the system process usr sbin lsof list open files with an inclusion of the working directory to speed up the execution of this command What else The development of Snowtrack came with countless technical challenges and I would be happy to share more insights File locking Electron Angular race conditions I O saturation build server update mechanisms edge cases with this project I touched many subjects and I would be happy to write a follow up blog post if you are interested Let me know in the comments below If you want to support SnowFS Snowtrack or me then feel free to join me on Twitter Thanks for reading TLDRDon t get me started on file locking Addendum What about the File In Use dialog in Windows If you are a Windows user you might have seen this error message before Windows or rather NTFS behaves very different compared to other file systems like HFS APFS ext There is no equivalent to inodes in NTFS and therefore no garbage collection deletes the file if the last file handle to an already deleted file is closed The File in Use dialog only indicates that if any process has a file handle to a given file no matter how it got opened it cannot be renamed moved or deleted That does not imply a file lock on the file content 2021-06-07 14:21:15
海外TECH DEV Community Programmatically generating color palettes https://dev.to/siddharthshyniben/programmatically-generating-color-palettes-5cgn Programmatically generating color palettesYou may have seen color palettes like the Material Palette or the tailwind colors Well I wanted to know how these were generated and wanted to generate my own too Here s how I did it The Base ColorsThis was the easiest one because I could just use hsl to adjust the hue by a certain step So we get hsl hsl hsl That was easy enough The rest of the paletteThen I thought of iterating over the saturation to brighten or darken the colors So I iterated again adding in to the value but there was always grey at the start of every color Not quite right Tweaking the loop gave me this final palette Not the best but OK by my standards 2021-06-07 14:09:18
海外TECH DEV Community Tools for Auditing CSS https://dev.to/starbist/tools-for-auditing-css-54n2 Tools for Auditing CSSAuditing CSS is not a common task in a developer s everyday life but sometimes you just have to do it Maybe it s part of a performance review to identify critical CSS and reduce unused selectors Perhaps is part of effort to improve accessibility where all the colors used in the codebase evaluated for contrast It might even be to enforce consistency Whatever the case and whenever that moment arrives I usually reach for some of the tools I ll cover in the article But before that let s see what it even means to audit CSS in the first place Auditing CSS is hardGenerally code auditing involves analyzing code to find bugs or other irregularities like possible performance issues For most programming languages the concept of auditing code is relatively straightforward it works or it doesn t But CSS is a specific language where errors are mostly ignored by browsers Then there s the fact that you could achieve the same style in many different ways This makes CSS a little tricky to audit to say the least Finding those errors might be prevented by using an extension for your favorite code editor or setting up a linter or code checker But that is not what I want to show here and that is not enough We could still use too many colors typographic definitions or z indexes all of which could lead to a messy unmaintainable unstable CSS codebase To truly audit CSS we would need to dig deeper and find places that are not considered best practices To find those places we could use the following tools Browser DevToolsLet s take a look at the Chrome DevTools tools for CSS auditing I m using Brave here which is Chromium based You might also want to check out this article by Umar Hansa who compiled a whole bunch of great DevTool features that released in If you like inspecting CSS code manually there is the Inspect tool Using that we could see the CSS code applied to a specific element Using the Inspect arrow we could even see additional details about colors fonts size and accessibility Grid and Flex inspectorThere s a lot of practical details in the DevTools interface but my favorite is the Grid and Flex inspector To enable them go to the Settings a little gear icon at the top right of the DevTools click on Experiments then enable CSS Grid and Flexbox debugging features Although this tool is mainly used for debugging layout issues I sometimes use it to quickly determine if CSS Grid or Flexbox is even used on the page at all CSS OverviewInspecting CSS is pretty basic and everything needs to be done manually Let s look at some more advanced DevTools features CSS Overview is one of them To enable CSS Overview tool go to the Settings click on Experiments and enable CSS Overview option To open the CSS Overview panel you could use the CMD Shift P shortcut type css overview then select Show CSS Overview This tool summarizes CSS properties like colors fonts contrast issues unused declarations and media queries I usually use this tool to get the feel of how good or poor CSS code is For example if there are shades of gray or too many typographic definitions that means that the style guide wasn t respected or one might not even exist Note that this tool summarizes the style applied to a specific page not the whole file Coverage panelThe Coverage tool shows the amount and the percentage of code used on the page To view it use the CMD Shift P shortcut type coverage select Show Coverage and click on the refresh icon You could filter only CSS files by typing css in the URL filter input I usually use this tool to understand the delivery technique of the site For example if I see that the coverage is pretty high I could assume that the CSS file is generated for each page separately It may not be critical data to know but sometimes it helps to understand the caching strategy Rendering panelThe Rendering panel is another useful tool To open the Rendering panel use CMD Shift P again type rendering this time and choose the Show Rendering option This tool has many options but my favorite ones are Paint flashing ー shows green rectangles when a repaint event happens I use it to identify areas that take too much time for rendering Layout Shift Regions ー shows blue rectangles when the layout shift occurs To make the most of these options I usually set the Slow G preset under the Network tab I sometimes record my screen and then slow down the video to find the layout shifts Frame Rendering Stats ー shows the real time usage of GPU and frames This tool is handy when identifying heavy animations and scrolling issues These tools are something that the regular audit doesn t imply but I find it essential to understand if the CSS code is performant and doesn t drain a device s energy Other options may be more beneficial for debugging issues like emulation and disabling of various features forcing the prefers color scheme feature or print media type and disabling local fonts Performance MonitorAnother tool for auditing the performance CSS code is the Performance Monitor To enable it use CMD Shift P again type performance monitor and select the Show Performance Monitor option I usually use this tool to see how many recalculations and layouts are triggered when interacting with the page or when the animation occurs Perfomance panelThe Performance panel shows a detailed view of all browser events during page load To enable the Performance tool do CMD Shift P type performance select Show Performance then click the reload icon I usually enable the Screenshots and Web Vitals options The most interesting metrics to me are First Paint First Contentful Paint Layout Shifts and Largest Contentful Paint There is also a pie chart showing the Painting and Rendering time DevTools might not be considered a classical auditing tool but it helps us understand which CSS features are used the efficiency of the code and how it performs ー all of which are key things to audit Online toolsDevTools is just one tool that is packed with a lot of features But there are other available tools we can use to audit CSS Specificity VisualizerSpecificity Visualizer shows the specificity of CSS selectors in the codebase Simply visit the site and paste in the CSS The main chart displays the specificity in relation to the location in the stylesheet The other two charts show the usage of specificities I often use this site to find bad selectors For example if I see many specificities marked as red I could easily conclude that the code could be better It is helpful to save the screenshots for reference as you work to improve things CSS Specificity Graph GeneratorCSS Specificity Graph Generator is a similar tool for visualizing specificity It shows a slightly different chart that might help you see how your CSS selectors are organized by specificity As it says on the tool s page spikes are bad and the general trend should be towards higher specificity later in the stylesheet It would be interesting to discuss that further but it s out of scope for this article However Harry Roberts did write about it extensively in his article The Specificity Graph which is worth checking out CSS StatsCSS Stats is another tool that provides analytics and visualizations for your stylesheets In fact Robin wrote about it a little while back and showed how he used it to audit the stylesheet at his job All you need to do is to enter the URL of the site and hit Enter The information is segmented into meaningful sections from declaration count to colors typography z indexes specificity and more Again you might want to store the screenshots for later reference Project WallaceProject Wallace is made by Bart Veneman who already introduced the project here on CSS Tricks The power of Project Wallace is that it can compare and visualize changes based on imports That means you could see previous states of your CSS code base and see how your code changes between states I find this feature quite useful especially when you want to convince someone that the code is improved The tool is free for a single project and offers paid plans for more projects CLI toolsIn addition to DevTools and online tools there are command line interface CLI tools that can help audit CSS WallaceOne of my favorite CLI tools is Wallace Once installed type wallace and then the site name The output shows everything you need to know about the CSS code for the site My favorite things to look at are the number of times important is used as well as how many IDs are in the code Another neat piece of information is the top specificity number and how many selectors use it These might be red flags for bad code What I like the most about this tool is that it extracts all of the CSS code from the site not only external files but also inline code as well That is why the report from CSS Stats and Wallace mismatch csscssThe csscss CLI tool shows which rules share the same declarations This is useful for identifying duplicated code and opportunities to reduce the amount of code that s written I would think twice before doing that as it might not be worthwhile especially with today s caching mechanisms It is worth mentioning that csscss requires Ruby Other useful toolsOther CSS tools might not be used for auditing but are still useful Let s list those too Color Sorter ー Sort CSS colors by hue then by saturation CSS Analyzer ー Generate an analysis for a string of CSS constyble ー This is a CSS complexity linter based on CSS Analyzer Extract CSS Now ー Get all the CSS from a single webpage Get CSS ー Scrape all the CSS from a page uCSS ー Crawl websites to identify unused CSS ConclusionCSS is everywhere around us and we need to consider it a first class citizen of every project It does not matter what other people think about your CSS but what you think about it really does matter If your CSS is organized and well written you will spend less time debugging it and more time developing new features In an ideal world we would educate everyone to write good CSS but that takes time Let today be the day when you start caring for your CSS code I know that auditing CSS isn t going to be fun for everyone But if you run your code against any of these tools and try to improve even one part of your CSS codebase then this post has done its job I am thinking about CSS code more and more lately and I am trying to make more developers write CSS code more respectfully I even started a new project at css auditors com yay for hyphenated domain names that s dedicated to auditing CSS If you know of any other tools let me know in the comments 2021-06-07 14:03:29
Apple AppleInsider - Frontpage News Apple earns close to $1 million per day from 'Roblox' game alone https://appleinsider.com/articles/21/06/07/apple-earns-close-to-1-million-per-day-from-roblox-game-alone?utm_medium=rss Apple earns close to million per day from x Roblox x game aloneThe social gaming platform Roblox is iPhone gaming s biggest earner with million in revenue per day and Apple gets of that Roblox is a social gaming platform Roblox is a popular mobile game that lets users download and participate in experiences These experiences can vary from small levels or challenges to entire gaming worlds within the Roblox app Read more 2021-06-07 14:58:31
海外TECH Engadget Improve your writing with this award-winning productivity software package https://www.engadget.com/pro-writing-aid-lifetime-subscription-bundle-145552977.html?src=rss_b2c advice 2021-06-07 14:55:52
海外TECH Engadget Twitter may lose legal protections in India if it doesn't follow new rules https://www.engadget.com/india-twitter-social-media-rules-warning-143825408.html?src=rss_b2c final 2021-06-07 14:38:25
海外TECH Engadget The Instant Pot Duo Nova is down to $69 right now https://www.engadget.com/instant-pot-duo-nova-6-quart-deal-buydig-141023569.html?src=rss_b2c buydig 2021-06-07 14:10:23
海外TECH Engadget How to watch WWDC 2021 https://www.engadget.com/how-to-watch-wwdc-2021-140034116.html?src=rss_b2c event 2021-06-07 14:00:34
Cisco Cisco Blog A simpler, more flexible SD-WAN design for branches, from Customer Zero. Top five benefits. https://blogs.cisco.com/ciscoit/a-simpler-more-flexible-sd-wan-design-for-branches-from-customer-zero-top-five-benefits A simpler more flexible SD WAN design for branches from Customer Zero Top five benefits A simpler more flexible SD WAN network as led by the Customer Zero team in Cisco IT This blog explains how we built the fabric and summarizes the benefits to date 2021-06-07 14:43:42
Cisco Cisco Blog Cisco Networking Academy recognizes top partners and instructors https://blogs.cisco.com/csr/cisco-networking-academy-recognizes-top-partners professionals 2021-06-07 14:16:22
海外科学 NYT > Science FEMA Disaster Aid Often Widens Racial Disparities https://www.nytimes.com/2021/06/07/climate/FEMA-race-climate.html FEMA Disaster Aid Often Widens Racial DisparitiesThe federal government often gives less help to Black disaster survivors than their white neighbors That s a challenge for President Biden who has vowed to fight both inequality and climate change 2021-06-07 14:41:25
海外科学 NYT > Science Add ‘Climate Hazards’ to Your Home-Buyer’s Checklist https://www.nytimes.com/2021/06/01/realestate/home-buying-climate-disasters.html house 2021-06-07 14:49:20
金融 RSS FILE - 日本証券業協会 新型コロナウイルス感染症への証券関係機関等・各証券会社の対応について(リンク集) https://www.jsda.or.jp/shinchaku/coronavirus/link.html 新型コロナウイルス 2021-06-07 15:40:00
金融 RSS FILE - 日本証券業協会 J-IRISS https://www.jsda.or.jp/anshin/j-iriss/index.html iriss 2021-06-07 14:49:00
ニュース BBC News - Home Covid: What do under-30s need to know about the vaccine? https://www.bbc.co.uk/news/health-57273875 rollout 2021-06-07 14:48:40
ビジネス ダイヤモンド・オンライン - 新着記事 ベゾス氏、ブルーオリジン初の有人宇宙飛行に搭乗へ - WSJ発 https://diamond.jp/articles/-/273382 有人宇宙飛行 2021-06-07 23:26:00
北海道 北海道新聞 感染対応の道内医療従事者 ワクチン接種1回目全員終える https://www.hokkaido-np.co.jp/article/552723/ 医療従事者 2021-06-07 23:17:30
北海道 北海道新聞 加藤官房長官側が報告書訂正 政党支部と資金管理団体 https://www.hokkaido-np.co.jp/article/552840/ 加藤勝信 2021-06-07 23:15:00
IT IT号外 夜勤従事者のためのNPO法人ってなんで無いのかなあと https://figreen.org/it/%e5%a4%9c%e5%8b%a4%e5%be%93%e4%ba%8b%e8%80%85%e3%81%ae%e3%81%9f%e3%82%81%e3%81%aenpo%e6%b3%95%e4%ba%ba%e3%81%a3%e3%81%a6%e3%81%aa%e3%82%93%e3%81%a7%e7%84%a1%e3%81%84%e3%81%ae%e3%81%8b%e3%81%aa/ 夜勤従事者のためのNPO法人ってなんで無いのかなあと夜勤ワーカー、いわゆるナイトタイムエコノミーに属して働く人というのは、これからの時代日本でざっと万人ほど不足するかもしれないという記事を年前に見た覚えがあります。 2021-06-07 14:29:24

コメント

このブログの人気の投稿

投稿時間:2021-06-17 22:08:45 RSSフィード2021-06-17 22:00 分まとめ(2089件)

投稿時間:2021-06-20 02:06:12 RSSフィード2021-06-20 02:00 分まとめ(3871件)

投稿時間:2021-06-17 05:05:34 RSSフィード2021-06-17 05:00 分まとめ(1274件)