Unable to run 'gatsby develop' for publishing Obsidian notes online - javascript

I'm following the tutorial given at this medium article and got stuck at Step 4, where I need to run 'gatsby develop' to build my digital garden.
Running 'gatsby develop' returns an error message given below:
Error:
error:0308010C:digital envelope routines::unsupported
Error: error:0308010C:digital envelope routines::unsupported
- hash:71 new Hash
node:internal/crypto/hash:71:19
- node:crypto:140 Object.createHash
node:crypto:140:10
- createHash.js:135 module.exports
[my-digital-garden]/[webpack]/lib/util/createHash.js:135:53
- NormalModule.js:417 NormalModule._initBuildHash
[my-digital-garden]/[webpack]/lib/NormalModule.js:417:16
- NormalModule.js:471 handleParseError
[my-digital-garden]/[webpack]/lib/NormalModule.js:471:10
- NormalModule.js:503
[my-digital-garden]/[webpack]/lib/NormalModule.js:503:5
- NormalModule.js:358
[my-digital-garden]/[webpack]/lib/NormalModule.js:358:12
- LoaderRunner.js:373
[my-digital-garden]/[loader-runner]/lib/LoaderRunner.js:373:3
- LoaderRunner.js:214 iterateNormalLoaders
[my-digital-garden]/[loader-runner]/lib/LoaderRunner.js:214:10
- LoaderRunner.js:221 iterateNormalLoaders
[my-digital-garden]/[loader-runner]/lib/LoaderRunner.js:221:10
- LoaderRunner.js:236
[my-digital-garden]/[loader-runner]/lib/LoaderRunner.js:236:3
- LoaderRunner.js:111 context.callback
[my-digital-garden]/[loader-runner]/lib/LoaderRunner.js:111:13
- index.js:44
[my-digital-garden]/[babel-loader]/lib/index.js:44:71
not finished Building development bundle - 0.524s
The above message is not the whole of what CLI returns whenever I enter "gatsby develop". It is the part after the heading "Error" that appears in CLI. If you need me to print the whole answer, do tell. And excuse me if there's anything I should have mentioned or excluded.
Here's what I've tried:
Installed Gatsby CLI and ensured that it's up-to-date.
Checked my system requirements and confirmed that my machine meets the minimum specifications.
Verified that Node.js and npm are installed and updated to the latest version.
Checked that the project's dependencies are installed using npm install.
This is what i expect to obtain (the picture is attached from tutorial i am following
Image of CLI that I expect to obtain, taken from a medium tutorial article
My level of expertise:
I'm new to Gatsby and Obsidian.
I have experience with the command line and have tried troubleshooting using various online resources.
Any help would be greatly appreciated. Thank you!

Related

eas build -p ios problem with pod install

try to build an IPA with EXPO EAS now but i keep facing this problem with the pod install
i expect building an IPA as i use to do before with : expo build
plus the expo build was working just fine
here the error i get
Using Expo modules2Auto-linking React Native modules for target Malabiss: RNCAsyncStorage, RNCPicker, RNGestureHandler, RNReanimated, RNSVG, RNScreens, RNVectorIcons, and react-native-safe-area-context3[Codegen] Generating ./build/generated/ios/React-Codegen.podspec.json4Analyzing dependencies5Fetching podspec for DoubleConversion from ../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec6[Codegen] Found FBReactNativeSpec7Fetching podspec for RCT-Folly from ../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec8Fetching podspec for boost from ../node_modules/react-native/third-party-podspecs/boost.podspec9Fetching podspec for glog from ../node_modules/react-native/third-party-podspecs/glog.podspec10Adding spec repo trunk with CDN https://cdn.cocoapods.org/11[!] Unable to find a specification for UMCore depended upon by UMPermissionsInterface12You have either:13 * out-of-date source repos which you can update with pod repo update or with pod install --repo-update.14 * mistyped the name or version.15 * not added the source repo that hosts the Podspec to your Podfile.16pod exited with non-zero code: 1

"Could not exchange access token for unknown reasons" ; In-meeting App Meeting Extension

Myself and a team member have followed the 'Try this sample' and 'Use the app in Teams' instructions for the In-Meeting sample application to develop an app for Microsoft Teams:
https://github.com/OfficeDev/TeamsFx-Samples/tree/v2/in-meeting-app
We've both followed the same steps on different computers and on different OS's (Mac and PC), and we are getting the same issue:
"An error has occurred. This application may no longer respond until reloaded".
The instructions have us open Powershell and run commands in two locations. ('Try this sample' Step 5)
'tabs' folder, asked to run npm install and npm start
'bot' folder, asked to run npm install and npm run start:local
No errors occur when these commands are run initially, but when we open the app up in Teams and click on the button to bring out the side panel, errors show up in both terminals where we ran the commands.
In terminal 1, the tabs folder, we get a 'proxy error':
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
Try the new cross-platform PowerShell https://aka.ms/pscore6
PS C:\Users\Luke\TeamsApps\in-meeting-app\tabs> npm install
up to date, audited 1685 packages in 2s
101 packages are looking for funding
run `npm fund` for details
142 vulnerabilities (125 moderate, 16 high, 1 critical)
To address issues that do not require attention, run:
Compiled successfully!
You can now view microsoft-teams-ext in the browser.
Local: https://localhost:3000
On Your Network: https://192.168.0.3:3000
Note that the development build is not optimized.
To create a production build, use npm run build.
Proxy error: Could not proxy request /getGraphAccessToken?ssoToken=eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImtpZCI6Ik1yNS1BVWliZkJpaTdOZDFqQmViYXhib1hXMCJ9.eyJhdWQiOiI5MzI0MTRiOS04NjM1LTQ3MjYtODlhZS1mYzAzVjOWU2MGMiLCJpc3MiOiJodHRwczovL2xvZ2luLm1pY3Jvc29mdG9ubGluZS5jb20vNTk2ZGYzOWEtNzUyNS00OWU4LWE3ODktYzZhMzY2OGQ5ZWZmL3YyLjAiLCJpYXQiOjE2NDU1NTU2NTYsIm5iZiI6MTY0NTU1NTY1NiwiZXhwIjoxNjQ1NTY0NjQyLCJhaW8iJBVFFBeS84VEFBQUExZTF2NkVIUVpFbkEvSEZ0Q3lkSHp4OEJVU3U0QzR2VlExbFNoWldiMjRBV0JMZWtlbmExOC8wbTlBZzFiajhtIiwiYXpwIjoiMWZlYzhlNzgtYmNlNC00YWFmLWFiMWItNTQ1MWNjMzg3MjY0IiwiYXpwYWNyIjoiMCIsIm5hbWUiOiJMdWtlI6cGllayIsIm9pZCI6ImMyNjdkZDUyLWQ4OTItNDZlZC1iNWMyLWVkMGU5OTdlN2ZmOSIsInByZWZlcnJlZF91c2VybmFtZSI6Ikx1a2VAcDIxcS5vbm1pY3Jvc29mdC5jb20iLCJyaCI6IjAuQVU4QW12TnRXU1YxNkVtbmljYWpabzJlXzdrVUpKTTFoaVpIaWE3OEWEo1Z3hQQUVZLiIsInNjcCI6ImFjY2Vzc19hc191c2VyIiwic3ViIjoiNG01LTlvQ2JKT1ZLb3k1TGduMEtpWnpaNk9YNkU5STR4ZVJsUVMxYjZEbyIsInRpZCI6IjU5NmRmMzlhLTc1MjUtNDllOC1hNzg5LWM2YTM2NjhkOWVmZiIsInV0aSI6IlB0bEs4QnJOcmsVRwTE5Nb0U5QVEiLCJ2ZXIiOiIyLjAifQ.je5zMu4knsZ-NwqSKF1M_n71Ehxgs8WZGsPdIwUu0EBT3qdoHHL2ET4RqoTACqtMC8lDFqxFT2EWwYHcXes02QivXYEvWj8j-MQS-VhAs3FTh1e07qer8jq4cOeaVrLpfBjoCpSnbI_lXYUP-hz77YGWbUZrI6k5rXnij6-Jcn1TmvV9OgD_lrliWGIPHrS28TajvFa1Acu64YJGNAGys-r6uU7U5MrpcEszufRVExx8tDEysNWc55_Wr88Ur5mBIzDgDqiUbEf_RP2ZzlulRlPZC2ZVwI54VZqAWM2LfbCpD5bL9OhT7H9qAml5N8fOXY_WNHlYUWROgtD_iinQ from reflectrdomain.eu.rok.io to http://localhost:5000/.
See https://nodejs.org/api/errors.html#errors_common_system_errors for more information (ECONNRESET).
In terminal 2, the bot folder, we get a type error:
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
Try the new cross-platform PowerShell https://aka.ms/pscore6
PS C:\Users\Luke\TeamsApps\in-meeting-app\bot> npm install
up to date, audited 188 packages in 1s
12 packages are looking for funding
run `npm fund` for details
found 0 vulnerabilities
PS C:\Users\Luke\TeamsApps\in-meeting-app\bot> npm run start:local
> api-server#0.0.1 start:local
> cross-env NODE_ENV=development.local node ./index.js
API server is listening on port 5000
C:\Users\Luke\TeamsApps\in-meeting-app\bot\node_modules\botbuilder\lib\botFrameworkAdapter.js:192
const connectorClient = this.createConnectorClientInternal(reference.serviceUrl, credentials);
^
TypeError: Cannot read properties of undefined (reading 'serviceUrl')
at BotFrameworkAdapter.<anonymous> (C:\Users\Luke\TeamsApps\in-meeting-app\bot\node_modules\botbuilder\lib\botFrameworkAdapter.js:192:82)
at Generator.next (<anonymous>)
at C:\Users\Luke\TeamsApps\in-meeting-app\bot\node_modules\botbuilder\lib\botFrameworkAdapter.js:15:71
at new Promise (<anonymous>)
at __awaiter (C:\Users\Luke\TeamsApps\in-meeting-app\bot\node_modules\botbuilder\lib\botFrameworkAdapter.js:11:12)
at BotFrameworkAdapter.continueConversation (C:\Users\Luke\TeamsApps\in-meeting-app\bot\node_modules\botbuilder\lib\botFrameworkAdapter.js:165:16)
at C:\Users\Luke\TeamsApps\in-meeting-app\bot\index.js:144:13
at Layer.handle [as handle_request] (C:\Users\Luke\TeamsApps\in-meeting-app\bot\node_modules\express\lib\router\layer.js:95:5)
at next (C:\Users\Luke\TeamsApps\in-meeting-app\bot\node_modules\express\lib\router\route.js:137:13)
at Route.dispatch (C:\Users\Luke\TeamsApps\in-meeting-app\bot\node_modules\express\lib\router\route.js:112:3)
My team member who is on Mac, instead of getting the error I get above, just gets the message "Could not exchange access token for unknown reasons.", but his client displays the same behaviour.
These errors repeat each time we open and close the side panel.
What can we do to fix the issue, and get it to show as it's supposed to?
Steps to reproduce:
Follow steps at https://github.com/OfficeDev/TeamsFx-Samples/tree/v2/in-meeting-app
"An error has occurred. This application may no longer respond until reloaded."
Thanks for using this sample and post the issue.
For the first error occurred in tab folder, from the log
reflectrdomain.eu.rok.io to http://localhost:5000/
I found that you may not using the ngrok, so caused the proxy error, my suggestion is try ngrok first and check if it is worked.
The solution for the second issue in bot folder, is removed the app in the meeting and re-add the app into the meeting.

React Native ios run issue

I am new to react-native and running yarn ios on my react native project keeps failing with the following error.
`** BUILD FAILED **
The following build commands failed:
CompileC
/Users/gift/Library/Developer/Xcode/DerivedData/gainerDemo-eudprqpgpjkdvzechchqincjgjlo/Build/Intermediates.noindex/Pods.build/Debug-iphonesimulator/RCT-Folly.build/Objects-normal/x86_64/SysUio.o
/Users/gift/Desktop/personal
projects/gainerDemo/ios/Pods/RCT-Folly/folly/portability/SysUio.cpp
normal x86_64 c++ com.apple.compilers.llvm.clang.1_0.compiler (in
target 'RCT-Folly' from project 'Pods')
`
Folly hardly ever works for me.
In your Podfile, comment out the line flipper_post_install(installer) i.e:
# Use a hash to comment within Podfiles and Podspecs.
# flipper_post_install(installer)
Then reinstall pods by running either npx pod-install or by typing pod install in your Terminal from within the ios directory. You have to do this every time you modify the Podfile or install a new native binary for iOS.

expo init <project name> throwing npm ERROR (windows OS)

Just started with expo and React-Native and when I run
expo init ProjectName
I am getting an error stating:
Unexpected end of JSON input while parsing near '...,"version":"7.0.0-bet'
Process exited with non-zero code: 1
Set EXPO_DEBUG=true in your env to view the stack trace.
When I add the said thing in env (using set EXPO_DEBUG=true on windows), I get the following error:
Error: Process exited with non-zero code: 1
at ChildProcess.child.on (C:\Users\mohit\AppData\Roaming\npm\node_modules\expo-cli\node_modules\#expo\spawn-async\build\spawnAsync.js:39:21)
at ChildProcess.emit (events.js:182:13)
at ChildProcess.cp.emit (C:\Users\mohit\AppData\Roaming\npm\node_modules\expo-cli\node_modules\cross-spawn\lib\enoent.js:40:29)
at maybeClose (internal/child_process.js:962:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5)
It's something related to 'spawn-async'. I was also getting issues with 'spawn' sometime earlier while creating a node-server...but I resolved that there and then using 'exec' instead. Tried to find this on expo forums and even in react-native issues but couldn't find a solution. Can someone plz suggest something? Is it some "windows" thing only or something related to npm releases?
P.S: I also ran create-react-native-app ProjectName and again got a similar kind of error about end of JSON input!
Now I know what can be the issue, it can be just the trivial one:
Please update node an npm to the newest available version and please init you project again in different directory.
You'll need to have Node.js (version 10 or newer) installed on
your computer. Download the latest version of Node.js.
Additionally, you'll need Git to create new projects with Expo
CLI. You can download Git from here.
Make sure that you have installed these two things in your device.
Go to doc for expo installation
in my case. make sure you have yarn installed and update tour android studio packages, for it to work

React-Native Could not get batchedBridge Error

I am a beginner in React Native (version 0.40.0) and I have encountered a problem while developing a project. When I run npm start (npm version-4.6.0) I get no errors and the packager starts normally. Running react-native run-android also doesn't give any errors however when the app starts in the Android Emulator( Nexus 6 API 23 ) I see the "Unfortunately app had to be closed" notice. The logcats in Android Studio are:
07-22 04:56:15.504 5325-5353/com.downtofood E/AndroidRuntime: FATAL EXCEPTION: mqt_js
Process: com.downtofood, PID: 5325
java.lang.RuntimeException: com.facebook.react.devsupport.JSException: Could not get BatchedBridge, make sure your bundle is packaged correctly
at com.facebook.react.bridge.DefaultNativeModuleCallExceptionHandler.handleException(DefaultNativeModuleCallExceptionHandler.java:24)
at com.facebook.react.devsupport.DisabledDevSupportManager.handleException(DisabledDevSupportManager.java:158)
at com.facebook.react.cxxbridge.CatalystInstanceImpl.onNativeException(CatalystInstanceImpl.java:431)
at com.facebook.react.cxxbridge.CatalystInstanceImpl.access$400(CatalystInstanceImpl.java:51)
at com.facebook.react.cxxbridge.CatalystInstanceImpl$NativeExceptionHandler.handleException(CatalystInstanceImpl.java:447)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:33)
at android.os.Looper.loop(Looper.java:148)
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$3.run(MessageQueueThreadImpl.java:196)
at java.lang.Thread.run(Thread.java:818)
Caused by: com.facebook.react.devsupport.JSException: Could not get BatchedBridge, make sure your bundle is packaged correctly
at com.facebook.react.bridge.queue.NativeRunnable.run(Native Method)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:31)
at android.os.Looper.loop(Looper.java:148) 
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$3.run(MessageQueueThreadImpl.java:196) 
at java.lang.Thread.run(Thread.java:818) 
Caused by: com.facebook.jni.CppException: Could not get BatchedBridge, make sure your bundle is packaged correctly
at com.facebook.react.bridge.queue.NativeRunnable.run(Native Method) 
at android.os.Handler.handleCallback(Handler.java:739) 
at android.os.Handler.dispatchMessage(Handler.java:95) 
at com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:31) 
at android.os.Looper.loop(Looper.java:148) 
at com.facebook.react.bridge.queue.MessageQueueThreadImpl$3.run(MessageQueueThreadImpl.java:196) 
at java.lang.Thread.run(Thread.java:818) 
Please let me know what I can do to resolve this issue.
I'm just going to quote a solution form this issue on the official react-native github repository.
react-native run-android
react-native start --reset-cache
To better understand how this works and to look for another solution there are several issues under similar name/tags on the issue page of the repository itself.

Categories