Open joydeep2001 opened 2 months ago
Hey @joydeep2001 I'd be happy to help you with your documentation. I'm looking to get some experience with REST API documentation so just tell me what you need and I'll give you a hand
@Ashleycodesseo First of all thank you for showing your interest. Your task will be to conduct a thorough review of the routing files located in the server/src/routes directory. Specifically, you will need to verify that each route's request, response, and other parameters align with the OpenAPI documentation found in the project's root folder.
In the event that you discover any inconsistencies between the routes and the OpenAPI documentation, you will be responsible for updating the OpenAPI documentation to ensure accuracy and consistency across the codebase.
You may feel free to ask any further clarification that you need.
@joydeep2001 Thank you! I will work on it tomorrow!
ok @joydeep2001 I'm ready to get started. I will keep you updated
hey @joydeep2001 I'm kind of struggling. I have been trying to run the clique ledger server locally from my computer and I just can't figure out how to make it work. What should I do so I can test it?
hey @Ashleycodesseo Make sure you have docker installed. Docker version 24 or Higher. Then see the ReadMe file all instructions are provided there. In case you still having issues after all this please inform.
Hey @joydeep2001 just wanted to update you. I'm still working at it and will continue to do so over the next few days.
Thanks @Ashleycodesseo ! Please take your time no need to hurry..
Hey @joydeep2001 I'm still having trouble. So I installed docker and I followed the instructions in the readme. but my terminal threw an error : => ERROR [nodejs 6/7] RUN rm .env
What does this mean? I installed nvm so that I could have node.js on my computer. I thought that was the right way to do it? Maybe I'm missing something?
@joydeep2001 nevermind I actually figured it out!
@joydeep2001 I cant get the app running in docker. I don't understand the instructions in the dockerfile after copy
`.env is the for the host machince and .env.doc is for docker container, so after copying the server folder we are deleting the .env and renaming the .env.docker to .env RUN rm .env RUN mv .env.docker .env Copy the entrypoint script COPY entrypoint.sh /usr/local/bin/
Make the entrypoint script executable RUN chmod +x /usr/local/bin/entrypoint.sh
ENTRYPOINT ["entrypoint.sh"]
Expose port 3000 for the application EXPOSE 3000
Specify the command to run the application CMD ["sh", "-c", "npx prisma migrate reset --force && npx prisma migrate dev --name init && npm run dev"] CMD ["npm", "run", "dev"]`
All of these instructions here ^^ I don't understand what I need to do to get it to work properly
@Ashleycodesseo I'm really sorry, as you don't have the .env file this issues are happening. I will share you the .env file. Please send us "Hi" to us at 127.0.0.1.aws@gmail.com we will send you the .env file. Thanks..
@joydeep2001 sent you an email. Talk soon!
Hey, @Ashleycodesseo I've emailed you the .env & .env.docker file and all the instructions you need. Make sure you don't include those when you will push your code. Thanks.
hey @joydeep2001 I sent this in an email as well, but when I initiate npx prisma dev --name init in the terminal I keep getting this error:
Error: Prisma schema validation - (get-config wasm) Error code: P1012 error: Environment variable not found: DATABASE_URL. --> prisma/schema.prisma:7 | 6 | provider = "mysql" 7 | url = env("DATABASE_URL") |
---|
Validation Error Count: 1 [Context: getConfig]
Prisma CLI Version : 5.19.1
what does it mean?
I believe this is happening because when we download the files from gmail it sometimes get renamed. For example .env
becomes env
. The .
get removed somehow. So please cross files names they should be .env
& .env.docker
.
ok let me see what I can do to fix it. I think I need to rename it in the folder because it won't allow me on my desktop. one moment
@joydeep2001 now it won't let me add the .env
maybe can you email me the files in a folder and we can see if it works that way? or you can send it via drive. I know we will get this working soon!
okay in that case I'm creating a zip file containing the .env files and sending you to your email.
@joydeep2001 I got it to work! I had to delete the other .env.docker file and rename it within VS code. It would not let me do it on my dekstop. You have to do it inside the text editor!
ok @joydeep2001 I'm going slowly step by step. I will keep you updated to make sure that it is all correctly set up. Thank you!
Great..!!
Hey @joydeep2001 so I made the build, and when I did docker compose up --watch I'm not getting the location of the local server. Should I send you a picture?
I'm getting this error 2024-09-23 15:06:33 [1] [nodemon] app crashed - waiting for file changes before starting...
i did docker compose down and then put it back up with docker compose up --watch but its still not acivating
okay can you give me the entire nodejs log.
Run this command docker ps
and get the container id of the nodejs app
Then run this command docker logs <container-id>
and give a screenshot.
yes give me one second. Do you want a screenshot or do you want me to copy paste?
copy paste will also work.
kafka-1 | [2024-09-23 19:11:05,903] INFO Updated connection-accept-rate max connection creation rate to 2147483647 (kafka.network.ConnectionQuotas)
kafka-1 | [2024-09-23 19:11:05,904] INFO Awaiting socket connections on 0.0.0.0:9092. (kafka.network.Acceptor)
kafka-1 | [2024-09-23 19:11:05,915] INFO [SocketServer listenerType=ZK_BROKER, nodeId=1001] Created data-plane acceptor and processors for endpoint : ListenerName(OUTSIDE) (kafka.network.SocketServer)
kafka-1 | [2024-09-23 19:11:05,954] INFO [broker-1001-to-controller-send-thread]: Starting (kafka.server.BrokerToControllerRequestThread)
kafka-1 | [2024-09-23 19:11:05,979] INFO [ExpirationReaper-1001-Produce]: Starting (kafka.server.DelayedOperationPurgatory$ExpiredOperationReaper)
kafka-1 | [2024-09-23 19:11:05,981] INFO [ExpirationReaper-1001-Fetch]: Starting (kafka.server.DelayedOperationPurgatory$ExpiredOperationReaper)
kafka-1 | [2024-09-23 19:11:05,984] INFO [ExpirationReaper-1001-DeleteRecords]: Starting (kafka.server.DelayedOperationPurgatory$ExpiredOperationReaper)
kafka-1 | [2024-09-23 19:11:05,986] INFO [ExpirationReaper-1001-ElectLeader]: Starting (kafka.server.DelayedOperationPurgatory$ExpiredOperationReaper)
kafka-1 | [2024-09-23 19:11:06,002] INFO [LogDirFailureHandler]: Starting (kafka.server.ReplicaManager$LogDirFailureHandler)
kafka-1 | [2024-09-23 19:11:06,036] INFO Creating /brokers/ids/1001 (is it secure? false) (kafka.zk.KafkaZkClient)
kafka-1 | [2024-09-23 19:11:06,059] INFO Stat of the created znode at /brokers/ids/1001 is: 26,26,1727118666052,1727118666052,1,0,0,72057654814507008,237,0,26
kafka-1 | (kafka.zk.KafkaZkClient)
kafka-1 | [2024-09-23 19:11:06,061] INFO Registered broker 1001 at path /brokers/ids/1001 with addresses: INSIDE://kafka:9093,OUTSIDE://localhost:9092, czxid (broker epoch): 26 (kafka.zk.KafkaZkClient)
kafka-1 | [2024-09-23 19:11:06,131] INFO [ExpirationReaper-1001-topic]: Starting (kafka.server.DelayedOperationPurgatory$ExpiredOperationReaper)
kafka-1 | [2024-09-23 19:11:06,137] INFO [ExpirationReaper-1001-Heartbeat]: Starting (kafka.server.DelayedOperationPurgatory$ExpiredOperationReaper)
kafka-1 | [2024-09-23 19:11:06,138] INFO [ExpirationReaper-1001-Rebalance]: Starting (kafka.server.DelayedOperationPurgatory$ExpiredOperationReaper)
kafka-1 | [2024-09-23 19:11:06,142] INFO Successfully created /controller_epoch with initial epoch 0 (kafka.zk.KafkaZkClient)
kafka-1 | [2024-09-23 19:11:06,160] INFO [GroupCoordinator 1001]: Starting up. (kafka.coordinator.group.GroupCoordinator)
kafka-1 | [2024-09-23 19:11:06,160] INFO Feature ZK node created at path: /feature (kafka.server.FinalizedFeatureChangeListener)
kafka-1 | [2024-09-23 19:11:06,169] INFO [GroupCoordinator 1001]: Startup complete. (kafka.coordinator.group.GroupCoordinator)
kafka-1 | [2024-09-23 19:11:06,196] INFO Updated cache from existing ts-node ./dist/app.js ./src/app.ts
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [0] assets by path controllers/.ts 1.17 KiB
nodejs-1 | [0] asset controllers/generateMediaId.d.ts 278 bytes [emitted]
nodejs-1 | [0] asset controllers/getUserInfo.d.ts 276 bytes [emitted]
nodejs-1 | [0] + 6 assets
nodejs-1 | [0] assets by path middlewares/.ts 1.67 KiB
nodejs-1 | [0] asset middlewares/checkCliqueLevelPerms.d.ts 998 bytes [emitted]
nodejs-1 | [0] asset middlewares/verifySender.d.ts 184 bytes [emitted]
nodejs-1 | [0] + 3 assets
nodejs-1 | [0] assets by path routes/.ts 555 bytes
nodejs-1 | [0] asset routes/transactions.d.ts 199 bytes [emitted]
nodejs-1 | [0] asset routes/cliques.d.ts 89 bytes [emitted]
nodejs-1 | [0] asset routes/index.d.ts 89 bytes [emitted]
nodejs-1 | [0] + 2 assets
nodejs-1 | [0] asset app.js 78.5 KiB [emitted] (name: main)
nodejs-1 | [0] asset app.d.ts 274 bytes [emitted]
nodejs-1 | [0] cacheable modules 65.3 KiB
nodejs-1 | [0] modules by path ./src/controllers/.ts 6.85 KiB 8 modules
nodejs-1 | [0] modules by path ./src/routes/.ts 50.7 KiB 4 modules
nodejs-1 | [0] modules by path ./src/middlewares/.ts 3.55 KiB 3 modules
nodejs-1 | [0] + 1 module
nodejs-1 | [0] external "express" 42 bytes [built] [code generated]
nodejs-1 | [0] external "http" 42 bytes [built] [code generated]
nodejs-1 | [0] external "socket.io" 42 bytes [built] [code generated]
nodejs-1 | [0] external "@prisma/client" 42 bytes [built] [code generated]
nodejs-1 | [0] external "zod" 42 bytes [built] [code generated]
nodejs-1 | [0] external "bidirectional-map" 42 bytes [built] [code generated]
nodejs-1 | [0] external "express-oauth2-jwt-bearer" 42 bytes [built] [code generated]
nodejs-1 | [0] external "multer" 42 bytes [built] [code generated]
nodejs-1 | [0] external "@aws-sdk/client-s3" 42 bytes [built] [code generated]
nodejs-1 | [0] external "multer-s3" 42 bytes [built] [code generated]
nodejs-1 | [0] webpack 5.93.0 compiled successfully in 3750 ms
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] starting ts-node ./dist/app.js ./src/app.ts
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] starting ts-node ./dist/app.js ./src/app.ts
nodejs-1 | [0] assets by status 78.5 KiB [cached] 1 asset
nodejs-1 | [0] cached modules 65.8 KiB [cached] 26 modules
nodejs-1 | [0] webpack 5.93.0 compiled successfully in 76 ms
nodejs-1 | [1] Server is running on port 3000
nodejs-1 | [1] /server/node_modules/@prisma/client/runtime/library.js:63
nodejs-1 | [1] ${Ze(e)}}var nd=F("prisma:client:engines:resolveEnginePath"),id=()=>new RegExp("runtime[\\\\/]library\\.m?js$");async function Ca(e,t){let r={binary:process.env.PRISMA_QUERY_ENGINE_BINARY,library:process.env.PRISMA_QUERY_ENGINE_LIBRARY}[e]??t.prismaPath;if(r!==void 0)return r;let{enginePath:n,searchedLocations:i}=await od(e,t);if(nd("enginePath",n),n!==void 0&&e==="binary"&&ii(n),n!==void 0)return t.prismaPath=n;let o=await tt(),s=t.generator?.binaryTargets??[],a=s.some(d=>d.native),l=!s.some(d=>d.value===o),u=__filename.match(id())===null,c={searchedLocations:i,generatorBinaryTargets:s,generator:t.generator,runtimeBinaryTarget:o,queryEngineName:Sa(e,o),expectedLocation:dr.default.relative(process.cwd(),t.dirname),errorStack:new Error().stack},p;throw a&&l?p=va(c):l?p=xa(c):u?p=Pa(c):p=Ta(c),new R(p,t.clientVersion)}async function od(engineType,config){let binaryTarget=await tt(),searchedLocations=[],dirname=eval("__dirname"),searchLocations=[config.dirname,dr.default.resolve(dirname,".."),config.generator?.output?.value??dirname,dr.default.resolve(dirname,"../../../.prisma/client"),"/tmp/prisma-engines",config.cwd];__filename.includes("resolveEnginePath")&&searchLocations.push(Go());for(let e of searchLocations){let t=Sa(engineType,binaryTarget),r=dr.default.join(e,t);if(searchedLocations.push(e),Ra.default.existsSync(r))return{enginePath:r,searchedLocations}}return{enginePath:void 0,searchedLocations}}function Sa(e,t){return e==="library"?Nr(t,"fs"):
query-engine-${t}${t==="windows"?".exe":""}}var qi=k(fi());function Aa(e){return e?e.replace(/".*"/g,'"X"').replace(/[\s:\[]([+-]?([0-9]*[.])?[0-9]+)/g,t=>
${t[0]}5):""}function Ia(e){return e.split(
nodejs-1 | [1] ^
nodejs-1 | [1] PrismaClientInitializationError: Prisma Client could not locate the Query Engine for runtime "debian-openssl-3.0.x".
nodejs-1 | [1]
nodejs-1 | [1] This happened because Prisma Client was generated for "darwin", but the actual deployment required "debian-openssl-3.0.x".
nodejs-1 | [1] Add "debian-openssl-3.0.x" to binaryTargets
in the "schema.prisma" file and run prisma generate
after saving it:
nodejs-1 | [1]
nodejs-1 | [1] generator client {
nodejs-1 | [1] provider = "prisma-client-js"
nodejs-1 | [1] binaryTargets = ["native", "debian-openssl-3.0.x"]
nodejs-1 | [1] }
nodejs-1 | [1]
nodejs-1 | [1] The following locations have been searched:
nodejs-1 | [1] /server/node_modules/.prisma/client
nodejs-1 | [1] /server/node_modules/@prisma/client
nodejs-1 | [1] /Users/alorescott/Desktop/Clique-Ledger-Core/server/node_modules/@prisma/client
nodejs-1 | [1] /tmp/prisma-engines
nodejs-1 | [1] /server/prisma
nodejs-1 | [1] at Ca (/server/node_modules/@prisma/client/runtime/library.js:63:805)
nodejs-1 | [1] at async Object.loadLibrary (/server/node_modules/@prisma/client/runtime/library.js:110:10060)
nodejs-1 | [1] at async Cr.loadEngine (/server/node_modules/@prisma/client/runtime/library.js:111:448)
nodejs-1 | [1] at async Cr.instantiateLibrary (/server/node_modules/@prisma/client/runtime/library.js:110:12575) {
nodejs-1 | [1] clientVersion: '5.19.1',
nodejs-1 | [1] errorCode: undefined
nodejs-1 | [1] }
nodejs-1 | [1] [nodemon] app crashed - waiting for file changes before starting...
kafka-1 | creating topics: yourtopic:1:1
zookeeper | 2024-09-23 19:11:14,326 [myid:] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxnFactory@215] - Accepted socket connection from /172.18.0.3:55066
zookeeper | 2024-09-23 19:11:14,330 [myid:] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:ZooKeeperServer@949] - Client attempting to establish new session at /172.18.0.3:55066
zookeeper | 2024-09-23 19:11:14,332 [myid:] - INFO [SyncThread:0:ZooKeeperServer@694] - Established session 0x100000e26910001 with negotiated timeout 30000 for client /172.18.0.3:55066
zookeeper | 2024-09-23 19:11:14,549 [myid:] - INFO [ProcessThread(sid:0 cport:2181)::PrepRequestProcessor@653] - Got user-level KeeperException when processing sessionid:0x100000e26910001 type:setData cxid:0x4 zxid:0x21 txntype:-1 reqpath:n/a Error Path:/config/topics/yourtopic Error:KeeperErrorCode = NoNode for /config/topics/yourtopic
kafka-1 | Created topic yourtopic.
zookeeper | 2024-09-23 19:11:14,589 [myid:] - INFO [ProcessThread(sid:0 cport:2181)::PrepRequestProcessor@487] - Processed session termination for sessionid: 0x100000e26910001
zookeeper | 2024-09-23 19:11:14,591 [myid:] - INFO [NIOServerCxn.Factory:0.0.0.0/0.0.0.0:2181:NIOServerCnxn@1056] - Closed socket connection for client /172.18.0.3:55066 which had sessionid 0x100000e26910001
kafka-1 | [2024-09-23 19:11:14,659] INFO [ReplicaFetcherManager on broker 1001] Removed fetcher for partitions Set(yourtopic-0) (kafka.server.ReplicaFetcherManager)
kafka-1 | [2024-09-23 19:11:14,719] INFO [Log partition=yourtopic-0, dir=/kafka/kafka-logs-d5c97b1f1109] Loading producer state till offset 0 with message format version 2 (kafka.log.Log)
kafka-1 | [2024-09-23 19:11:14,725] INFO Created log for partition yourtopic-0 in /kafka/kafka-logs-d5c97b1f1109/yourtopic-0 with properties {} (kafka.log.LogManager)
kafka-1 | [2024-09-23 19:11:14,727] INFO [Partition yourtopic-0 broker=1001] No checkpointed highwatermark is found for partition yourtopic-0 (kafka.cluster.Partition)
kafka-1 | [2024-09-23 19:11:14,728] INFO [Partition yourtopic-0 broker=1001] Log loaded for partition yourtopic-0 with initial high watermark 0 (kafka.cluster.Partition)
⦿ Watch disabled
i tried to run it one more time. here's the terminal log:
alorescott@Alores-MacBook-Pro server % docker compose up --watch
[+] Running 4/4
✔ Container zookeeper Running 0.0s
✔ Container clique_ledger_mysql_1 Running 0.0s
✔ Container clique-ledger-core-kafka-1 Running 0.0s
✔ Container clique-ledger-core-nodejs-1 Recreated 1.0s
⦿ Watch enabled
Attaching to kafka-1, nodejs-1, clique_ledger_mysql_1, zookeeper
nodejs-1 |
nodejs-1 | > clique_ledger@1.0.0 dev
nodejs-1 | > concurrently "webpack --watch --config webpack.config.mjs" "nodemon ./dist/app.js"
nodejs-1 |
nodejs-1 | [1] [nodemon] 3.1.4
nodejs-1 | [1] [nodemon] to restart at any time, enter rs
nodejs-1 | [1] [nodemon] watching path(s): .
nodejs-1 | [1] [nodemon] watching extensions: ts,json
nodejs-1 | [1] [nodemon] starting ts-node ./dist/app.js ./src/app.ts
nodejs-1 | [1] node:internal/modules/cjs/loader:1228
nodejs-1 | [1] throw err;
nodejs-1 | [1] ^
nodejs-1 | [1]
nodejs-1 | [1] Error: Cannot find module './app.js'
nodejs-1 | [1] Require stack:
nodejs-1 | [1] - /server/dist/imaginaryUncacheableRequireResolveScript
nodejs-1 | [1] at Module._resolveFilename (node:internal/modules/cjs/loader:1225:15)
nodejs-1 | [1] at Function.resolve (node:internal/modules/helpers:190:19)
nodejs-1 | [1] at requireResolveNonCached (/server/node_modules/ts-node/dist/bin.js:549:16)
nodejs-1 | [1] at getProjectSearchDir (/server/node_modules/ts-node/dist/bin.js:519:40)
nodejs-1 | [1] at phase3 (/server/node_modules/ts-node/dist/bin.js:267:27)
nodejs-1 | [1] at bootstrap (/server/node_modules/ts-node/dist/bin.js:47:30)
nodejs-1 | [1] at main (/server/node_modules/ts-node/dist/bin.js:33:12)
nodejs-1 | [1] at Object.ts-node ./dist/app.js ./src/app.ts
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [0] assets by path controllers/.ts 1.17 KiB
nodejs-1 | [0] asset controllers/generateMediaId.d.ts 278 bytes [emitted]
nodejs-1 | [0] asset controllers/getUserInfo.d.ts 276 bytes [emitted]
nodejs-1 | [0] + 6 assets
nodejs-1 | [0] assets by path middlewares/.ts 1.67 KiB
nodejs-1 | [0] asset middlewares/checkCliqueLevelPerms.d.ts 998 bytes [emitted]
nodejs-1 | [0] asset middlewares/verifySender.d.ts 184 bytes [emitted]
nodejs-1 | [0] + 3 assets
nodejs-1 | [0] assets by path routes/.ts 555 bytes
nodejs-1 | [0] asset routes/transactions.d.ts 199 bytes [emitted]
nodejs-1 | [0] asset routes/cliques.d.ts 89 bytes [emitted]
nodejs-1 | [0] asset routes/index.d.ts 89 bytes [emitted]
nodejs-1 | [0] + 2 assets
nodejs-1 | [0] asset app.js 78.5 KiB [emitted] (name: main)
nodejs-1 | [0] asset app.d.ts 274 bytes [emitted]
nodejs-1 | [0] cacheable modules 65.3 KiB
nodejs-1 | [0] modules by path ./src/controllers/.ts 6.85 KiB 8 modules
nodejs-1 | [0] modules by path ./src/routes/.ts 50.7 KiB 4 modules
nodejs-1 | [0] modules by path ./src/middlewares/.ts 3.55 KiB 3 modules
nodejs-1 | [0] + 1 module
nodejs-1 | [0] external "express" 42 bytes [built] [code generated]
nodejs-1 | [0] external "http" 42 bytes [built] [code generated]
nodejs-1 | [0] external "socket.io" 42 bytes [built] [code generated]
nodejs-1 | [0] external "@prisma/client" 42 bytes [built] [code generated]
nodejs-1 | [0] external "zod" 42 bytes [built] [code generated]
nodejs-1 | [0] external "bidirectional-map" 42 bytes [built] [code generated]
nodejs-1 | [0] external "express-oauth2-jwt-bearer" 42 bytes [built] [code generated]
nodejs-1 | [0] external "multer" 42 bytes [built] [code generated]
nodejs-1 | [0] external "@aws-sdk/client-s3" 42 bytes [built] [code generated]
nodejs-1 | [0] external "multer-s3" 42 bytes [built] [code generated]
nodejs-1 | [0] webpack 5.93.0 compiled successfully in 3477 ms
nodejs-1 | [1] [nodemon] starting ts-node ./dist/app.js ./src/app.ts
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] starting ts-node ./dist/app.js ./src/app.ts
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] restarting due to changes...
nodejs-1 | [1] [nodemon] starting ts-node ./dist/app.js ./src/app.ts
nodejs-1 | [0] assets by status 78.5 KiB [cached] 1 asset
nodejs-1 | [0] cached modules 65.8 KiB [cached] 26 modules
nodejs-1 | [0] webpack 5.93.0 compiled successfully in 70 ms
nodejs-1 | [1] Server is running on port 3000
nodejs-1 | [1] /server/node_modules/@prisma/client/runtime/library.js:63
nodejs-1 | [1] ${Ze(e)}}var nd=F("prisma:client:engines:resolveEnginePath"),id=()=>new RegExp("runtime[\\\\/]library\\.m?js$");async function Ca(e,t){let r={binary:process.env.PRISMA_QUERY_ENGINE_BINARY,library:process.env.PRISMA_QUERY_ENGINE_LIBRARY}[e]??t.prismaPath;if(r!==void 0)return r;let{enginePath:n,searchedLocations:i}=await od(e,t);if(nd("enginePath",n),n!==void 0&&e==="binary"&&ii(n),n!==void 0)return t.prismaPath=n;let o=await tt(),s=t.generator?.binaryTargets??[],a=s.some(d=>d.native),l=!s.some(d=>d.value===o),u=__filename.match(id())===null,c={searchedLocations:i,generatorBinaryTargets:s,generator:t.generator,runtimeBinaryTarget:o,queryEngineName:Sa(e,o),expectedLocation:dr.default.relative(process.cwd(),t.dirname),errorStack:new Error().stack},p;throw a&&l?p=va(c):l?p=xa(c):u?p=Pa(c):p=Ta(c),new R(p,t.clientVersion)}async function od(engineType,config){let binaryTarget=await tt(),searchedLocations=[],dirname=eval("__dirname"),searchLocations=[config.dirname,dr.default.resolve(dirname,".."),config.generator?.output?.value??dirname,dr.default.resolve(dirname,"../../../.prisma/client"),"/tmp/prisma-engines",config.cwd];__filename.includes("resolveEnginePath")&&searchLocations.push(Go());for(let e of searchLocations){let t=Sa(engineType,binaryTarget),r=dr.default.join(e,t);if(searchedLocations.push(e),Ra.default.existsSync(r))return{enginePath:r,searchedLocations}}return{enginePath:void 0,searchedLocations}}function Sa(e,t){return e==="library"?Nr(t,"fs"):
query-engine-${t}${t==="windows"?".exe":""}}var qi=k(fi());function Aa(e){return e?e.replace(/".*"/g,'"X"').replace(/[\s:\[]([+-]?([0-9]*[.])?[0-9]+)/g,t=>
${t[0]}5):""}function Ia(e){return e.split(
nodejs-1 | [1] ^
nodejs-1 | [1] PrismaClientInitializationError: Prisma Client could not locate the Query Engine for runtime "debian-openssl-3.0.x".
nodejs-1 | [1]
nodejs-1 | [1] This happened because Prisma Client was generated for "darwin", but the actual deployment required "debian-openssl-3.0.x".
nodejs-1 | [1] Add "debian-openssl-3.0.x" to binaryTargets
in the "schema.prisma" file and run prisma generate
after saving it:
nodejs-1 | [1]
nodejs-1 | [1] generator client {
nodejs-1 | [1] provider = "prisma-client-js"
nodejs-1 | [1] binaryTargets = ["native", "debian-openssl-3.0.x"]
nodejs-1 | [1] }
nodejs-1 | [1]
nodejs-1 | [1] The following locations have been searched:
nodejs-1 | [1] /server/node_modules/.prisma/client
nodejs-1 | [1] /server/node_modules/@prisma/client
nodejs-1 | [1] /Users/alorescott/Desktop/Clique-Ledger-Core/server/node_modules/@prisma/client
nodejs-1 | [1] /tmp/prisma-engines
nodejs-1 | [1] /server/prisma
nodejs-1 | [1] at Ca (/server/node_modules/@prisma/client/runtime/library.js:63:805)
nodejs-1 | [1] at async Object.loadLibrary (/server/node_modules/@prisma/client/runtime/library.js:110:10060)
nodejs-1 | [1] at async Cr.loadEngine (/server/node_modules/@prisma/client/runtime/library.js:111:448)
nodejs-1 | [1] at async Cr.instantiateLibrary (/server/node_modules/@prisma/client/runtime/library.js:110:12575) {
nodejs-1 | [1] clientVersion: '5.19.1',
nodejs-1 | [1] errorCode: undefined
nodejs-1 | [1] }
nodejs-1 | [1] [nodemon] app crashed - waiting for file changes before starting...
v View in Docker Desktop o View Config w Disable Watch
okay so our system is only tested in debian and windows system and not in macos. So I believe this is some mac specific issue.
I will suggest you to search for this following issue in internet. You may google it or may use some AI tools to get the solution. I think we need to do a little bit modification in schema.prisma
file to get it run in macos.
PrismaClientInitializationError: Prisma Client could not locate the Query Engine for runtime "debian-openssl-3.0.x".
nodejs-1 | [1]
nodejs-1 | [1] This happened because Prisma Client was generated for "darwin", but the actual deployment required "debian-openssl-3.0.x".
nodejs-1 | [1] Add "debian-openssl-3.0.x" to binaryTargets in the "schema.prisma" file and run prisma generate after saving it:
nodejs-1 | [1]
nodejs-1 | [1] generator client {
nodejs-1 | [1] provider = "prisma-client-js"
nodejs-1 | [1] binaryTargets = ["native", "debian-openssl-3.0.x"]
nodejs-1 | [1] }
nodejs-1 | [1]
nodejs-1 | [1] The following locations have been searched:
nodejs-1 | [1] /server/node_modules/.prisma/client
nodejs-1 | [1] /server/node_modules/@prisma/client
nodejs-1 | [1] /Users/alorescott/Desktop/Clique-Ledger-Core/server/node_modules/@prisma/client
nodejs-1 | [1] /tmp/prisma-engines
nodejs-1 | [1] /server/prisma
nodejs-1 | [1] at Ca (/server/node_modules/@prisma/client/runtime/library.js:63:805)
nodejs-1 | [1] at async Object.loadLibrary (/server/node_modules/@prisma/client/runtime/library.js:110:10060)
nodejs-1 | [1] at async Cr.loadEngine (/server/node_modules/@prisma/client/runtime/library.js:111:448)
nodejs-1 | [1] at async Cr.instantiateLibrary (/server/node_modules/@prisma/client/runtime/library.js:110:12575) {
nodejs-1 | [1] clientVersion: '5.19.1',
nodejs-1 | [1] errorCode: undefined
nodejs-1 | [1] }
For example this is what chatgpt gave me but I don't have a macos to test it. So you have to figure this out by yourself. https://chatgpt.com/share/66f1c170-4928-8008-bbf6-5a99fd17028f
ok I will look into it. But who made the instruction video that was sent to me earlier? I think it was Arpan @arpan4119 ? It looked like they have a mac in the video?
I made the video and that's an Ubuntu System not mac. It seemed to you like a Mac because of the fancy theme installed on that 😂
ok let me work on it on my end and you can let me know if you make a mac fix on your end . I will keep you updated
its up! We did it!
Since it's working on your Mac can you briefly mention that how you made it work in the readme file under contributor's guide and give a small PR.? It would be great for future contributors. Like you just mention what are the additional steps a contributor should do when they are using Mac to run the project.
Yes I got you! I have to work but I will as soon as I can
Hey @Ashleycodesseo , kindly let us know the updates. I would suggest you to do it part by part and keep giving PRs. No need to do the whole thing at once. You may update the docs for one end point and give a PR and move to next one.
Thanks..
Hey @joydeep2001 sorry I have been working everyday this week
I will email you those instructions tonite. Thank you
@joydeep2001 I emailed you the document explaining the configuration. I started a new job this week that will not allow me the time to contribute to the project for now. If you want me to push up my forked folder to github, let me know. And thank you so much!
hey @Ashleycodesseo push whatever you have done , and give a PR .
I'm trying to push my fork back up to github but it wont let me, its saying To https://github.com/Ashleycodesseo/Clique-Ledger-Core.git ! [remote rejected] main -> main (push declined due to repository rule violations) error: failed to push some refs to 'https://github.com/Ashleycodesseo/Clique-Ledger-Core.git'
hey @Ashleycodesseo thanks for your response. You won't be able to push changes in the main branch. You need to create another branch and push that branch. Also give a PR after you push the branch.
@joydeep2001 pushing it up the proper way now!
hmmm I still don't understand what I'm doing wrong. I made my own branch, added and committed the changes, then I pushed both to origin HEAD and to origin HEAD:main. both are throwing an error
alorescott@Alores-MacBook-Pro Clique-Ledger-Core % git push origin HEAD
Enumerating objects: 17, done.
Counting objects: 100% (17/17), done.
Delta compression using up to 16 threads
Compressing objects: 100% (9/9), done.
Writing objects: 100% (10/10), 2.33 KiB | 1.17 MiB/s, done.
Total 10 (delta 7), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (7/7), completed with 6 local objects.
remote: error: GH013: Repository rule violations found for refs/heads/ashley_branch.
remote:
remote: - GITHUB PUSH PROTECTION
remote: —————————————————————————————————————————
remote: Resolve the following violations before pushing again
remote:
remote: - Push cannot contain secrets
remote:
remote:
remote: (?) Learn how to resolve a blocked push
remote: https://docs.github.com/code-security/secret-scanning/working-with-secret-scanning-and-push-protection/working-with-push-protection-from-the-command-line#resolving-a-blocked-push
remote:
remote:
remote: —— Amazon AWS Access Key ID ——————————————————————————
remote: locations:
remote: - commit: 2e8349f32cfb3369dc0fb4566c4a3c4026650909
remote: path: server/.env.docker:5
remote:
remote: (?) To push, remove secret from commit(s) or follow this URL to allow the secret.
remote: https://github.com/Ashleycodesseo/Clique-Ledger-Core/security/secret-scanning/unblock-secret/2nRhKBftvZVLtfYCQyfw3g9tyIm
remote:
remote:
remote: —— Amazon AWS Secret Access Key ——————————————————————
remote: locations:
remote: - commit: 2e8349f32cfb3369dc0fb4566c4a3c4026650909
remote: path: server/.env.docker:6
remote:
remote: (?) To push, remove secret from commit(s) or follow this URL to allow the secret.
remote: https://github.com/Ashleycodesseo/Clique-Ledger-Core/security/secret-scanning/unblock-secret/2nRhKCKttE2OcaoteNTWvS30MLD
remote:
remote:
remote:
To https://github.com/Ashleycodesseo/Clique-Ledger-Core.git
! [remote rejected] HEAD -> ashley_branch (push declined due to repository rule violations)
error: failed to push some refs to 'https://github.com/Ashleycodesseo/Clique-Ledger-Core.git'
alorescott@Alores-MacBook-Pro Clique-Ledger-Core % git push origin HEAD:main
Enumerating objects: 17, done.
Counting objects: 100% (17/17), done.
Delta compression using up to 16 threads
Compressing objects: 100% (9/9), done.
Writing objects: 100% (10/10), 2.33 KiB | 1.17 MiB/s, done.
Total 10 (delta 7), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (7/7), completed with 6 local objects.
remote: error: GH013: Repository rule violations found for refs/heads/main.
remote:
remote: - GITHUB PUSH PROTECTION
remote: —————————————————————————————————————————
remote: Resolve the following violations before pushing again
remote:
remote: - Push cannot contain secrets
remote:
remote:
remote: (?) Learn how to resolve a blocked push
remote: https://docs.github.com/code-security/secret-scanning/working-with-secret-scanning-and-push-protection/working-with-push-protection-from-the-command-line#resolving-a-blocked-push
remote:
remote:
remote: —— Amazon AWS Access Key ID ——————————————————————————
remote: locations:
remote: - commit: 2e8349f32cfb3369dc0fb4566c4a3c4026650909
remote: path: server/.env.docker:5
remote:
remote: (?) To push, remove secret from commit(s) or follow this URL to allow the secret.
remote: https://github.com/Ashleycodesseo/Clique-Ledger-Core/security/secret-scanning/unblock-secret/2nRhKBftvZVLtfYCQyfw3g9tyIm
remote:
remote:
remote: —— Amazon AWS Secret Access Key ——————————————————————
remote: locations:
remote: - commit: 2e8349f32cfb3369dc0fb4566c4a3c4026650909
remote: path: server/.env.docker:6
remote:
remote: (?) To push, remove secret from commit(s) or follow this URL to allow the secret.
remote: https://github.com/Ashleycodesseo/Clique-Ledger-Core/security/secret-scanning/unblock-secret/2nRhKCKttE2OcaoteNTWvS30MLD
remote:
remote:
remote:
To https://github.com/Ashleycodesseo/Clique-Ledger-Core.git
! [remote rejected] HEAD -> main (push declined due to repository rule violations)
error: failed to push some refs to 'https://github.com/Ashleycodesseo/Clique-Ledger-Core.git'
alorescott@Alores-MacBook-Pro Clique-Ledger-Core %
As I can see in the error message your push contains secrets like aws key, which is the reason your push is blocked this time. Make sure all of them are kept in .env file. The .env file in not included in the commit. If you have already committed the secrets you might need to reset the commit, exclude the .env file and commit it again.
@Ashleycodesseo If you are facing issues which are not being solved , i will suggest you to come on a gmeet/zoom , there we can see what is causing this . let us know when you are available .
Our API documentation is written using OpenAPI and is almost complete. However, some endpoints may not be fully up-to-date with the latest code changes. If you're interested in contributing, feel free to take on this task.
If you update any of the endpoints, please mention it in your git commit by stating that it "partially fixes #issue_number" to keep track of the progress.